public inbox for linux-pm@vger.kernel.org
 help / color / mirror / Atom feed
From: Linus Torvalds <torvalds@linux-foundation.org>
To: Len Brown <lenb@kernel.org>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	linux-acpi@vger.kernel.org,
	Linux Power Management List <linux-pm@lists.osdl.org>
Subject: Re: git mv (was Re: [git pull] ACPI & Suspend patches for 2.6.29-rc0)
Date: Fri, 9 Jan 2009 13:16:12 -0800 (PST)	[thread overview]
Message-ID: <alpine.LFD.2.00.0901091305160.6528@localhost.localdomain> (raw)
In-Reply-To: <alpine.LFD.2.00.0901091537530.16697@localhost.localdomain>



On Fri, 9 Jan 2009, Len Brown wrote:
> 
> I guess using 'git mv' gave me the false expectation
> that git actually tracks moves like other SCMs
> and it would show up that way in the diff -- though
> now that I think about it, I like the comparison
> of the two endpoints that git did even better.

The main reason "git mv" exists at all is just people migrating from other 
places expecting it. It's largely just purely synthetic sugar - it has 
almost no meaning to git long-term.

[ Technically, it _is_ meaningful, in that it obviously not just moves the 
  file in the checked-out copy, but it also moves the index information 
  around. So "git mv" clearly does something, but it's not important in 
  the big picture.

  So using "git mv" is really nothing fundamental - it doesn't really 
  matter to the end result, and if you had done the 'mv' by just applying 
  a patch to delete the old file and create a new one, the actual commit 
  would have been 100% identical. Think of it as a convenience function, 
  and you won't be wrong. ]

> gitk doesn't use --follow by default, and when it is added, the history 
> looks pretty strange.

Heh. That's because "--follow" is a total hack, and doesn't do the nice 
(and pretty complicated) parent rewriting that the real "git log" family 
of operations normally do.

So yeah, "--follow" is broken. It's really a quick hack there for people 
who come from some other SCM to feel more comfy with git. If you come from 
SVN or CVS, you never had proper history, and you never had "gitk" anyway, 
and so "gitk --follow" doesn't really work. But it makes the pure 
_textual_ logs look a bit like CVS/SVN.

I'd love to make --follow work better and integrate more, but I've been so 
successful at never using it myself that I don't much care. And it really 
is not a very natural thing for git to do, so the hackiness is somewhat 
inherent.

			Linus

  reply	other threads:[~2009-01-09 21:16 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-09 10:55 [git pull] ACPI & Suspend patches for 2.6.29-rc0 Len Brown
2009-01-09 20:12 ` Linus Torvalds
2009-01-09 20:56   ` git mv (was Re: [git pull] ACPI & Suspend patches for 2.6.29-rc0) Len Brown
2009-01-09 21:16     ` Linus Torvalds [this message]
2009-01-09 21:27       ` Sam Ravnborg
2009-01-09 21:40         ` Linus Torvalds
2009-01-09 21:47         ` Harvey Harrison
2009-01-09 21:58           ` Linus Torvalds

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=alpine.LFD.2.00.0901091305160.6528@localhost.localdomain \
    --to=torvalds@linux-foundation.org \
    --cc=akpm@linux-foundation.org \
    --cc=lenb@kernel.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@lists.osdl.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