Subject: Re: [PATCH v2] ls-files.c: add --object-only option

From: Junio C Hamano <[email-masked]>
Date: Mon, 13 Jun 2022 10:19:12 -0700

ZheNing Hu <[email-masked]> writes:

> I think those atoms are undoubtedly necessary to keep
>
> %(tag)
> %(objectmode)
> %(objectname)
> %(stage)
> %(path)

I am not sure what you mean by "keep".  You cannot keep what you do
not have yet ;-)

If ls-files needs (that is a big if; it is a plumbing to be used by
whatever program that want to assemble the pieces, and it shouldn't
have to learn such assembly itself) to support "--format", so that
people can reinvent its "-s" output (but why?  There already is "-s"
output available), then the above would be necessary (assuming that
via the "--format" the user will be able to supply inter-field
spaces and tabs properly).  I do not know if there are other things
available in output other than the "-s" option produces offhand, but
if there are, they would need to be added for completeness.