{"thread":{"id":"41248","subject":"PATCH 1/2] Update the flags for git show-branch","startedAt":"2016-01-23T01:23:24Z","lastAt":"2016-02-22T13:02:50Z","messageCount":10,"participants":["Paul Wagland","Junio C Hamano","SZEDER Gábor"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"276605","messageId":"20160123012316.GA27965@wagland.net","threadId":"41248","inReplyTo":null,"subject":"[PATCH 0/2] Update BASH completions","fromName":"Paul Wagland","fromEmail":"paul@kungfoocoder.org","sentAt":"2016-01-23T01:23:24Z","receivedAt":"2016-01-23T01:23:24Z","isPatch":true,"sender":{"key":"paul@kungfoocoder.org","avatar":null},"body":"While playing around git stash I noticed that some options were\nmissing. I have updated these in the BASH completions file. Note\nthat this is not a comprehensive review, but adds the options that\nI use in git-stash, and a nearby missing option.\n\nPaul Wagland (2):\n  Update the flags for git show-branch\n  Fix up the arguments for git stash. This adds the branch to the branch\n    subcommand, and adds the missing options to save and drop commands\n\n contrib/completion/git-completion.bash | 19 +++++++++++++++----\n 1 file changed, 15 insertions(+), 4 deletions(-)\n\n--\n2.7.0\n"},{"id":"276603","messageId":"20160123012554.GA28197@wagland.net","threadId":"41248","inReplyTo":"20160123012316.GA27965@wagland.net","subject":"PATCH 1/2] Update the flags for git show-branch","fromName":"Paul Wagland","fromEmail":"paul@kungfoocoder.org","sentAt":"2016-01-23T01:25:54Z","receivedAt":"2016-01-23T01:25:54Z","isPatch":false,"sender":{"key":"paul@kungfoocoder.org","avatar":null},"body":"Signed-off-by: Paul Wagland <paul@kungfoocoder.org>\n---\n contrib/completion/git-completion.bash | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\ndiff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash\nindex ab4da7f..63754bc 100644\n--- a/contrib/completion/git-completion.bash\n+++ b/contrib/completion/git-completion.bash\n@@ -2369,7 +2369,7 @@ _git_show_branch ()\n \tcase \"$cur\" in\n \t--*)\n \t\t__gitcomp \"\n-\t\t\t--all --remotes --topo-order --current --more=\n+\t\t\t--all --remotes --topo-order --date-order --current --more=\n \t\t\t--list --independent --merge-base --no-name\n \t\t\t--color --no-color\n \t\t\t--sha1-name --sparse --topics --reflog\n--\n2.7.0\n"},{"id":"276604","messageId":"20160123013049.GB28197@wagland.net","threadId":"41248","inReplyTo":"20160123012316.GA27965@wagland.net","subject":"[PATCH 2/2] Fix up the arguments for git stash.","fromName":"Paul Wagland","fromEmail":"paul@kungfoocoder.org","sentAt":"2016-01-23T01:30:50Z","receivedAt":"2016-01-23T01:30:50Z","isPatch":true,"sender":{"key":"paul@kungfoocoder.org","avatar":null},"body":"Signed-off-by: Paul Wagland <paul@kungfoocoder.org>\n---\n contrib/completion/git-completion.bash | 17 ++++++++++++++---\n 1 file changed, 14 insertions(+), 3 deletions(-)\n\ndiff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash\nindex 63754bc..043d5bb 100644\n--- a/contrib/completion/git-completion.bash\n+++ b/contrib/completion/git-completion.bash\n@@ -2382,7 +2382,7 @@ _git_show_branch ()\n \n _git_stash ()\n {\n-\tlocal save_opts='--keep-index --no-keep-index --quiet --patch'\n+\tlocal save_opts='--all --keep-index --no-keep-index --quiet --patch --include-untracked'\n \tlocal subcommands='save list show apply clear drop pop create branch'\n \tlocal subcommand=\"$(__git_find_on_cmdline \"$subcommands\")\"\n \tif [ -z \"$subcommand\" ]; then\n@@ -2404,9 +2404,20 @@ _git_stash ()\n \t\tapply,--*|pop,--*)\n \t\t\t__gitcomp \"--index --quiet\"\n \t\t\t;;\n-\t\tshow,--*|drop,--*|branch,--*)\n+\t\tdrop,--*)\n+\t\t\t__gitcomp \"--quiet\"\n \t\t\t;;\n-\t\tshow,*|apply,*|drop,*|pop,*|branch,*)\n+\t\tshow,--*|branch,--*)\n+\t\t\t;;\n+\t\tbranch,*)\n+\t\t\tif [ $cword -eq 3 ]; then\n+\t\t\t__gitcomp_nl \"$(__git_refs)\";\n+\t\t\telse\n+\t\t\t\t__gitcomp_nl \"$(git --git-dir=\"$(__gitdir)\" stash list \\\n+\t\t\t\t\t\t| sed -n -e 's/:.*//p')\"\n+\t\t\tfi\n+\t\t\t;;\n+\t\tshow,*|apply,*|drop,*|pop,*)\n \t\t\t__gitcomp_nl \"$(git --git-dir=\"$(__gitdir)\" stash list \\\n \t\t\t\t\t| sed -n -e 's/:.*//p')\"\n \t\t\t;;\n-- \n2.7.0\n"},{"id":"276746","messageId":"xmqqmvrtdzb1.fsf@gitster.mtv.corp.google.com","threadId":"41248","inReplyTo":"20160123012554.GA28197@wagland.net","subject":"Re: PATCH 1/2] Update the flags for git show-branch","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2016-01-25T23:17:22Z","receivedAt":"2016-01-25T23:17:22Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Thanks.  I'll retitle this to\n\n    completion: complete show-branch \"--date-order\"\n\nwhile queuing.\n"},{"id":"276747","messageId":"xmqqio2hdz48.fsf@gitster.mtv.corp.google.com","threadId":"41248","inReplyTo":"20160123013049.GB28197@wagland.net","subject":"Re: [PATCH 2/2] Fix up the arguments for git stash.","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2016-01-25T23:21:27Z","receivedAt":"2016-01-25T23:21:27Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Paul Wagland <paul@kungfoocoder.org> writes:\n\n> Signed-off-by: Paul Wagland <paul@kungfoocoder.org>\n> ---\n\nThis needs a better explanation than just \"Fix up\" in the title.\nWhat is broken in the current behaviour and what is the more desired\nbehaviour?\n\nThanks.\n\n>  contrib/completion/git-completion.bash | 17 ++++++++++++++---\n>  1 file changed, 14 insertions(+), 3 deletions(-)\n>\n> diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash\n> index 63754bc..043d5bb 100644\n> --- a/contrib/completion/git-completion.bash\n> +++ b/contrib/completion/git-completion.bash\n> @@ -2382,7 +2382,7 @@ _git_show_branch ()\n>  \n>  _git_stash ()\n>  {\n> -\tlocal save_opts='--keep-index --no-keep-index --quiet --patch'\n> +\tlocal save_opts='--all --keep-index --no-keep-index --quiet --patch --include-untracked'\n>  \tlocal subcommands='save list show apply clear drop pop create branch'\n>  \tlocal subcommand=\"$(__git_find_on_cmdline \"$subcommands\")\"\n>  \tif [ -z \"$subcommand\" ]; then\n> @@ -2404,9 +2404,20 @@ _git_stash ()\n>  \t\tapply,--*|pop,--*)\n>  \t\t\t__gitcomp \"--index --quiet\"\n>  \t\t\t;;\n> -\t\tshow,--*|drop,--*|branch,--*)\n> +\t\tdrop,--*)\n> +\t\t\t__gitcomp \"--quiet\"\n>  \t\t\t;;\n> -\t\tshow,*|apply,*|drop,*|pop,*|branch,*)\n> +\t\tshow,--*|branch,--*)\n> +\t\t\t;;\n> +\t\tbranch,*)\n> +\t\t\tif [ $cword -eq 3 ]; then\n> +\t\t\t__gitcomp_nl \"$(__git_refs)\";\n> +\t\t\telse\n> +\t\t\t\t__gitcomp_nl \"$(git --git-dir=\"$(__gitdir)\" stash list \\\n> +\t\t\t\t\t\t| sed -n -e 's/:.*//p')\"\n> +\t\t\tfi\n> +\t\t\t;;\n> +\t\tshow,*|apply,*|drop,*|pop,*)\n>  \t\t\t__gitcomp_nl \"$(git --git-dir=\"$(__gitdir)\" stash list \\\n>  \t\t\t\t\t| sed -n -e 's/:.*//p')\"\n>  \t\t\t;;\n"},{"id":"276757","messageId":"C8776441-3B93-42D3-A759-0AA918F0F97C@kungfoocoder.org","threadId":"41248","inReplyTo":"xmqqio2hdz48.fsf@gitster.mtv.corp.google.com","subject":"Re: [PATCH 2/2] Fix up the arguments for git stash.","fromName":"Paul Wagland","fromEmail":"paul@kungfoocoder.org","sentAt":"2016-01-26T06:21:06Z","receivedAt":"2016-01-26T06:21:06Z","isPatch":true,"sender":{"key":"paul@kungfoocoder.org","avatar":null},"body":"Fair enough. I'll re-roll the patches with improved comments, and get these out to the list today. \n\nCheers,\nPaul\n\nSent from my iPhone\n\n> On 26 Jan 2016, at 00:21, Junio C Hamano <gitster@pobox.com> wrote:\n> \n> Paul Wagland <paul@kungfoocoder.org> writes:\n> \n>> Signed-off-by: Paul Wagland <paul@kungfoocoder.org>\n>> ---\n> \n> This needs a better explanation than just \"Fix up\" in the title.\n> What is broken in the current behaviour and what is the more desired\n> behaviour?\n> \n> Thanks.\n"},{"id":"276770","messageId":"20160126093429.GA77046@wagland.net","threadId":"41248","inReplyTo":"20160123012316.GA27965@wagland.net","subject":"[PATCH v2 0/2] Update BASH completions","fromName":"Paul Wagland","fromEmail":"paul@kungfoocoder.org","sentAt":"2016-01-26T09:34:29Z","receivedAt":"2016-01-26T09:34:29Z","isPatch":true,"sender":{"key":"paul@kungfoocoder.org","avatar":null},"body":"While playing around git stash I noticed that some options were\nmissing. I have updated these in the BASH completions file. Note\nthat this is not a comprehensive review, but adds the options that\nI use in git-stash, and a nearby missing option.\n\nThis re-roll doesn't change the code, but updates the commit comments\nto make it clearer what each change is doing.\n\nPaul Wagland (2):\n  Update the flags for git show-branch\n  Fix up the arguments for git stash. This adds the branch to the branch\n    subcommand, and adds the missing options to save and drop commands\n\n contrib/completion/git-completion.bash | 19 +++++++++++++++----\n 1 file changed, 15 insertions(+), 4 deletions(-)\n\n--\n2.7.0\n"},{"id":"276772","messageId":"20160126093616.GB77046@wagland.net","threadId":"41248","inReplyTo":"20160126093429.GA77046@wagland.net","subject":"[PATCH v2 1/2] completion: complete show-branch \"--date-order\"","fromName":"Paul Wagland","fromEmail":"paul@kungfoocoder.org","sentAt":"2016-01-26T09:36:16Z","receivedAt":"2016-01-26T09:36:16Z","isPatch":true,"sender":{"key":"paul@kungfoocoder.org","avatar":null},"body":"\nSigned-off-by: Paul Wagland <paul@kungfoocoder.org>\n---\n contrib/completion/git-completion.bash | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\ndiff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash\nindex ab4da7f..63754bc 100644\n--- a/contrib/completion/git-completion.bash\n+++ b/contrib/completion/git-completion.bash\n@@ -2369,7 +2369,7 @@ _git_show_branch ()\n \tcase \"$cur\" in\n \t--*)\n \t\t__gitcomp \"\n-\t\t\t--all --remotes --topo-order --current --more=\n+\t\t\t--all --remotes --topo-order --date-order --current --more=\n \t\t\t--list --independent --merge-base --no-name\n \t\t\t--color --no-color\n \t\t\t--sha1-name --sparse --topics --reflog\n-- \n2.7.0\n"},{"id":"276773","messageId":"20160126093718.GC77046@wagland.net","threadId":"41248","inReplyTo":"20160126093429.GA77046@wagland.net","subject":"[PATCH v2 2/4] completion: update completion arguments for stash","fromName":"Paul Wagland","fromEmail":"paul@kungfoocoder.org","sentAt":"2016-01-26T09:37:19Z","receivedAt":"2016-01-26T09:37:19Z","isPatch":true,"sender":{"key":"paul@kungfoocoder.org","avatar":null},"body":"\nAdd --all and --include-untracked to the git stash save completions.\nAdd --quiet to the git stash drop completions.\nUpdate git stash branch so that the first argument expands out to the\npossible branch names, and the other arguments expand to the stash\nnames.\n\nSigned-off-by: Paul Wagland <paul@kungfoocoder.org>\n---\n contrib/completion/git-completion.bash | 17 ++++++++++++++---\n 1 file changed, 14 insertions(+), 3 deletions(-)\n\ndiff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash\nindex 63754bc..043d5bb 100644\n--- a/contrib/completion/git-completion.bash\n+++ b/contrib/completion/git-completion.bash\n@@ -2382,7 +2382,7 @@ _git_show_branch ()\n \n _git_stash ()\n {\n-\tlocal save_opts='--keep-index --no-keep-index --quiet --patch'\n+\tlocal save_opts='--all --keep-index --no-keep-index --quiet --patch --include-untracked'\n \tlocal subcommands='save list show apply clear drop pop create branch'\n \tlocal subcommand=\"$(__git_find_on_cmdline \"$subcommands\")\"\n \tif [ -z \"$subcommand\" ]; then\n@@ -2404,9 +2404,20 @@ _git_stash ()\n \t\tapply,--*|pop,--*)\n \t\t\t__gitcomp \"--index --quiet\"\n \t\t\t;;\n-\t\tshow,--*|drop,--*|branch,--*)\n+\t\tdrop,--*)\n+\t\t\t__gitcomp \"--quiet\"\n \t\t\t;;\n-\t\tshow,*|apply,*|drop,*|pop,*|branch,*)\n+\t\tshow,--*|branch,--*)\n+\t\t\t;;\n+\t\tbranch,*)\n+\t\t  if [ $cword -eq 3 ]; then\n+  \t\t\t__gitcomp_nl \"$(__git_refs)\";\n+\t\t\telse\n+\t\t\t\t__gitcomp_nl \"$(git --git-dir=\"$(__gitdir)\" stash list \\\n+\t\t\t\t\t\t| sed -n -e 's/:.*//p')\"\n+\t\t\tfi\n+\t\t\t;;\n+\t\tshow,*|apply,*|drop,*|pop,*)\n \t\t\t__gitcomp_nl \"$(git --git-dir=\"$(__gitdir)\" stash list \\\n \t\t\t\t\t| sed -n -e 's/:.*//p')\"\n \t\t\t;;\n-- \n2.7.0\n"},{"id":"278881","messageId":"1456146170-17556-1-git-send-email-szeder@ira.uka.de","threadId":"41248","inReplyTo":"20160126093718.GC77046@wagland.net","subject":"[PATCH] completion: fix mis-indentation in _git_stash()","fromName":"SZEDER Gábor","fromEmail":"szeder@ira.uka.de","sentAt":"2016-02-22T13:02:50Z","receivedAt":"2016-02-22T13:02:50Z","isPatch":true,"sender":{"key":"szeder.dev@gmail.com","avatar":"https://avatars.githubusercontent.com/u/116324?v=4"},"body":"Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>\n---\n contrib/completion/git-completion.bash | 4 ++--\n 1 file changed, 2 insertions(+), 2 deletions(-)\n\ndiff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash\nindex 45ec47f2b1b4..e3918c87e3ad 100644\n--- a/contrib/completion/git-completion.bash\n+++ b/contrib/completion/git-completion.bash\n@@ -2415,8 +2415,8 @@ _git_stash ()\n \t\tshow,--*|branch,--*)\n \t\t\t;;\n \t\tbranch,*)\n-\t\t  if [ $cword -eq 3 ]; then\n-\t\t\t__gitcomp_nl \"$(__git_refs)\";\n+\t\t\tif [ $cword -eq 3 ]; then\n+\t\t\t\t__gitcomp_nl \"$(__git_refs)\";\n \t\t\telse\n \t\t\t\t__gitcomp_nl \"$(git --git-dir=\"$(__gitdir)\" stash list \\\n \t\t\t\t\t\t| sed -n -e 's/:.*//p')\"\n-- \n2.7.1.384.g61d9461\n"}]}