git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "brian m. carlson" <sandals@crustytoothpaste.net>
To: "Martin Ågren" <martin.agren@gmail.com>
Cc: Junio C Hamano <gitster@pobox.com>,
	git@vger.kernel.org, Elijah Newren <newren@gmail.com>,
	Phillip Wood <phillip.wood123@gmail.com>,
	Eric Sunshine <sunshine@sunshineco.com>,
	Taylor Blau <me@ttaylorr.com>
Subject: Re: [PATCH v3 1/2] git-merge-file doc: drop "-file" from argument placeholders
Date: Thu, 2 Nov 2023 09:18:15 +0000	[thread overview]
Message-ID: <ZUNpVyQYUT8TA6An@tapette.crustytoothpaste.net> (raw)
In-Reply-To: <CAN0heSrv7MPcEwkq4uEtv9uBbqm4FLKQLE3gdsEbqKkxPXOj5A@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 2013 bytes --]

On 2023-11-02 at 08:53:36, Martin Ågren wrote:
> On Thu, 2 Nov 2023 at 00:53, Junio C Hamano <gitster@pobox.com> wrote:
> >
> > "brian m. carlson" <sandals@crustytoothpaste.net> writes:
> >
> > > From: Martin Ågren <martin.agren@gmail.com>
> > >
> > > `git merge-file` takes three positional arguments. Each of them is
> > > documented as `<foo-file>`. In preparation for teaching this command to
> > > alternatively take three object IDs, make these placeholders a bit more
> >
> > Minor nit.  Don't we want to say "three blob object names"?  Unless
> > we plan to grow this feature into accepting three tree object names,
> > that is.
> 
> Hmm, yeah. Or just "three non-filename arguments". I do wonder: doesn't
> this mean that the second patch could/should possibly move away from the
> notion of "object ID"/`--object-id`? (That's not trying to shift any
> blame from one patch to the other, that's my honest reaction.)

Not specifying an option would make this ambiguous.  What if I have a
file named "e69de29bb2d1d6434b8b29ae775ad8c2e48c5391"?  Is that the
empty blob, or is it that file?  Normally we have ways to disambiguate
this, but those don't work here because of the positional arguments.

> Ah, yes, I thought I recognized this. Quoting your response [1] to v2:
> 
> > I briefly thought about suggesting --blob-id instead of --object-id
> > simply because you'd never want to feed it trees and commits, but
> > the error message from read_mmblob() the users would get mentions
> > 'blob' to signal that non-blob objects are unwelcome, so the name of
> > the optionwould be OK as-is.
> 
> Maybe you having a similar reaction a second time makes this smell a bit
> more?

I think the name is fine.  We don't typically use the phrase "blob ID"
anywhere, but we do say "object ID".  We'd need to say "--blob", but
I'm not sure that's an improvement, and I fear it may be less
understandable.
-- 
brian m. carlson (he/him or they/them)
Toronto, Ontario, CA

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 262 bytes --]

  reply	other threads:[~2023-11-02  9:18 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-24 19:56 [PATCH 0/1] Object ID support for git merge-file brian m. carlson
2023-10-24 19:56 ` [PATCH 1/1] merge-file: add an option to process object IDs brian m. carlson
2023-10-24 20:12   ` Eric Sunshine
2023-10-24 21:23     ` brian m. carlson
2023-10-29  6:17   ` Elijah Newren
2023-10-29 10:12     ` Phillip Wood
2023-10-30 16:14       ` brian m. carlson
2023-10-29 14:18     ` brian m. carlson
2023-10-30 16:39       ` Elijah Newren
2023-10-29  6:24 ` [PATCH 0/1] Object ID support for git merge-file Elijah Newren
2023-10-29 10:15   ` Phillip Wood
2023-10-30 15:54   ` Taylor Blau
2023-10-30 16:24     ` brian m. carlson
2023-10-30 17:14       ` Elijah Newren
2023-10-30 16:26 ` [PATCH v2 " brian m. carlson
2023-10-30 16:26   ` [PATCH v2 1/1] merge-file: add an option to process object IDs brian m. carlson
2023-10-31 21:48     ` Martin Ågren
2023-10-31 22:31       ` brian m. carlson
2023-11-01  3:44         ` Junio C Hamano
2023-11-01 19:16           ` brian m. carlson
2023-10-30 17:15   ` [PATCH v2 0/1] Object ID support for git merge-file Elijah Newren
2023-10-31  0:03     ` Junio C Hamano
2023-10-31 11:05   ` Phillip Wood
2023-10-31 23:06     ` Junio C Hamano
2023-11-01 19:24 ` [PATCH v3 0/2] " brian m. carlson
2023-11-01 19:24   ` [PATCH v3 1/2] git-merge-file doc: drop "-file" from argument placeholders brian m. carlson
2023-11-01 23:53     ` Junio C Hamano
2023-11-02  8:53       ` Martin Ågren
2023-11-02  9:18         ` brian m. carlson [this message]
2023-11-02  9:29           ` Martin Ågren
2023-11-02 16:28         ` Junio C Hamano
2023-11-01 19:24   ` [PATCH v3 2/2] merge-file: add an option to process object IDs brian m. carlson
2023-11-02  8:51     ` Martin Ågren
2023-11-01 23:55   ` [PATCH v3 0/2] Object ID support for git merge-file Junio C Hamano

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=ZUNpVyQYUT8TA6An@tapette.crustytoothpaste.net \
    --to=sandals@crustytoothpaste.net \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=martin.agren@gmail.com \
    --cc=me@ttaylorr.com \
    --cc=newren@gmail.com \
    --cc=phillip.wood123@gmail.com \
    --cc=sunshine@sunshineco.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).