From: Jakub Narebski <jnareb@gmail.com>
To: git@vger.kernel.org
Subject: Re: Rename handling
Date: Wed, 21 Mar 2007 01:06:33 +0100 [thread overview]
Message-ID: <etpson$qih$1@sea.gmane.org> (raw)
In-Reply-To: 45FEE2B2.6050904@midwinter.com
Steven Grimm wrote:
> The following is actually my biggest beef with git's rename tracking,
> and it has nothing whatsoever to do with git-log (though I agree git-log
> needs to track renames too):
>
> $ ls
> dir1
> $ ls dir1
> file1 file2 file3
> $ echo "#include file1" > dir1/file4
> $ git add dir1/file4
> $ git commit
> $ git pull
> $ ls
> dir1 dir2
> $ ls dir1
> file4
> $ ls dir2
> file1 file2 file3
>
> That's just plain broken in my opinion. One can perhaps contrive a test
> case or two where that's the desired behavior, but in the real world it
> is almost never what you actually want.
>
> By the way, I don't think fixing that is necessarily related to how
> renames get detected, so in some sense it's a different bug report /
> feature request than the rename hints one. It would be possible to
> figure out the directory had been renamed based purely on content
> analysis; a bunch of files all individually renamed to the same places
> under a new directory, and a lack of any files at all left in the old
> one, probably means the directory got renamed. The content-based rename
> detector could handle this case.
Actually this came out in some earlier talk about recording renames
and renames detection (IIRC in the big thread about VCS comparison which
used to be on Bazaar-NG wiki). And one of the arguments about why directory
rename doesn't work as _you_ expected is (beside that it is not that
easy to code) the fact that the alternate solution (new files going
to old subdir) can be correct and expected by _others_.
--
Jakub Narebski
Warsaw, Poland
ShadeHawk on #git
next prev parent reply other threads:[~2007-03-21 0:04 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-19 16:10 Rename handling John Goerzen
2007-03-19 18:14 ` Steven Grimm
2007-03-19 18:35 ` Nicolas Pitre
2007-03-19 18:48 ` Linus Torvalds
2007-03-19 19:57 ` Steven Grimm
2007-03-19 20:19 ` Martin Langhoff
2007-03-20 8:33 ` Junio C Hamano
2007-03-19 20:22 ` Linus Torvalds
2007-03-19 20:02 ` Robin Rosenberg
2007-03-19 20:34 ` Linus Torvalds
2007-03-19 19:36 ` Steven Grimm
2007-03-19 19:45 ` Steven Grimm
2007-03-19 20:07 ` Linus Torvalds
2007-03-19 20:17 ` Nicolas Pitre
2007-03-19 20:44 ` Daniel Barkalow
2007-03-19 19:03 ` Andy Parkins
2007-03-19 19:21 ` Steven Grimm
2007-03-21 0:06 ` Jakub Narebski [this message]
2007-03-21 0:25 ` Johannes Schindelin
2007-03-21 22:28 ` Steven Grimm
2007-03-21 23:01 ` Johannes Schindelin
2007-03-21 23:10 ` Linus Torvalds
2007-03-22 0:10 ` Martin Langhoff
2007-03-22 2:01 ` Jakub Narebski
2007-03-22 2:39 ` Martin Langhoff
2007-03-22 3:32 ` Jakub Narebski
2007-03-22 3:53 ` Linus Torvalds
2007-03-19 19:15 ` Daniel Barkalow
2007-03-19 19:49 ` John Goerzen
2007-03-19 22:27 ` Junio C Hamano
2007-03-21 0:21 ` Jakub Narebski
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='etpson$qih$1@sea.gmane.org' \
--to=jnareb@gmail.com \
--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).