Skip to content

Instantly share code, notes, and snippets.

View Kenshino's full-sized avatar

Jon Ang Kenshino

View GitHub Profile
/**
* Load more content over ajax in a nice manner
*
* This script utilizes Font Awesome to give proper visual feedback
* while the new content is being fetched and loaded
*
* Usage:
* - Attach the class 'load-more-content' to any a tag in the DOM
* - Give this object a data attribute of data-content-area which indicates
* what part of the site is to be loaded in
@Clorith
Clorith / load-more-content.js
Last active October 21, 2021 11:06
jQuery script for loading more content over ajax.
/**
* Load more content over ajax in a nice manner
*
* This script utilizes Font Awesome to give proper visual feedback
* while the new content is being fetched and loaded
*
* Usage:
* - Attach the class 'load-more-content' to any a tag in the DOM
* - Give this object a data attribute of data-content-area which indicates
* what part of the site is to be loaded in
@chrismccoy
chrismccoy / gitcheats.txt
Last active June 29, 2025 17:35
git cheats
# alias to edit commit messages without using rebase interactive
# example: git reword commithash message
reword = "!f() {\n GIT_SEQUENCE_EDITOR=\"sed -i 1s/^pick/reword/\" GIT_EDITOR=\"printf \\\"%s\\n\\\" \\\"$2\\\" >\" git rebase -i \"$1^\";\n git push -f;\n}; f"
# transfer all git repos from one org to another org
gh repo list {orgname} --limit 300 --json nameWithOwner -q '.[].nameWithOwner' | xargs -I {} gh api --method POST repos/{}/transfer -f new_owner={neworg}
# aliases to change a git repo from private to public, and public to private using gh-cli
alias gitpublic="gh repo edit --accept-visibility-change-consequences --visibility public"
alias gitprivate="gh repo edit --accept-visibility-change-consequences --visibility private"