git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 2/4] completion: complete --patch-with-raw

From
Junio C Hamano <gitster@pobox.com>
Date
Jan 22, 2024, 16:09 UTC
Message-ID
<xmqqo7ddcptt.fsf@gitster.g>
In-Reply-To
<1debe2fe18eec7f431f355241117afb0a5e2bf5f.1705810072.git.gitgitgadget@gmail.com>
"Philippe Blain via GitGitGadget" <gitgitgadget@gmail.com> writes:
Show 18 quoted lines
> From: Philippe Blain <levraiphilippeblain@gmail.com>
>
> Signed-off-by: Philippe Blain <levraiphilippeblain@gmail.com>
> ---
>  contrib/completion/git-completion.bash | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
> index 6108d523a11..ccb17f4ad7b 100644
> --- a/contrib/completion/git-completion.bash
> +++ b/contrib/completion/git-completion.bash
> @@ -1807,7 +1807,7 @@ __git_diff_common_options="--stat --numstat --shortstat --summary
>  			--output= --output-indicator-context=
>  			--output-indicator-new= --output-indicator-old=
>  			--ws-error-highlight=
> -			--pickaxe-all --pickaxe-regex
> +			--pickaxe-all --pickaxe-regex --patch-with-raw
>  "

Its ancient company, --patch-with-stat, is listed there, so it is not all that wrong to include it as a suggestion, I guess.

But in the longer term, I think we would want to slim "git diff -h" output by hiding them (no reason to touch code to remove the support) from the "common diff options" part. They were added as a kludge before I realized we need more than these two combinations and made the options --patch, --stat, and --raw cumulative.

Thanks.
Previous: Philippe Blain via GitGitGadgetNext: Philippe Blain via GitGitGadget
Message 4 of 6 in “completion: add missing 'git log' options”
  1. 0/4 completion: add missing 'git log' optionsPhilippe Blain via GitGitGadget, Jan 21, 2024
  2. 1/4 completion: complete missing rev-list optionsPhilippe Blain via GitGitGadget, Jan 21, 2024
  3. 2/4 completion: complete --patch-with-rawPhilippe Blain via GitGitGadget, Jan 21, 2024
  4. Junio C HamanoJan 22, 2024
  5. 3/4 completion: complete --encodingPhilippe Blain via GitGitGadget, Jan 21, 2024
  6. 4/4 completion: complete missing 'git log' optionsPhilippe Blain via GitGitGadget, Jan 21, 2024

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.