From: Mischa POSLAWSKY <shiar@shiar.nl>
To: git@vger.kernel.org
Subject: conflict merging directory replaced by symlink
Date: Fri, 29 Oct 2010 19:32:32 +0200 [thread overview]
Message-ID: <20101029173232.GA9869@pearl.mediadesign.nl> (raw)
Hello list,
After replacing a directory by a symlink, branches without that change will
conflict whenever they change something unrelated in the link target.
To illustrate:
git init &&
mkdir common &&
touch common/test &&
git add common/test &&
mkdir dupe &&
touch dupe/test &&
git add dupe/test &&
git commit -m 'initial setup' &&
git rm -r dupe &&
ln -s common dupe &&
git add dupe &&
git commit -m 'replace dir by symlink' &&
git checkout -b prelink HEAD^ &&
touch common/irrelevant &&
git add common/irrelevant &&
git commit -m 'additional common file' &&
git checkout - &&
git merge prelink
fails in git v1.7.2.3 with:
> CONFLICT (file/directory): There is a directory with name dupe in prelink.
> Adding dupe as dupe~HEAD
> Automatic merge failed; fix conflicts and then commit the result.
I'd expect the same resolution as when adding a symlink from a different
name, without replacing the directory, but this happily merges without
raising a fuss.
Does anyone recognise or know a reason for this behaviour?
Thanks!
--
Mischa
reply other threads:[~2010-10-29 17:39 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20101029173232.GA9869@pearl.mediadesign.nl \
--to=shiar@shiar.nl \
--cc=git@vger.kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).