{"thread":{"id":"22416","subject":"git-tag -s can't find GPG private key","startedAt":"2010-01-27T21:02:40Z","lastAt":"2010-01-27T21:16:33Z","messageCount":3,"participants":["Mike.lifeguard","Sverre Rabbelier","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"132834","messageId":"4B60A9F0.5000904@gmail.com","threadId":"22416","inReplyTo":null,"subject":"git-tag -s can't find GPG private key","fromName":"Mike.lifeguard","fromEmail":"mike.lifeguard@gmail.com","sentAt":"2010-01-27T21:02:40Z","receivedAt":"2010-01-27T21:02:40Z","isPatch":false,"sender":{"key":"mike.lifeguard@gmail.com","avatar":"https://gravatar.com/avatar/a12ecdf9f8b0f34d981d1ae8d7e74205358548f48936c86f240308e942544928?d=mp&s=160"},"body":"-----BEGIN PGP SIGNED MESSAGE-----\nHash: SHA1\n\nHello,\n\nIt seems that when the GPG key name and user.name in git's config are\ndifferent, git can't find the appropriate private key to sign the tag.\nGit should attempt to use user.email to find the key. Setting\nuser.signingkey is of course a workaround. The relevant code would be in\nbuiltin-tag.c.\n\n- -Mike\n-----BEGIN PGP SIGNATURE-----\nVersion: GnuPG v1.4.9 (GNU/Linux)\n\niEYEARECAAYFAktgqewACgkQst0AR/DaKHuDZgCgpYHD05aJHKF/Wj/uU8CK5swP\nSccAoMjHVKM/OZBhbvSvC+aWCQ123Tje\n=ZIo0\n-----END PGP SIGNATURE-----\n"},{"id":"132835","messageId":"fabb9a1e1001271306o7e6d9abu1f370ed4698ac055@mail.gmail.com","threadId":"22416","inReplyTo":"4B60A9F0.5000904@gmail.com","subject":"Re: git-tag -s can't find GPG private key","fromName":"Sverre Rabbelier","fromEmail":"srabbelier@gmail.com","sentAt":"2010-01-27T21:06:00Z","receivedAt":"2010-01-27T21:06:00Z","isPatch":false,"sender":{"key":"srabbelier@gmail.com","avatar":"https://avatars.githubusercontent.com/u/3098?v=4"},"body":"Heya,\n\nOn Wed, Jan 27, 2010 at 22:02, Mike.lifeguard <mike.lifeguard@gmail.com> wrote:\n> It seems that when the GPG key name and user.name in git's config are\n> different, git can't find the appropriate private key to sign the tag.\n> Git should attempt to use user.email to find the key. Setting\n> user.signingkey is of course a workaround. The relevant code would be in\n> builtin-tag.c.\n\nIt seems you already know where to look, why don't you try and come up\nwith a patch since it is indeed, your itch to scratch?\n\n-- \nCheers,\n\nSverre Rabbelier\n"},{"id":"132836","messageId":"7v3a1rp7ta.fsf@alter.siamese.dyndns.org","threadId":"22416","inReplyTo":"4B60A9F0.5000904@gmail.com","subject":"Re: git-tag -s can't find GPG private key","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2010-01-27T21:16:33Z","receivedAt":"2010-01-27T21:16:33Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Mike.lifeguard\" <mike.lifeguard@gmail.com> writes:\n\n> It seems that when the GPG key name and user.name in git's config are\n> different, git can't find the appropriate private key to sign the tag.\n> Git should attempt to use user.email to find the key. Setting\n> user.signingkey is of course a workaround.\n\nuser.signingkey was devised for this exact case, and I don't think it is a\nwork-around.\n\nI do not think \"should attempt\" is a correct attitude, even though I can\n100% agree with \"it would have been nicer if it attempted to do this from\nday one\".  You are unfortunately not interacting with git codebase in\nearly 2005 anymore and there are thousands if not millions of existing\nusers you should worry about.\n\nUsing user.email changes the behaviour for people who do not want a key\nthat has the same e-mail address, and because the choice of key is all\nabout security, the logic to choose which one shouldn't be changed\nlightly.\n"}]}