From: Michael J Gruber <git@drmicha.warpmail.net>
To: Junio C Hamano <gitster@pobox.com>,
Dennis Kaarsemaker <dennis@kaarsemaker.net>
Cc: git@vger.kernel.org, "Nguyễn Thái Ngọc Duy" <pclouds@gmail.com>
Subject: Re: [PATCH] checkout: indicate when a detached head is checked out for a branch
Date: Mon, 21 Jul 2014 15:03:28 +0200 [thread overview]
Message-ID: <53CD0FA0.1030600@drmicha.warpmail.net> (raw)
In-Reply-To: <xmqqpph2l39d.fsf@gitster.dls.corp.google.com>
Junio C Hamano venit, vidit, dixit 19.07.2014 00:18:
> Dennis Kaarsemaker <dennis@kaarsemaker.net> writes:
>
>> My use case for this is checking out the same branch (or commit, so
>> already on a detached HEAD) in multiple different places to run
>> independent actions (e.g. make test with different compiler options, or
>> creating several different packages) and I would really appreciate it if
>> that would keep working.
>
> I do not have any problem if multiple working trees have the same
> commit checked out on their own detached HEADs at all. The "should
> error out" was solely for the case where the user asked not to detach
> but to obtain a state where a named branch is checked out. In such
> a case, the command should not turn it into a detached HEAD, with or
> without a warning.
Exactly, all of that, plus:
* "git checkout --detach --to foo bar" could/should be a way to spell out
"git checkout --to foo bar^0".
* In the case of erroring out, "git checkout" could suggest one of the
above two commands.
Michael
prev parent reply other threads:[~2014-07-21 13:03 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-18 9:50 [PATCH] checkout: indicate when a detached head is checked out for a branch Michael J Gruber
2014-07-18 10:58 ` Duy Nguyen
2014-07-18 13:27 ` Michael J Gruber
2014-07-18 14:13 ` Max Kirillov
2014-07-18 17:36 ` Junio C Hamano
2014-07-18 21:54 ` Dennis Kaarsemaker
2014-07-18 22:18 ` Junio C Hamano
2014-07-21 13:03 ` Michael J Gruber [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=53CD0FA0.1030600@drmicha.warpmail.net \
--to=git@drmicha.warpmail.net \
--cc=dennis@kaarsemaker.net \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=pclouds@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.