Re: [PATCH/RFC] Add [] as an alias for a reference to the empty tree
- From
Jonathan Nieder <jrnieder@gmail.com>
- Date
- May 8, 2010, 16:07 UTC
- Message-ID
- <20100508160731.GA4638@progeny.tock>
- In-Reply-To
- <7vhbmjc6dy.fsf@alter.siamese.dyndns.org>
Junio C Hamano wrote:
> The reason I am not interested in the feature > is because I don't see much value in running "git diff EMPTY <anything>". > Perhaps "git archive" might be what the user really wants to find.
I suspect the goal was to use a tool such as checkpatch, or get_maintainer without -f. An implementation using git archive should still work (with the help of a tar diff-ing program with the EMPTY feature ;-)), but as UI that might be less discoverable than building it into git diff.
Personally, I liked both the
git diff $(</dev/null git hash-object -t tree --stdin) $rev
and
git diff --root $rev
suggestions. That may be from a warped sense of aesthetics.
Cheers, Jonathan