{"thread":{"id":"33281","subject":"[PATCH] log: make \"show --show-signature\" use gpg.program setting","startedAt":"2013-03-25T18:03:52Z","lastAt":"2013-03-27T15:59:15Z","messageCount":3,"participants":["Hans Brigman","Jeff King","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"212191","messageId":"8C726954D36902459248B0627BF2E66F45D7029930@AUSP01VMBX10.collaborationhost.net","threadId":"33281","inReplyTo":null,"subject":"[PATCH] log: make \"show --show-signature\" use gpg.program setting","fromName":"Hans Brigman","fromEmail":"hbrigman@openspan.com","sentAt":"2013-03-25T18:03:52Z","receivedAt":"2013-03-25T18:03:52Z","isPatch":true,"sender":{"key":"hbrigman@openspan.com","avatar":null},"body":"\"show --show-signature\" doesn't currently use the gpg.program setting.  Commit signing, tag signing, and tag verification currently use this setting properly, so the logic has been added to handle it here as well.\n\nSigned-off-by: Hans Brigman <hbrigman@openspan.com>\n---\n builtin/log.c | 4 +++-\n 1 file changed, 3 insertions(+), 1 deletion(-)\n\ndiff --git a/builtin/log.c b/builtin/log.c\nindex 8f0b2e8..a6c5576 100644\n--- a/builtin/log.c\n+++ b/builtin/log.c\n@@ -23,6 +23,7 @@\n #include \"streaming.h\"\n #include \"version.h\"\n #include \"mailmap.h\"\n+#include \"gpg-interface.h\"\n \n /* Set a default date-time format for git log (\"log.date\" config variable) */\n static const char *default_date_mode = NULL;\n@@ -364,7 +365,8 @@ static int git_log_config(const char *var, const char *value, void *cb)\n \t\tuse_mailmap_config = git_config_bool(var, value);\n \t\treturn 0;\n \t}\n-\n+\tif (!prefixcmp(var, \"gpg.\"))\n+\t\treturn git_gpg_config(var, value, NULL); \n \tif (grep_config(var, value, cb) < 0)\n \t\treturn -1;\n \treturn git_diff_ui_config(var, value, cb);\n-- \n1.7.11.msysgit.0\n\n\n\nFrom 5e0b3de93e90750ea8d3f5c897861886647672b4 Mon Sep 17 00:00:00 2001\nFrom: Hans Brigman <datyedyeguy@gmail.com>\nDate: Fri, 22 Mar 2013 16:41:06 -0400\nSubject: [PATCH] log: make \"show --show-signature\" use gpg.program setting\n\n\"show --show-signature\" doesn't currently use the gpg.program setting.  Commit signing, tag signing, and tag verification currently use this setting properly, so the logic has been added to handle it here as well.\n\nSigned-off-by: Hans Brigman <datyedyeguy@gmail.com>\n---\n builtin/log.c | 4 +++-\n 1 file changed, 3 insertions(+), 1 deletion(-)\n\ndiff --git a/builtin/log.c b/builtin/log.c\nindex 8f0b2e8..a6c5576 100644\n--- a/builtin/log.c\n+++ b/builtin/log.c\n@@ -23,6 +23,7 @@\n #include \"streaming.h\"\n #include \"version.h\"\n #include \"mailmap.h\"\n+#include \"gpg-interface.h\"\n \n /* Set a default date-time format for git log (\"log.date\" config variable) */\n static const char *default_date_mode = NULL;\n@@ -364,7 +365,8 @@ static int git_log_config(const char *var, const char *value, void *cb)\n \t\tuse_mailmap_config = git_config_bool(var, value);\n \t\treturn 0;\n \t}\n-\n+\tif (!prefixcmp(var, \"gpg.\"))\n+\t\treturn git_gpg_config(var, value, NULL); \n \tif (grep_config(var, value, cb) < 0)\n \t\treturn -1;\n \treturn git_diff_ui_config(var, value, cb);\n-- \n1.7.11.msysgit.0\n\n"},{"id":"212226","messageId":"20130325213453.GB19303@sigill.intra.peff.net","threadId":"33281","inReplyTo":"8C726954D36902459248B0627BF2E66F45D7029930@AUSP01VMBX10.collaborationhost.net","subject":"Re: [PATCH] log: make \"show --show-signature\" use gpg.program setting","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2013-03-25T21:34:53Z","receivedAt":"2013-03-25T21:34:53Z","isPatch":true,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Mon, Mar 25, 2013 at 01:03:52PM -0500, Hans Brigman wrote:\n\n> \"show --show-signature\" doesn't currently use the gpg.program setting.  Commit signing, tag signing, and tag verification currently use this setting properly, so the logic has been added to handle it here as well.\n\nPlease wrap your commit messages at something reasonable (70 is probably\nas high as you want to go, given that log output is often shown\nindented).\n\n> @@ -364,7 +365,8 @@ static int git_log_config(const char *var, const char *value, void *cb)\n>  \t\tuse_mailmap_config = git_config_bool(var, value);\n>  \t\treturn 0;\n>  \t}\n> -\n> +\tif (!prefixcmp(var, \"gpg.\"))\n> +\t\treturn git_gpg_config(var, value, NULL); \n>  \tif (grep_config(var, value, cb) < 0)\n>  \t\treturn -1;\n\nThe gpg config can also be other places than \"gpg.*\". Right now it is\njust user.signingkey, which log would not care about, but it feels like\nwe are depending an unnecessary detail here. We also don't know whether\nit would care about the callback data. Is there a reason not to do:\n\n  if (git_gpg_config(var, value, cb) < 0)\n          return -1;\n\njust like the grep_config call below?\n\n-Peff\n"},{"id":"212389","messageId":"7vzjxoomuk.fsf@alter.siamese.dyndns.org","threadId":"33281","inReplyTo":"20130325213453.GB19303@sigill.intra.peff.net","subject":"Re: [PATCH] log: make \"show --show-signature\" use gpg.program setting","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2013-03-27T15:59:15Z","receivedAt":"2013-03-27T15:59:15Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Jeff King <peff@peff.net> writes:\n\n> On Mon, Mar 25, 2013 at 01:03:52PM -0500, Hans Brigman wrote:\n>\n>> \"show --show-signature\" doesn't currently use the gpg.program setting.  Commit signing, tag signing, and tag verification currently use this setting properly, so the logic has been added to handle it here as well.\n>\n> Please wrap your commit messages at something reasonable (70 is probably\n> as high as you want to go, given that log output is often shown\n> indented).\n\nThanks for pointing out Documentation/SubmittingPatches.\n\nAlso please do not send multipart/mixed (or alternative).  Send\npatches in text/plain.\n\n>> @@ -364,7 +365,8 @@ static int git_log_config(const char *var, const char *value, void *cb)\n>>  \t\tuse_mailmap_config = git_config_bool(var, value);\n>>  \t\treturn 0;\n>>  \t}\n>> -\n>> +\tif (!prefixcmp(var, \"gpg.\"))\n>> +\t\treturn git_gpg_config(var, value, NULL); \n>>  \tif (grep_config(var, value, cb) < 0)\n>>  \t\treturn -1;\n>\n> The gpg config can also be other places than \"gpg.*\". Right now it is\n> just user.signingkey, which log would not care about, but it feels like\n> we are depending an unnecessary detail here. We also don't know whether\n> it would care about the callback data. Is there a reason not to do:\n>\n>   if (git_gpg_config(var, value, cb) < 0)\n>           return -1;\n>\n> just like the grep_config call below?\n>\n> -Peff\n"}]}