Re: [PATCHv4 1/3] wt-status.*: better advices for git status added
- From
Matthieu Moy <matthieu.moy@grenoble-inp.fr>
- Date
- May 31, 2012, 06:29 UTC
- Message-ID
- <vpqipfcsw1x.fsf@bauges.imag.fr>
- In-Reply-To
- <1338384216-18782-1-git-send-email-Lucien.Kong@ensimag.imag.fr>
Kong Lucien <Lucien.Kong@ensimag.imag.fr> writes:
> The new messages are not shown when using options such as > -s or --porcelain.The messages about the current
space between . and The (normally, 2 spaces in english).
Show 8 quoted lines
> --- a/Documentation/config.txt > +++ b/Documentation/config.txt > @@ -176,6 +179,7 @@ advice.*:: > Advice shown when you used linkgit:git-checkout[1] to > move to the detach HEAD state, to instruct how to create > a local branch after the fact. > + > --
Why add a blank line here?
Show 18 quoted lines
> + if (state->merge_in_progress) {
> + wt_status_merge_in_progress(s, state, state_color);
> + }
> + else if (state->am_in_progress) {
> + wt_status_am_in_progress(s, state, state_color);
> + }
> +
> + else if (state->rebase_in_progress || state->rebase_interactive_in_progress) {
> + wt_status_rebase_in_progress(s, state, state_color);
> + }
> +
> + else if (state->cherry_pick_in_progress) {
> + wt_status_cherry_pick_in_progress(s, state, state_color);
> + }
> +
> + if (state->bisect_in_progress) {
> + wt_status_bisect_in_progress(s, state, state_color);
> + }Do these have to be if/else if/... ?
In most cases, the user will have only one of these at the same time, but in the few cases where there's, e.g. a rebase during a bisect or so, I think it makes more sense to show both advices to the user (probably as a sign that something's wrong).
-- Matthieu Moy http://www-verimag.imag.fr/~moy/