I have configured git to always sign commits with my gpg key. In ~/.gitconfig I added my user.signingkey and set commit.gpgsign to true. From the command line, everything works fine.
I'd like Cola to do the same. Right now, I can't get it to sign commits at all. In fact, it won't even commit. Here's what I'm doing:
After making some edits, I stage the changes, write up my nice commit message, and click the Commit button. This returns an error:
Commit failed:
gpg: cannot open tty `/dev/tty': No such device or address
error: gpg failed to sign the data
fatal: failed to write commit object
exit code 128
I try to click the menu to Create Signed Commit. for the regular Commit, and nothing happens.
I'm running Git Cola v2.3 on Fedora 22 (64-bit). I've read the Cola docs about setting up gpg and I'm still having trouble. Here's the git cola options in ~/.gitconfig
[cola]
textwidth = 72
fontdiff = Source Code Pro,12,-1,5,50,0,0,0,0,0
tabwidth = 4
signcommits = true
In ~/.gnupg/gpg.conf I set use-agent.
And in ~/.gnupg/gpg-agent.conf I added the following lines, as suggested in the Cola documentation.
pinentry-program /usr/bin/pinentry-gtk
default-cache-ttl 3600
enable-ssh-support
use-standard-socket
Any ideas? Thanks for taking a look at this with me.
Commit failed:
gpg: skipped "m...@example.mail": No secret key
gpg: signing failed: No secret key
error: gpg failed to sign the data
fatal: failed to write commit object
exit code 128