Re: Diff topic branch + working copy changes?
- From
Junio C Hamano <gitster@pobox.com>
- Date
- May 17, 2017, 02:47 UTC
- Message-ID
- <xmqq37c4yzb3.fsf@gitster.mtv.corp.google.com>
- In-Reply-To
- <CAHd499ADTbO09OJhH_wWBbAcXZeLRLFAqOw5eTe6=abN-JUrUA@mail.gmail.com>
Robert Dailey <rcdailey.lists@gmail.com> writes:
Show 18 quoted lines
> So for a topic branch based on master, I can diff ONLY my changes on > the topic branch by doing this simple command: > > $ git diff origin/master... > > However, this does not include uncommitted working copy changes. To > work around this, I can do this instead: > > $ git diff origin/master > > (No three-dot notation above) > > However this implies a ".." notation which will include changes on > master that have been made after I branched my topic (I use three-dot > to exclude those). > > Is there a way I can do the first diff but also include working copy > changes?
I've wished this a few times, but the answer is no. Not as a short-hand like "..." anyway.
You can still do
$ git diff $(git merge-base origin/master HEAD)
of course.