Re: [RFC PATCH] short status: improve reporting for submodule changes
- From
Stefan Beller <sbeller@google.com>
- Date
- Mar 16, 2017, 05:16 UTC
- Message-ID
- <CAGZ79kZ7rWw=q6a2AomTw20DsU1h+7ou4i8A14a2bcg+asRwLA@mail.gmail.com>
- In-Reply-To
- <xmqqvarac8hc.fsf@gitster.mtv.corp.google.com>
On Wed, Mar 15, 2017 at 6:31 PM, Junio C Hamano <gitster@pobox.com> wrote:
Show 29 quoted lines
> Stefan Beller <sbeller@google.com> writes: > >> While we already have a porcelain2 layer for git-status, that is accurate >> for submodules, users still like the way they are are used to of >> 'status -s'. >> >> As a submodule has more state than a file potentially, we'll look at all >> cases: >> >> ------ new submodule commits >> / ----- modified files >> | / -- untracked files >> | | / >> | | | current / proposed reporting >> 0 0 0 " " " " >> 0 0 1 " M" " ?" >> 0 1 0 " M" " m" >> 0 1 1 " M" " m" >> 1 0 0 " M" " M" >> 1 0 1 " M" " M" >> 1 1 0 " M" " M" >> 1 1 1 " M" " M" > > You are essentialy saying that there are three levels, 1. with > commit level difference, 2. the same commit with local mods, 3. no > mods but with crufts, and instead of wasting 8 letters to express > all combinations, the highest level is reported, right? That sounds > OK to me. I am not sure if "?" is a good letter to use (doesn't it > usually mean it is an untracked cruft?), though.
ok. it helped me, though, to picture all possibilities to come up with what I consider best for each case. Yes in the end it can be described as 'report highest bit'.
Show 8 quoted lines
> > Does the commit level difference really mean "has new commits"? It > probably is not new problem but an old mistake inherited from the > current code, but I suspect that you're just comparing the commit > bound in the index of the superproject and the HEAD commit in the > submodule, in which case "newness" does not matter a bit---"is it > the same or different?" is the question you are asking, I would > think.
yes, I agree. That is the actual question asked.
> >