All of lore.kernel.org
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: David Turner <dturner@twopensource.com>
Cc: git@vger.kernel.org, David Turner <dturner@twitter.com>
Subject: Re: [PATCH v5 3/3] cat-file: add --follow-symlinks to --batch
Date: Thu, 14 May 2015 13:06:39 -0700	[thread overview]
Message-ID: <xmqqiobukjow.fsf@gitster.dls.corp.google.com> (raw)
In-Reply-To: <1431455779.16652.20.camel@ubuntu> (David Turner's message of "Tue, 12 May 2015 14:36:19 -0400")

David Turner <dturner@twopensource.com> writes:

> On Tue, 2015-05-12 at 11:07 -0700, Junio C Hamano wrote:
>
>>  * Is it fundamental that this is only for --batch family, or is it
>>    just lack of need by the current implementor and implementation?
>>    "git cat-file --follow-symlinks blob :RelNotes" does not sound
>>    a nonsense request to me.
>
> The reason that --follow-symlinks doesn't work for non-batch requests is
> that it is impossible to distinguish out-of-tree symlinks from valid
> output in non-batch output. I will add text explaining this. 

Actually, I do not think that is a valid reason not to consider
supporting "git cat-file --follow-symlinks blob :RelNotes" in future
versions of Git.  "--batch" and "--batch-check" needs to continue,
so it needs to give diagnosis in-line in its output and let the
driving script continue talking with it, but a single-shot request
"git cat-file --follow-symlinks blob :RelNotes" can signal that
the link does not resolve in-tree (or in-index) by erroring out.

So I still view it as "we currently do not need it outside --batch;
if somebody wants to, feel free to add it to non-batch mode".  It
does not have to be called a bug but I would say it is a missing
feature.  And not handling an in-index path e.g. :RelNotes falls
into the same category, I would say.

Just to avoid misunderstanding, I still think this series (at its
9th iteration) is good from the point of new feature without filling
these two missing features.

      parent reply	other threads:[~2015-05-14 20:06 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-11 22:50 [PATCH v5 0/3] cat-file --follow-symlinks dturner
2015-05-11 22:50 ` [PATCH v5 1/3] tree-walk: learn get_tree_entry_follow_symlinks dturner
2015-05-12 17:29   ` Johannes Sixt
2015-05-11 22:50 ` [PATCH v5 2/3] sha1_name: get_sha1_with_context learns to follow symlinks dturner
2015-05-11 22:50 ` [PATCH v5 3/3] cat-file: add --follow-symlinks to --batch dturner
2015-05-12 17:34   ` Johannes Sixt
2015-05-12 18:07   ` Junio C Hamano
2015-05-12 18:36     ` David Turner
2015-05-12 18:43       ` Junio C Hamano
2015-05-12 18:55         ` David Turner
2015-05-12 20:00           ` Junio C Hamano
2015-05-12 20:22             ` Junio C Hamano
2015-05-12 22:36               ` David Turner
2015-05-12 23:02                 ` Junio C Hamano
2015-05-12 23:06                   ` Junio C Hamano
2015-05-12 20:07       ` Junio C Hamano
2015-05-12 21:37         ` David Turner
2015-05-12 21:42           ` Junio C Hamano
2015-05-12 21:53             ` David Turner
2015-05-14 20:06       ` Junio C Hamano [this message]

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=xmqqiobukjow.fsf@gitster.dls.corp.google.com \
    --to=gitster@pobox.com \
    --cc=dturner@twitter.com \
    --cc=dturner@twopensource.com \
    --cc=git@vger.kernel.org \
    /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.