{"thread":{"id":"6058","subject":"UI: git-tag should support -F as well","startedAt":"2006-12-21T11:52:53Z","lastAt":"2006-12-22T12:15:03Z","messageCount":5,"participants":["Han-Wen Nienhuys","Johannes Schindelin","Junio C Hamano","Shawn Pearce"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"29940","messageId":"emdsi9$ecm$1@sea.gmane.org","threadId":"6058","inReplyTo":null,"subject":"UI: git-tag should support -F as well","fromName":"Han-Wen Nienhuys","fromEmail":"hanwen@xs4all.nl","sentAt":"2006-12-21T11:52:53Z","receivedAt":"2006-12-21T11:52:53Z","isPatch":false,"sender":{"key":"hanwen@google.com","avatar":"https://avatars.githubusercontent.com/u/31547?v=4"},"body":"\nWorking on a little darcs2git script, I found the following inconsistency\n\ngit-commit supports -m and -F \ngit-tag supports only -m\n\n\n-- \n Han-Wen Nienhuys - hanwen@xs4all.nl - http://www.xs4all.nl/~hanwen\n"},{"id":"29951","messageId":"Pine.LNX.4.63.0612211512160.19693@wbgn013.biozentrum.uni-wuerzburg.de","threadId":"6058","inReplyTo":"emdsi9$ecm$1@sea.gmane.org","subject":"[PATCH] git-tag: support -F <file> option","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2006-12-21T14:13:02Z","receivedAt":"2006-12-21T14:13:02Z","isPatch":true,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"\nThis imitates the behaviour of git-commit.\n\nNoticed by Han-Wen Nienhuys.\n\nSigned-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>\n---\n\n\tOn Thu, 21 Dec 2006, Han-Wen Nienhuys wrote:\n\n\t> Working on a little darcs2git script, I found the following \n\t> inconsistency\n\t> \n\t> git-commit supports -m and -F \n\t> git-tag supports only -m\n\n\tHow about this?\n\n Documentation/git-tag.txt |    6 +++++-\n git-tag.sh                |   11 +++++++++++\n 2 files changed, 16 insertions(+), 1 deletions(-)\n\ndiff --git a/Documentation/git-tag.txt b/Documentation/git-tag.txt\nindex 45476c2..48b82b8 100644\n--- a/Documentation/git-tag.txt\n+++ b/Documentation/git-tag.txt\n@@ -9,7 +9,8 @@ git-tag - Create a tag object signed with GPG\n SYNOPSIS\n --------\n [verse]\n-'git-tag' [-a | -s | -u <key-id>] [-f | -d] [-m <msg>] <name> [<head>]\n+'git-tag' [-a | -s | -u <key-id>] [-f | -d] [-m <msg> | -F <file>]\n+\t <name> [<head>]\n 'git-tag' -l [<pattern>]\n \n DESCRIPTION\n@@ -60,6 +61,9 @@ OPTIONS\n -m <msg>::\n \tUse the given tag message (instead of prompting)\n \n+-F <file>::\n+\tTake the tag message from the given file.  Use '-' to\n+\tread the message from the standard input.\n \n Author\n ------\ndiff --git a/git-tag.sh b/git-tag.sh\nindex d53f94c..36cd6aa 100755\n--- a/git-tag.sh\n+++ b/git-tag.sh\n@@ -45,6 +45,17 @@ do\n \t    message_given=1\n \tfi\n \t;;\n+    -F)\n+\tannotate=1\n+\tshift\n+\tif test \"$#\" = \"0\"; then\n+\t    die \"error: option -F needs an argument\"\n+\t    exit 2\n+\telse\n+\t    message=\"$(cat \"$1\")\"\n+\t    message_given=1\n+\tfi\n+\t;;\n     -u)\n \tannotate=1\n \tsigned=1\n-- \n1.4.4.3.g0ba4\n"},{"id":"30016","messageId":"7vvek45svl.fsf@assigned-by-dhcp.cox.net","threadId":"6058","inReplyTo":"Pine.LNX.4.63.0612211512160.19693@wbgn013.biozentrum.uni-wuerzburg.de","subject":"Re: [PATCH] git-tag: support -F <file> option","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-12-22T06:47:42Z","receivedAt":"2006-12-22T06:47:42Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:\n\n> This imitates the behaviour of git-commit.\n>\n> Noticed by Han-Wen Nienhuys.\n>\n> Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>\n\nOk, but what the **** is \"die ...; exit 2\" sequence?\n\n> @@ -45,6 +45,17 @@ do\n>  \t    message_given=1\n>  \tfi\n>  \t;;\n> +    -F)\n> +\tannotate=1\n> +\tshift\n> +\tif test \"$#\" = \"0\"; then\n> +\t    die \"error: option -F needs an argument\"\n> +\t    exit 2\n> +\telse\n> +\t    message=\"$(cat \"$1\")\"\n> +\t    message_given=1\n> +\tfi\n> +\t;;\n\nI know it was copied from Han-Wen's aabd7693, but was this\nsomehow to catch the case where die can fail???\n"},{"id":"30017","messageId":"20061222065314.GB15548@spearce.org","threadId":"6058","inReplyTo":"7vvek45svl.fsf@assigned-by-dhcp.cox.net","subject":"Re: [PATCH] git-tag: support -F <file> option","fromName":"Shawn Pearce","fromEmail":"spearce@spearce.org","sentAt":"2006-12-22T06:53:14Z","receivedAt":"2006-12-22T06:53:14Z","isPatch":true,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"Junio C Hamano <junkio@cox.net> wrote:\n> > +\tif test \"$#\" = \"0\"; then\n> > +\t    die \"error: option -F needs an argument\"\n> > +\t    exit 2\n> > +\t;;\n> \n> I know it was copied from Han-Wen's aabd7693, but was this\n> somehow to catch the case where die can fail???\n\nWhat, you haven't heard of the /bin/resurrection shell?\n\nApparently one of its features is it can sometimes make die return\nsuccessfully, even days after the initial call.  :-)\n\n-- \nShawn.\n"},{"id":"30048","messageId":"Pine.LNX.4.63.0612221314310.19693@wbgn013.biozentrum.uni-wuerzburg.de","threadId":"6058","inReplyTo":"7vvek45svl.fsf@assigned-by-dhcp.cox.net","subject":"Re: [PATCH] git-tag: support -F <file> option","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2006-12-22T12:15:03Z","receivedAt":"2006-12-22T12:15:03Z","isPatch":true,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Thu, 21 Dec 2006, Junio C Hamano wrote:\n\n> Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:\n> \n> > This imitates the behaviour of git-commit.\n> >\n> > Noticed by Han-Wen Nienhuys.\n> >\n> > Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>\n> \n> Ok, but what the **** is \"die ...; exit 2\" sequence?\n\n;-) I did not even bother reading the code when I copied it.\n\nCiao,\nDscho\n"}]}