Skip to content

Instantly share code, notes, and snippets.

@elutins
Created April 14, 2025 13:30
Show Gist options
  • Select an option

  • Save elutins/427541dc6b814267910902563a8d0cef to your computer and use it in GitHub Desktop.

Select an option

Save elutins/427541dc6b814267910902563a8d0cef to your computer and use it in GitHub Desktop.
Common git aliases to include in a .gitconfig file
[user]
email = evandlutins@gmail.com
name = evan lutins
[alias]
# nice one liner for status
st = status --short
stu = status --short --untracked-files=no
stau = status --untracked-files=no
# nice one liner to push the current local branch to the remote origin with the branch with the same name
psu = "!f() { \
cur_branch=$(git rev-parse --abbrev-ref HEAD); \
git push --set-upstream origin $cur_branch; \
}; \
f"
gcm = git commit --message
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment