To sign all your commits in the Git Pull Request (PR), you can use a combination of git rebase
and git commit --amend
. Here are the steps:
-
Before starting, make sure you've configured Git to use your signing key. You can do this with:
git config --global user.signingkey YOUR_SIGNING_KEY git config --global commit.gpgsign true
Replace
YOUR_SIGNING_KEY
with your GPG key ID. -
Then you need to start an interactive rebase with the parent of your first commit. If you don't know what commit that is, you can use
git log
to display your commit history. Once you have your commit hash, start the rebase: