Git Commands Cheatsheet
Lazy loaded imageGit Commands Cheatsheet
May 10, 2023|Last edited: Feb 21, 2025
type
status
date
slug
summary
tags
category
icon
password
Importance
Tweet
Commands
Description
git log --show-signature
git log but with signature
git commit --amend --no-edit -s
sign the latest commit with no message change
git stash -m <message>
git stash with message
git rebase --exec 'git commit --amend --no-edit -n -S' -i origin/main
sign all rebased commits over origin/main branch
git config commit.gpgsign true
Setting auto signing in commits
git config gpg.format ssh

Notes

  • always git stash with a message unless you know for sure you are getting back to it within a few minutes, even so it is so hard to type a quick message for it
 
How to generate ssh keyI switched username and lost association with previous commits
Loading...