docs: document caveats of rev-list's object-name output
commit15364d2a3cef397442033a3fec27d57007ca1c51
authorJeff King <peff@peff.net>
Tue, 28 Mar 2023 18:26:50 +0000 (28 14:26 -0400)
committerJunio C Hamano <gitster@pobox.com>
Tue, 28 Mar 2023 19:55:00 +0000 (28 12:55 -0700)
tree975a0378ca91c4d0dbf06fff6018b8e9ac77cfaf
parent7556e5d737b917d31ac3729b0f5e2391da7e132a
docs: document caveats of rev-list's object-name output

At first glance, the names given by "rev-list --objects" seem like a
good way to see which paths are present in a set of commits. But there
are some subtle gotchas there. We do not document the format of the
names at all, so let's do so, along with warning of these problems.

I intentionally did not document the exact format of the names here, as
I don't think it's something we want people to rely on (though I doubt
in practice that we'd change it at this point).

Though all of this is historically tied to "--objects", these days we
have a separate "--object-names" flag which can turn the names off or
on. So I put the detailed documentation there, but added a note from
--objects (which did not otherwise mention the names at all, even though
they are on by default).

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/rev-list-options.txt