From: Junio C Hamano <junkio@cox.net>
To: ltuikov@yahoo.com
Cc: git@vger.kernel.org
Subject: Re: [PATCH] [checkout-index] Give names to stages
Date: Sun, 03 Dec 2006 22:32:34 -0800 [thread overview]
Message-ID: <7v7ix8rx19.fsf@assigned-by-dhcp.cox.net> (raw)
In-Reply-To: 505428.75434.qm@web31808.mail.mud.yahoo.com
Luben Tuikov <ltuikov@yahoo.com> writes:
> Sometimes when I pull things from a bunch of places and do
> a resolve, I'm presented with the standard resolve format of
> a source file, "<<<< ==== >>>>" thingie, and all I'd really
> like to do is "accept ours". I.e. something similar to what I've
> seen in other (commercial) SCMs, a la "scm resolve accept ours".
>
> This patch merely allows the user to say
> git-checkout-index --stage=ours their_broken_file.c
> instead of
> git-checkout-index --stage=2 their_broken_file.c
> and similarly for "theirs", etc.
That's _exactly_ my point. It "merely allows to".
> If you think this breaks the ideology, ok.
It's not about the ideology. It's in the part you quoted but
did not respond to (by the way, please don't quote the the bulk
of the message if you are not responding to it).
You stopped at only adding "ours" as synonym for "2" and did not
do anything else in the patch; it is a very sensible thing to
do, because "checkout-index" is a plumbing command that is about
checking out files from the index to the working tree.
But that means you HAVE TO stop at that because you are working
at the plumbing layer. You said yourself that what you really
wanted to do was "scm resolve accept ours". And from an end
user's point of view, "checkout --stage=ours" is NOT it.
A user who wants to see "accept ours" wants the scm to perform:
git checkout-index --stage=2 paths...
git update-index paths... ;# or Nico's "git add"
for him. That is why I suggested to hoist the place you
implement this usability improvement up one level and make the
Porcelain level command:
git checkout --ours paths...
to do the above two plumbing command sequence internally for the
end user.
next prev parent reply other threads:[~2006-12-04 6:32 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-03 9:49 [PATCH] [checkout-index] Give names to stages Luben Tuikov
2006-12-04 2:00 ` Junio C Hamano
2006-12-04 5:18 ` Luben Tuikov
2006-12-04 6:32 ` Junio C Hamano [this message]
2006-12-04 6:59 ` Luben Tuikov
2006-12-04 10:52 ` Johannes Schindelin
2006-12-04 11:36 ` Jakub Narebski
2006-12-04 11:39 ` Johannes Schindelin
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=7v7ix8rx19.fsf@assigned-by-dhcp.cox.net \
--to=junkio@cox.net \
--cc=git@vger.kernel.org \
--cc=ltuikov@yahoo.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox