Re: [PATCH v2] branch: show rebase/bisect info when possible instead of "(no branch)"
Matthieu Moy writes: > Just to be sure: "other" here is not a hardcoded message "bisecting > other", but an instance of "bisecting " with the branch > being called "other". OK, then I do not have any objection. Thanks. -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2] branch: show rebase/bisect info when possible instead of "(no branch)"
Junio C Hamano writes: > Matthieu Moy writes: > >> Nguyễn Thái Ngọc Duy writes: >> >>> --- a/t/t6030-bisect-porcelain.sh >>> +++ b/t/t6030-bisect-porcelain.sh >>> @@ -164,7 +164,7 @@ test_expect_success 'bisect start: existing >>> ".git/BISECT_START" not modified if >>> cp .git/BISECT_START saved && >>> test_must_fail git bisect start $HASH4 foo -- && >>> git branch > branch.output && >>> - test_i18ngrep "* (no branch)" branch.output > /dev/null && >>> + test_i18ngrep "* (bisecting other)" branch.output > /dev/null && [...] > What does "other" refer to when you start your bisection at a > detached head? If I read correctly, the branch name is shown only when the bisection was not started on a detached HEAD: + if (!get_sha1_hex(sb.buf, sha1)) + strbuf_addstr(&result, _("(bisecting)")); + else + strbuf_addf(&result, _("(bisecting %s)"), sb.buf); > I personally think "other" has _no_ value in that message, because > "(no branch, bisecting)" gives the same amount of information, > especially because "other" does not say which branch it refers to at > all. Just to be sure: "other" here is not a hardcoded message "bisecting other", but an instance of "bisecting " with the branch being called "other". I think this is very valuable information, and most likely the information you'd be looking for when running "git branch". You're technically on detached HEAD, but morally on some branch, the HEAD being detached only because a bisect is in progress. -- Matthieu Moy http://www-verimag.imag.fr/~moy/ -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2] branch: show rebase/bisect info when possible instead of "(no branch)"
On Mon, Feb 4, 2013 at 2:14 PM, Duy Nguyen wrote: > * foo (rebasing) Well, this one does not make sense (or causes more confusion). -- Duy -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2] branch: show rebase/bisect info when possible instead of "(no branch)"
On Mon, Feb 4, 2013 at 4:23 AM, Matthieu Moy wrote: > Nguyễn Thái Ngọc Duy writes: > >> --- a/t/t6030-bisect-porcelain.sh >> +++ b/t/t6030-bisect-porcelain.sh >> @@ -164,7 +164,7 @@ test_expect_success 'bisect start: existing >> ".git/BISECT_START" not modified if >> cp .git/BISECT_START saved && >> test_must_fail git bisect start $HASH4 foo -- && >> git branch > branch.output && >> - test_i18ngrep "* (no branch)" branch.output > /dev/null && >> + test_i18ngrep "* (bisecting other)" branch.output > /dev/null && > > I'd have spelled it (no branch, bisecting other) to make it clear that > we're on detached HEAD, and avoid confusing old-timers. But maybe your > version is enough, I'm not sure. If we want to make it clear, I think the standard "* (no branch)" should become * HEAD (detached) or non-detached case: * HEAD -> foo Then we could present rebase/bisect information as * HEAD (detached, bisecting) * HEAD (detached, rebasing) * foo (rebasing) I don't want to make this line too long because it would break (well, waste space in) column layout. So if we do this, no branch name added for rebase/bisect. -- Duy -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2] branch: show rebase/bisect info when possible instead of "(no branch)"
Junio C Hamano writes: > Yeah, I do not think "bisecting other" alone makes much sense. > > What does "other" refer to when you start your bisection at a > detached head? I personally think "other" has _any_ value in that s/_any_/_no_/; obviously ;-) > message, because "(no branch, bisecting)" gives the same amount of > information, especially because "other" does not say which branch it > refers to at all. -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2] branch: show rebase/bisect info when possible instead of "(no branch)"
Matthieu Moy writes: > Nguyễn Thái Ngọc Duy writes: > >> --- a/t/t6030-bisect-porcelain.sh >> +++ b/t/t6030-bisect-porcelain.sh >> @@ -164,7 +164,7 @@ test_expect_success 'bisect start: existing >> ".git/BISECT_START" not modified if >> cp .git/BISECT_START saved && >> test_must_fail git bisect start $HASH4 foo -- && >> git branch > branch.output && >> -test_i18ngrep "* (no branch)" branch.output > /dev/null && >> +test_i18ngrep "* (bisecting other)" branch.output > /dev/null && > > I'd have spelled it (no branch, bisecting other) to make it clear that > we're on detached HEAD, and avoid confusing old-timers. But maybe your > version is enough, I'm not sure. Yeah, I do not think "bisecting other" alone makes much sense. What does "other" refer to when you start your bisection at a detached head? I personally think "other" has _any_ value in that message, because "(no branch, bisecting)" gives the same amount of information, especially because "other" does not say which branch it refers to at all. -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH v2] branch: show rebase/bisect info when possible instead of "(no branch)"
Nguyễn Thái Ngọc Duy writes: > --- a/t/t6030-bisect-porcelain.sh > +++ b/t/t6030-bisect-porcelain.sh > @@ -164,7 +164,7 @@ test_expect_success 'bisect start: existing > ".git/BISECT_START" not modified if > cp .git/BISECT_START saved && > test_must_fail git bisect start $HASH4 foo -- && > git branch > branch.output && > - test_i18ngrep "* (no branch)" branch.output > /dev/null && > + test_i18ngrep "* (bisecting other)" branch.output > /dev/null && I'd have spelled it (no branch, bisecting other) to make it clear that we're on detached HEAD, and avoid confusing old-timers. But maybe your version is enough, I'm not sure. -- Matthieu Moy http://www-verimag.imag.fr/~moy/ -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html