Last active
July 21, 2021 19:35
-
-
Save diodonfrost/9ecd101ef641d349d89b3f38a0a3bf2d to your computer and use it in GitHub Desktop.
Filter only specific commits and sign only them
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Filter only specific commits and sign only them | |
| git filter-branch --commit-filter 'if [ "$GIT_COMMITTER_EMAIL" = "user@domain.com" ]; | |
| then git commit-tree -S "$@"; | |
| else git commit-tree --no-gpg-sign "$@"; | |
| fi' HEAD | |
| git push --force |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment