I wonder how I can add the "signed-off-by" line in a Git commit automatically within PyCharm's Commit dialog.
There are options for amending to the previous commit and changing the author of the commit, but I couldn't find an option for adding the signed-off line (git commit -s
) on a per-commit basis.
Is it even possible or is it a missing feature?
For anyone getting this answer in google searches, here is the solution as tested in Ubuntu 16.04:
echo 'no-tty' >> ~/.gnupg/gpg.conf
echo 'use-agent' >> ~/.gnupg/gpg.conf
Then you can:
git config --global format.signoff true
This will set git to always sign-off, and set gpg to use a gtk popup to ask for your key password when needed and avoid errors in pycharm.
Hope that helps someone.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With