Skip to content

Instantly share code, notes, and snippets.

@EliteMasterEric
Created October 2, 2025 21:14
Show Gist options
  • Select an option

  • Save EliteMasterEric/a3e23710d91f30f74490f602343cd602 to your computer and use it in GitHub Desktop.

Select an option

Save EliteMasterEric/a3e23710d91f30f74490f602343cd602 to your computer and use it in GitHub Desktop.

review Alias

git config alias.review "! f() { git fetch public pull/$1/head:$2; }; f "

git review 1234 feature/new-feature

Fetches the commit with the given GitHub ID from the public remote and checks it out with the given branch name.

coauthor Alias

git config --global alias.coauthor '!f() { git commit --amend --no-edit -m "$(git log --format=%B -n1)" -m"Co-authored-by: $1 <[email protected]>"; }; f'

git coauthor Torvalds

Mutates the latest commit of the current Git branch to add the user with the given GitHub username as a co-author.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment