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 trueReplace
YOUR_SIGNING_KEYwith 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 logto display your commit history. Once you have your commit hash, start the rebase: