From: Quentin Bernet <quentin.bernet@bluewin.ch>
To: Junio C Hamano <gitster@pobox.com>
Cc: Mirko Faina <mroik@delayed.space>,
"D. Ben Knoble" <ben.knoble@gmail.com>,
Quentin Bernet via GitGitGadget <gitgitgadget@gmail.com>,
git@vger.kernel.org
Subject: Re: [PATCH] docs: fix git stash grammar
Date: Fri, 27 Mar 2026 17:58:19 +0100 [thread overview]
Message-ID: <9d0befb7-4f2b-4b47-bf9c-784fcacfe418@bluewin.ch> (raw)
In-Reply-To: <xmqq7bqxkyd5.fsf@gitster.g>
Just so we're clear: my previous grammar did allow "git stash path1
path2" (no "push", no "--"), which is not allowed
Do you still think it is good enough ?
"the command line description needs to mention that." that is already
the case, no ?
On 3/27/26 17:53, Junio C Hamano wrote:
> Quentin Bernet <quentin.bernet@bluewin.ch> writes:
>
>> My previous, simpler, grammar included "git stash <pathspec>" even
>> though it is not valid.
> "git stash -- path1 path2 ..." is valid and is taken as elliding the
> subcommand name 'push'. So I think your previous one is good enough
> but the command line description needs to mention that. Double dash
> is used to signal the start of pathspec when ambiguous, and it is a
> good example to highlight when it is useful. Without disambiguating
> "--", "path1" might be misspelt subcommand name but we cannot tell
> which one. You may even have a file whose name is "pop", and "git
> stash -- pop" would be a way to save away the changes to the file
> without having to say "push" explicitly ;-)
>
next prev parent reply other threads:[~2026-03-27 17:00 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-26 12:45 [PATCH] docs: fix git stash grammar Quentin Bernet via GitGitGadget
2026-03-26 16:17 ` D. Ben Knoble
2026-03-27 0:04 ` Mirko Faina
2026-03-27 15:58 ` Junio C Hamano
2026-03-27 16:28 ` Quentin Bernet
2026-03-27 16:53 ` Junio C Hamano
2026-03-27 16:58 ` Quentin Bernet [this message]
2026-03-27 17:16 ` Junio C Hamano
2026-03-27 17:36 ` Quentin Bernet
2026-03-27 17:45 ` Junio C Hamano
2026-03-27 16:47 ` Ben Knoble
2026-03-27 8:25 ` Quentin Bernet
2026-03-30 13:24 ` [PATCH v2] docs: fix "git stash [push]" documentation Quentin Bernet via GitGitGadget
2026-03-30 15:18 ` Junio C Hamano
2026-03-30 17:19 ` Quentin Bernet
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9d0befb7-4f2b-4b47-bf9c-784fcacfe418@bluewin.ch \
--to=quentin.bernet@bluewin.ch \
--cc=ben.knoble@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitgitgadget@gmail.com \
--cc=gitster@pobox.com \
--cc=mroik@delayed.space \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.