From: Jeff King <peff@peff.net>
To: Mark Kharitonov <mark.kharitonov@gmail.com>
Cc: Duy Nguyen <pclouds@gmail.com>, Elijah Newren <newren@gmail.com>,
Git Mailing List <git@vger.kernel.org>
Subject: Re: Can git tell me which uncommitted files clash with the incoming changes?
Date: Tue, 18 Dec 2018 08:14:29 -0500 [thread overview]
Message-ID: <20181218131429.GE30471@sigill.intra.peff.net> (raw)
In-Reply-To: <CAG2YSPy85YtAv6m5WR4ZrsZ4TRzgcyrC4DNZnOONtFD6MsH=YQ@mail.gmail.com>
On Mon, Dec 17, 2018 at 05:50:31PM -0500, Mark Kharitonov wrote:
> Guys, having git merge --dry-run would be great, but I am OK with git
> merge for real as long as its output is parseable.
>
> However, somewhere in between git 2.18 and git 2.20 the output of
> merge changed and now I do not know how to parse it.
> it used to be something like that:
>
> bla bla bla
> <tab>file name 1
> <tab>file name 2
> ...
> bla bla bla
>
> But now, the files are output in one line and given that some files
> may have spaces in the name I do not see how this can be parsed. If we
> could have easily parseable output of merge, it would be enough for
> me.
Interesting. I don't see that behavior at all. E.g., running this:
-- >8 --
git init repo
cd repo
echo base >base; git add base; git commit -m base
for i in one two three; do
echo $i >$i
done
git add .
git commit -m master
git checkout -b other HEAD^
echo other >other; git add other; git commit -m other
for i in one two three; do
echo working-tree >$i
done
git pull . master
-- 8< --
I see:
error: The following untracked working tree files would be overwritten by merge:
one
three
two
Please move or remove them before you merge.
I wonder if it has to do with Windows.
If you can reproduce it at will, can you try bisecting between v2.18 and
v2.20 to see which commit introduced the change?
-Peff
next prev parent reply other threads:[~2018-12-18 13:14 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-17 13:08 Can git tell me which uncommitted files clash with the incoming changes? Mark Kharitonov
2018-12-17 16:21 ` Jeff King
2018-12-17 18:49 ` Ævar Arnfjörð Bjarmason
2018-12-17 19:35 ` Jeff King
2018-12-17 16:24 ` Duy Nguyen
2018-12-17 17:17 ` Elijah Newren
2018-12-17 19:37 ` Duy Nguyen
2018-12-17 22:50 ` Mark Kharitonov
2018-12-18 13:14 ` Jeff King [this message]
2018-12-18 15:51 ` Elijah Newren
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=20181218131429.GE30471@sigill.intra.peff.net \
--to=peff@peff.net \
--cc=git@vger.kernel.org \
--cc=mark.kharitonov@gmail.com \
--cc=newren@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox