Skip to content

Instantly share code, notes, and snippets.

@justinline
Last active July 4, 2025 12:46
Show Gist options
  • Save justinline/835d69c24cab3a06a3c736cf94f02409 to your computer and use it in GitHub Desktop.
Save justinline/835d69c24cab3a06a3c736cf94f02409 to your computer and use it in GitHub Desktop.
My git aliases
alias.st status
# Show recent branch names
alias.recent for-each-ref --sort=-committerdate refs/heads/ --format='%(refname:short)'
# Please 🥺 - useful for rebasers
alias.please push --force-with-lease
# Quickly commit all work instead of stashing
alias.wip !git add . && git commit -m "WIP" --no-verify
# Start work on the most recent commit, used often with `git wip`
alias.edit reset --soft HEAD~1
# Squash all fixup commits
alias.squash git rebase -i origin/main --autosquash
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment