Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Mahesh Bandara Wijerathna m4heshd

🏠
Working from home
View GitHub Profile
@m4heshd
m4heshd / git-author-change.txt
Created Jan 27, 2021
All the necessary command lines to perform a full author rewrite for a git repository
View git-author-change.txt
//Remember to replace single quotes with double quotes if you're using these commands on a windows PS or command prompt
1. git clone --bare https://github.com/path_to_your_github_repo.git
2. cd creted_directory.git
2. git filter-branch -f --env-filter '
OLD_EMAIL="your-old-email@example.com"
CORRECT_NAME="Your correct name"
CORRECT_EMAIL="your-correct-email@example.com"
@m4heshd
m4heshd / slt_quota.js
Last active Nov 26, 2019
Remaining quota display in GB for SLT Broadband portal
View slt_quota.js
/* ------------------------------------------------
Use this code with a Javascript injector for your browser
Chrome - https://chrome.google.com/webstore/detail/user-javascript-and-css/nbhcbdghjpllgmfilhnhkllmkecfmpld
------------------------------------------------ */
let stdSel = "#root > div > div > div:nth-child(3) > div > div > div > div:nth-child(3) > div.col-md-8 > div > div:nth-child(1) > div > div > div > div:nth-child(1) > div > div > div:nth-child(3) > svg > text";
let totSel = "#root > div > div > div:nth-child(3) > div > div > div > div:nth-child(3) > div.col-md-8 > div > div:nth-child(1) > div > div > div > div:nth-child(2) > div > div > div:nth-child(3) > svg > text";
let xhrnew = null;
@m4heshd
m4heshd / WebStorm.cmd
Created Apr 3, 2018 — forked from M1chaelTran/WebStorm.cmd
Add `Open with WebStorm` to Windows right click context menu
View WebStorm.cmd
@echo off
:: change the path below to match your installed version
SET WebStormPath=C:\Program Files\JetBrains\WebStorm 2017.2.2\bin\webstorm64.exe
echo Adding file entries
@reg add "HKEY_CLASSES_ROOT\*\shell\WebStorm" /t REG_SZ /v "" /d "Open with WebStorm" /f
@reg add "HKEY_CLASSES_ROOT\*\shell\WebStorm" /t REG_EXPAND_SZ /v "Icon" /d "%WebStormPath%,0" /f
@reg add "HKEY_CLASSES_ROOT\*\shell\WebStorm\command" /t REG_SZ /v "" /d "%WebStormPath% \"%%1\"" /f