Skip to content

Instantly share code, notes, and snippets.

@urklc
Last active November 23, 2023 07:26
Show Gist options
  • Save urklc/1abe1ee56f9206f75ef5593067746324 to your computer and use it in GitHub Desktop.
Save urklc/1abe1ee56f9206f75ef5593067746324 to your computer and use it in GitHub Desktop.
[alias]
hard = reset --hard HEAD^
soft = reset --soft HEAD^
amend = commit --amend
ck = "!f() { git checkout "$1"; }; f"
ckb = "!f() { git checkout -b "$1"; }; f"
rbi = "!f() { git rebase -i "$1"; }; f"
rbc = rebase --continue
rba = rebase --abort
rbdate = rebase --ignore-date
del = "!f() { git branch -d "$1"; }; f"
dell = "!f() { git branch -D "$1"; }; f"
backup = "!f() { git add --all; git checkout -b "$1"; git commit -m "backup"; git checkout master; }; f"
tagco = "!f() { git tag --contains "$1"; }; f"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment