Re: [PATCH 0/5] Laptop driver documentation changes for 2.6.25

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, 09 Feb 2008, Carlos Corbacho wrote:
> On Saturday 09 February 2008 18:22:17 Henrique de Moraes Holschuh wrote:
> > BTW Carlos, sending a git diff would have resulted in much smaller diffs
> > (since git diff can do renames instead of add/delete) :)  I believe all of
> > us can deal just fine with git diffs, so it makes sense to use them in
> > these cases.
> 
> I don't quite know what you mean here - experimenting in a tree here, git-diff 
> doesn't produce any noticeable difference after using git-mv - unless this is 
> a bug with StackedGit being unable to handle renames/ moves properly?

Randy sent you a much better email than mine about it, but here it goes:

hmh@thorin:/tmp/f$ git init 
Initialized empty Git repository in .git/
hmh@thorin:/tmp/f$ cp /var/log/Xorg.0.log .
hmh@thorin:/tmp/f$ git add .
hmh@thorin:/tmp/f$ git commit -m "initial commit"
Created initial commit 4e5f9c4: initial commit
 1 files changed, 1260 insertions(+), 0 deletions(-)
 create mode 100644 Xorg.0.log
hmh@thorin:/tmp/f$ git mv Xorg.0.log Xorg.1.log
hmh@thorin:/tmp/f$ git commit -m "move commit"
 Created commit ed5f8d0: move commit
 2 files changed, 1260 insertions(+), 1260 deletions(-)
 delete mode 100644 Xorg.0.log
 create mode 100644 Xorg.1.log
hmh@thorin:/tmp/f$ git diff HEAD^.. -M       
diff --git a/Xorg.0.log b/Xorg.1.log
similarity index 100%
rename from Xorg.0.log
rename to Xorg.1.log

The key is that -M (or -C for that matter).  To be even more clear:
hmh@thorin:/tmp/f$ git diff HEAD^.. | wc
   2532   20098  134766
hmh@thorin:/tmp/f$ git diff HEAD^.. -M | wc
   4      13     103

So I really should have mentioned -M when I talked about git diffs :-(

-- 
  "One disk to rule them all, One disk to find them. One disk to bring
  them all and in the darkness grind them. In the Land of Redmond
  where the shadows lie." -- The Silicon Valley Tarot
  Henrique Holschuh
-
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux