Re: diff <commit> using 3-dot behavior

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

 



Robert Dailey <rcdailey.lists@xxxxxxxxx> writes:

> $ git diff master...topic

... which is defined roughly as

	git diff $(git merge-base master topic) topic

The merge-base is to compute the point you forked your topic from
the mainline.  So if you want to compare your current state in the
index with the fork point, you'd do

	git diff --cached $(git merge-base master topic)

and comparing your working tree state would be

	git diff --cached $(git merge-base master topic)

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]