{"thread":{"id":"60777","subject":"[PATCH 0/4] completion: add missing 'git log' options","startedAt":"2024-01-21T04:07:55Z","lastAt":"2024-01-22T16:09:43Z","messageCount":6,"participants":["Philippe Blain via GitGitGadget","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":4},"messages":[{"id":"487164","messageId":"pull.1650.git.git.1705810071.gitgitgadget@gmail.com","threadId":"60777","inReplyTo":null,"subject":"[PATCH 0/4] completion: add missing 'git log' options","fromName":"Philippe Blain via GitGitGadget","fromEmail":"gitgitgadget@gmail.com","sentAt":"2024-01-21T04:07:47Z","receivedAt":"2024-01-21T04:07:55Z","isPatch":true,"sender":{"key":"levraiphilippeblain@gmail.com","avatar":"https://avatars.githubusercontent.com/u/44212482?v=4"},"body":"I noticed a few 'git log' options (old and newish) were not suggested by the\ncompletion script, so I went through the whole list and added those that\nwere missing.\n\nPhilippe Blain (4):\n  completion: complete missing rev-list options\n  completion: complete --patch-with-raw\n  completion: complete --encoding\n  completion: complete missing 'git log' options\n\n contrib/completion/git-completion.bash | 15 ++++++++++++++-\n 1 file changed, 14 insertions(+), 1 deletion(-)\n\n\nbase-commit: e02ecfcc534e2021aae29077a958dd11c3897e4c\nPublished-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-1650%2Fphil-blain%2Fcompletion-log-options-v1\nFetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-1650/phil-blain/completion-log-options-v1\nPull-Request: https://github.com/git/git/pull/1650\n-- \ngitgitgadget\n"},{"id":"487165","messageId":"2f72ef0d5f83678de86f4773a547d10e57053300.1705810072.git.gitgitgadget@gmail.com","threadId":"60777","inReplyTo":"pull.1650.git.git.1705810071.gitgitgadget@gmail.com","subject":"[PATCH 1/4] completion: complete missing rev-list options","fromName":"Philippe Blain via GitGitGadget","fromEmail":"gitgitgadget@gmail.com","sentAt":"2024-01-21T04:07:48Z","receivedAt":"2024-01-21T04:07:55Z","isPatch":true,"sender":{"key":"levraiphilippeblain@gmail.com","avatar":"https://avatars.githubusercontent.com/u/44212482?v=4"},"body":"From: Philippe Blain <levraiphilippeblain@gmail.com>\n\nSome options listed in rev-list-options.txt, and thus accepted by 'git\nlog' and friends, are missing from the Bash completion script.\n\nAdd them to __git_log_common_options.\n\nSigned-off-by: Philippe Blain <levraiphilippeblain@gmail.com>\n---\n contrib/completion/git-completion.bash | 10 ++++++++++\n 1 file changed, 10 insertions(+)\n\ndiff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash\nindex 8c40ade4941..6108d523a11 100644\n--- a/contrib/completion/git-completion.bash\n+++ b/contrib/completion/git-completion.bash\n@@ -2071,6 +2071,16 @@ __git_log_common_options=\"\n \t--min-age= --until= --before=\n \t--min-parents= --max-parents=\n \t--no-min-parents --no-max-parents\n+\t--alternate-refs --ancestry-path\n+\t--author-date-order --basic-regexp\n+\t--bisect --boundary --exclude-first-parent-only\n+\t--exclude-hidden --extended-regexp\n+\t--fixed-strings --grep-reflog\n+\t--ignore-missing --left-only --perl-regexp\n+\t--reflog --regexp-ignore-case --remove-empty\n+\t--right-only --show-linear-break\n+\t--show-notes-by-default --show-pulls\n+\t--since-as-filter --single-worktree\n \"\n # Options that go well for log and gitk (not shortlog)\n __git_log_gitk_options=\"\n-- \ngitgitgadget\n\n"},{"id":"487166","messageId":"1debe2fe18eec7f431f355241117afb0a5e2bf5f.1705810072.git.gitgitgadget@gmail.com","threadId":"60777","inReplyTo":"pull.1650.git.git.1705810071.gitgitgadget@gmail.com","subject":"[PATCH 2/4] completion: complete --patch-with-raw","fromName":"Philippe Blain via GitGitGadget","fromEmail":"gitgitgadget@gmail.com","sentAt":"2024-01-21T04:07:49Z","receivedAt":"2024-01-21T04:07:56Z","isPatch":true,"sender":{"key":"levraiphilippeblain@gmail.com","avatar":"https://avatars.githubusercontent.com/u/44212482?v=4"},"body":"From: Philippe Blain <levraiphilippeblain@gmail.com>\n\nSigned-off-by: Philippe Blain <levraiphilippeblain@gmail.com>\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 6108d523a11..ccb17f4ad7b 100644\n--- a/contrib/completion/git-completion.bash\n+++ b/contrib/completion/git-completion.bash\n@@ -1807,7 +1807,7 @@ __git_diff_common_options=\"--stat --numstat --shortstat --summary\n \t\t\t--output= --output-indicator-context=\n \t\t\t--output-indicator-new= --output-indicator-old=\n \t\t\t--ws-error-highlight=\n-\t\t\t--pickaxe-all --pickaxe-regex\n+\t\t\t--pickaxe-all --pickaxe-regex --patch-with-raw\n \"\n \n # Options for diff/difftool\n-- \ngitgitgadget\n\n"},{"id":"487167","messageId":"faa601ecb92b301d5730474efd11fba27d6a5cc7.1705810072.git.gitgitgadget@gmail.com","threadId":"60777","inReplyTo":"pull.1650.git.git.1705810071.gitgitgadget@gmail.com","subject":"[PATCH 3/4] completion: complete --encoding","fromName":"Philippe Blain via GitGitGadget","fromEmail":"gitgitgadget@gmail.com","sentAt":"2024-01-21T04:07:50Z","receivedAt":"2024-01-21T04:07:57Z","isPatch":true,"sender":{"key":"levraiphilippeblain@gmail.com","avatar":"https://avatars.githubusercontent.com/u/44212482?v=4"},"body":"From: Philippe Blain <levraiphilippeblain@gmail.com>\n\nThe option --encoding is supported by 'git log' and 'git show', so add\nit to __git_log_show_options.\n\nSigned-off-by: Philippe Blain <levraiphilippeblain@gmail.com>\n---\n contrib/completion/git-completion.bash | 1 +\n 1 file changed, 1 insertion(+)\n\ndiff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash\nindex ccb17f4ad7b..a7ae2cbe55b 100644\n--- a/contrib/completion/git-completion.bash\n+++ b/contrib/completion/git-completion.bash\n@@ -2096,6 +2096,7 @@ __git_log_shortlog_options=\"\n # Options accepted by log and show\n __git_log_show_options=\"\n \t--diff-merges --diff-merges= --no-diff-merges --dd --remerge-diff\n+\t--encoding=\n \"\n \n __git_diff_merges_opts=\"off none on first-parent 1 separate m combined c dense-combined cc remerge r\"\n-- \ngitgitgadget\n\n"},{"id":"487168","messageId":"9991dd4bfa6747dccc12c8a5d9fe8d6ed95fdb52.1705810072.git.gitgitgadget@gmail.com","threadId":"60777","inReplyTo":"pull.1650.git.git.1705810071.gitgitgadget@gmail.com","subject":"[PATCH 4/4] completion: complete missing 'git log' options","fromName":"Philippe Blain via GitGitGadget","fromEmail":"gitgitgadget@gmail.com","sentAt":"2024-01-21T04:07:51Z","receivedAt":"2024-01-21T04:07:58Z","isPatch":true,"sender":{"key":"levraiphilippeblain@gmail.com","avatar":"https://avatars.githubusercontent.com/u/44212482?v=4"},"body":"From: Philippe Blain <levraiphilippeblain@gmail.com>\n\nSome options specific to 'git log' are missing from the Bash completion\nscript. Add them to _git_log.\n\nSigned-off-by: Philippe Blain <levraiphilippeblain@gmail.com>\n---\n contrib/completion/git-completion.bash | 2 ++\n 1 file changed, 2 insertions(+)\n\ndiff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash\nindex a7ae2cbe55b..2f1412d85ea 100644\n--- a/contrib/completion/git-completion.bash\n+++ b/contrib/completion/git-completion.bash\n@@ -2180,6 +2180,8 @@ _git_log ()\n \t\t\t--no-walk --no-walk= --do-walk\n \t\t\t--parents --children\n \t\t\t--expand-tabs --expand-tabs= --no-expand-tabs\n+\t\t\t--clear-decorations --decorate-refs=\n+\t\t\t--decorate-refs-exclude=\n \t\t\t$merge\n \t\t\t$__git_diff_common_options\n \t\t\t\"\n-- \ngitgitgadget\n"},{"id":"487209","messageId":"xmqqo7ddcptt.fsf@gitster.g","threadId":"60777","inReplyTo":"1debe2fe18eec7f431f355241117afb0a5e2bf5f.1705810072.git.gitgitgadget@gmail.com","subject":"Re: [PATCH 2/4] completion: complete --patch-with-raw","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2024-01-22T16:09:34Z","receivedAt":"2024-01-22T16:09:43Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Philippe Blain via GitGitGadget\" <gitgitgadget@gmail.com> writes:\n\n> From: Philippe Blain <levraiphilippeblain@gmail.com>\n>\n> Signed-off-by: Philippe Blain <levraiphilippeblain@gmail.com>\n> ---\n>  contrib/completion/git-completion.bash | 2 +-\n>  1 file changed, 1 insertion(+), 1 deletion(-)\n>\n> diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash\n> index 6108d523a11..ccb17f4ad7b 100644\n> --- a/contrib/completion/git-completion.bash\n> +++ b/contrib/completion/git-completion.bash\n> @@ -1807,7 +1807,7 @@ __git_diff_common_options=\"--stat --numstat --shortstat --summary\n>  \t\t\t--output= --output-indicator-context=\n>  \t\t\t--output-indicator-new= --output-indicator-old=\n>  \t\t\t--ws-error-highlight=\n> -\t\t\t--pickaxe-all --pickaxe-regex\n> +\t\t\t--pickaxe-all --pickaxe-regex --patch-with-raw\n>  \"\n\nIts ancient company, --patch-with-stat, is listed there, so it is\nnot all that wrong to include it as a suggestion, I guess.\n\nBut in the longer term, I think we would want to slim \"git diff -h\"\noutput by hiding them (no reason to touch code to remove the\nsupport) from the \"common diff options\" part.  They were added as a\nkludge before I realized we need more than these two combinations\nand made the options --patch, --stat, and --raw cumulative.\n\nThanks.\n"}]}