Skip to content

Instantly share code, notes, and snippets.

View DEARaison's full-sized avatar
🎯
Focusing

DEA Raison DEARaison

🎯
Focusing
View GitHub Profile
@DEARaison
DEARaison / rarreg.key
Last active August 2, 2022 01:35 — forked from MuhammadSaim/rarreg.key
Step 1: Create a file called rarreg.key Step 2: Paste into the file the raw content of this gist Step 3: Go to Winrar install directory (by default => c:\ProgramFiles\WinRAR\ ) Step 4: Paste the rarreg.key into WinRAR directory Step 5: Enjoy
RAR registration data
WinRAR
Unlimited Company License
UID=4b914fb772c8376bf571
6412212250f5711ad072cf351cfa39e2851192daf8a362681bbb1d
cd48da1d14d995f0bbf960fce6cb5ffde62890079861be57638717
7131ced835ed65cc743d9777f2ea71a8e32c7e593cf66794343565
b41bcf56929486b8bcdac33d50ecf773996052598f1f556defffbd
982fbe71e93df6b6346c37a3890f3c7edc65d7f5455470d13d1190
6e6fb824bcf25f155547b5fc41901ad58c0992f570be1cf5608ba9
@DEARaison
DEARaison / MouseJigglerPowerShell.ps1
Last active September 22, 2023 05:36
A PowerShell script to prevent computer from going to sleep mode
# MouseJiggler PowerShell Script
Clear-Host
Echo "Keep-alive with Scroll Lock..."
$WShell = New-Object -com "Wscript.Shell"
while ($true)
{
@DEARaison
DEARaison / Get resource form classpath
Created October 24, 2021 09:13
Get resource form classpath
// Static way
System.out.println("test1: "+TestGetResource.class.getResource("test.css"));
// Dynamic way
System.out.println("test2: "+getClass().getResource("test.css"));
public static void wait(int ms)
{
try
{
Thread.sleep(ms);
}
catch(InterruptedException ex)
{
Thread.currentThread().interrupt();
}
@DEARaison
DEARaison / SHOPEE Statistics
Last active April 18, 2024 17:05
To Get Shopee Statistics
var tongDonHang = 0;
var tongTienTietKiem=0;
var tongtienhang = 0;
var tongtienhangchuagiam = 0;
var tongSanPhamDaMua = 0;
var trangThaiDonHangConKhong = true;
var offset = 0;
var si = 20;
function xemBaoCaoThongKe() {
var orders = [];
@DEARaison
DEARaison / Rename Github's default branch
Last active October 14, 2021 13:24 — forked from lttlrck/gist:9628955
rename git branch locally and remotely
If you want to rename a brach being the Github's default branch, You must set the default branch to another branch before renaming the branch.
git branch -m old_branch new_branch # Rename branch locally
git push origin :old_branch # Delete the old branch from remote
git push --set-upstream origin new_branch # Push the new branch, set local branch to track the new remote
public static void main(String[] args) {
String userHomePath = System.getProperty("user.home");
String projectDirPath = System.getProperty("user.dir");
String roamingAppDataPath = System.getenv("AppData");
String LocalAppDataPath = System.getenv("LocalAppData");
String localLowAppDataPath = System.getProperty("user.home") + File.separator + "AppData" + File.separator + "LocalLow";
System.out.println(userHomePath);
System.out.println(projectDirPath);
System.out.println(roamingAppDataPath);
DISM /Online /Cleanup-Image /RestoreHealth
sfc /scannow
@DEARaison
DEARaison / Remove unnecessary IntelliJ IDEA config files.ps1
Last active September 23, 2023 16:37
Remove IntelliJ IDEA config files or folders that can be created automatically by IntelliJ
"Put config folder into the same folder with this script file"
Pause
# Files and directories need removing
$directoriesToRemove = "codestyles", "event-log-whitelist", "extensions", "jdbc-drivers", "mdn", "tasks", "workspace", "terminal"
$filesInConfigToRemove = "idea.properties", "idea64.exe.vmoptions", "user.web.token"
$filesInOptionsToRemove = "acceptedLanguageLevels.xml", "baseRefactoring.xml", "colors.scheme.xml", "databaseDrivers.xml", "debugger.xml", "dimensions.xml", "equalsHashCodeTemplates.xml", "extensionsRootType.xml", "file.template.settings.xml", "filetypes.xml", "find.xml", "images.support.xml", "jdk.table.xml", "markdown.xml", "other.xml", "laf.xml", "path.macros.xml", "profilerRunConfigurations.xml", "recentProjects.xml", "runner.layout.xml", "studioFlags.xml", "textmate_os.xml", "updates.xml", "usage.statistics.xml", "vcs.xml", "window.state.xml", "window.manager.xml", "wsl.distributions.xml"
# The total number of files/directories to remove
$totalDirs = $directoriesToRemove.Length
$totalFil
@DEARaison
DEARaison / Solution to remove unremovable files and folders on Windows
Last active September 23, 2023 16:38
Solution to remove unremovable files/folder on Windows
1.Create folder that name "windows.old" in Local disk C
2.Drag the files or folder that cannot be deleted into Windows.old
3.run Disk cleanup
4.choose Disk C
5.then click Cleanup System Files