git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Linus Torvalds <torvalds@linux-foundation.org>
To: Robin Rosenberg <robin.rosenberg.lists@dewire.com>
Cc: Nicolas Pitre <nico@cam.org>, Steven Grimm <koreth@midwinter.com>,
	John Goerzen <jgoerzen@complete.org>,
	git@vger.kernel.org
Subject: Re: Rename handling
Date: Mon, 19 Mar 2007 13:34:27 -0700 (PDT)	[thread overview]
Message-ID: <Pine.LNX.4.64.0703191323490.6730@woody.linux-foundation.org> (raw)
In-Reply-To: <200703192102.20258.robin.rosenberg.lists@dewire.com>



On Mon, 19 Mar 2007, Robin Rosenberg wrote:
> 
> How about this simple receipe for defeating rename tracking (real world):
> 
> User needs to modify A. User renames A to OLD_A within his/her IDE. SCM
> records the rename. User now uses SaveAs to restore A, and SCM detects the 
> *NEW* file A.

Well, the thing is, I don't think that's a very strong argument against 
rename tracking.

You can always make trivial examples of when something goes wrong. 
Computers (and SCM's) are stupid, and they simply do what they are told. 
Just about *any* policy can be trivially show to be "totally broken" by 
having a user do something - usually something very simple - that breaks 
it on purpose.

Similarly, I don't think it's hard to show examples of where git's 
"content is king" does something that the user thinks could be done much 
better. And similarly, I don't think that's an argument against the 
content model that git uses.

No, the reason I like the content model is that there is never any hidden 
state that doesn't matter for the user. If you're a physicist, you could 
say that yhere is never any "action at a distance" with git. There are no 
hidden linkages that aren't obvious in the source tree that you commit or 
work on.

In contrast, the very *definition* of "explicit rename tracking" is to 
track those hidden linkages. They aren't visible to the developer, except 
when they clash, and that very invisibility is what makes both mistakes so 
easy (anybody who claims that they never do a rename as a del/add pair is 
simply lying or not doing very interesting development) *and* it is what 
makes handling merges so hard (because when there is a conflict, the 
conflict isn't actually in anything that is *visible*!).

I also pretty much guarantee that the reason git development has been so 
fast, stable and trouble-free comes exactly from the simple conceptual 
mindset and very concrete implementation. There simply are never any 
subtle issues. Content is content is content. It has no "history". Yes, 
git shows history, but it's literally a "series of snapshots", and the 
trees that are checked out are totally history-less. 

In contrast, if you have file rename tracking, then those trees are no 
longer stateless - they have an implied history associated with them, that 
matters. It's largely *invisible*, but that just makes it worse!

			Linus

  reply	other threads:[~2007-03-19 20:35 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 [this message]
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
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=Pine.LNX.4.64.0703191323490.6730@woody.linux-foundation.org \
    --to=torvalds@linux-foundation.org \
    --cc=git@vger.kernel.org \
    --cc=jgoerzen@complete.org \
    --cc=koreth@midwinter.com \
    --cc=nico@cam.org \
    --cc=robin.rosenberg.lists@dewire.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;
as well as URLs for NNTP newsgroup(s).