Skip to content

Instantly share code, notes, and snippets.

@thisaurel
Last active January 23, 2021 12:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save thisaurel/26c766abb33743c17648e3d47444d63f to your computer and use it in GitHub Desktop.
Save thisaurel/26c766abb33743c17648e3d47444d63f to your computer and use it in GitHub Desktop.
[user]
name = ************************
email = *************************
signingkey = *********************
[color]
ui = true
diff = auto
status = auto
[alias]
st = status -sb
a = add -p
s = switch # Switch a branch
sc = switch -c # Switch a new not yet existing branch
f = fetch -p --all # Fetch from a repository and prune any remote-tracking references that no longer exist on the remote.
rom = !git f && git rebase origin/master && git st
c = commit # Commit your changes
ca = commit --amend # Commit your changes with amend
p = push # Push your changes to a remote
pf = push -f # Push your changes to a remote with force flag
ba = branch -a # List both remote-tracking branches and local branches.
bd = branch -d # Delete a branch only if it has been merged
bD = branch -D # Force delete a branch
dc = diff --cached # Display the staged changes
lg = log --graph --pretty=tformat:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%an %cr)%Creset'
last = log --graph --pretty=tformat:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%an %cr)%Creset' -n15
plog = log --graph --pretty='format:%C(red)%d%C(reset) %C(yellow)%h%C(reset) %ar %C(green)%aN%C(reset) %s'
tlog = log --stat --since='1 Day Ago' --graph --pretty=oneline --abbrev-commit --date=relative
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment