<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/git-rebase.sh, branch v2.7.3</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.7.3</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.7.3'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2016-02-05T22:54:13Z</updated>
<entry>
<title>Merge branch 'jk/ok-to-fail-gc-auto-in-rebase' into maint</title>
<updated>2016-02-05T22:54:13Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2016-02-05T22:54:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=b11a3badf2353d69a244348991ff35f823f6b967'/>
<id>urn:sha1:b11a3badf2353d69a244348991ff35f823f6b967</id>
<content type='text'>
"git rebase", unlike all other callers of "gc --auto", did not
ignore the exit code from "gc --auto".

* jk/ok-to-fail-gc-auto-in-rebase:
  rebase: ignore failures from "gc --auto"
</content>
</entry>
<entry>
<title>rebase: ignore failures from "gc --auto"</title>
<updated>2016-01-13T20:04:53Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2016-01-13T18:47:18Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=8c24f5b022095f4735fcb73364ccae7d97576636'/>
<id>urn:sha1:8c24f5b022095f4735fcb73364ccae7d97576636</id>
<content type='text'>
After rebasing, we call "gc --auto" to clean up if we
created a lot of loose objects. However, we do so inside an
&amp;&amp;-chain. If "gc --auto" fails (e.g., because a previous
background gc blocked us by leaving "gc.log" in place),
then:

  1. We will fail to clean up the state directory, leaving
     the user stuck in the rebase forever (even "git am
     --abort" doesn't work, because it calls "gc --auto"!).

  2. In some cases, we may return a bogus exit code from
     rebase, indicating failure when everything except the
     auto-gc succeeded.

We can fix this by ignoring the exit code of "gc --auto".

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jk/rebase-no-autostash'</title>
<updated>2015-10-05T19:30:22Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-10-05T19:30:21Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=6560584494a8053431d0c8e90b78d50f71c8055b'/>
<id>urn:sha1:6560584494a8053431d0c8e90b78d50f71c8055b</id>
<content type='text'>
There was no way to defeat a configured rebase.autostash variable
from the command line, as "git rebase --no-autostash" was missing.

* jk/rebase-no-autostash:
  Documentation/git-rebase: fix --no-autostash formatting
  rebase: support --no-autostash
</content>
</entry>
<entry>
<title>rebase: support --no-autostash</title>
<updated>2015-09-11T00:42:01Z</updated>
<author>
<name>John Keeping</name>
<email>john@keeping.me.uk</email>
</author>
<published>2015-09-10T22:30:51Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=619e3604288ab54c3694e99746661caf0f2df961'/>
<id>urn:sha1:619e3604288ab54c3694e99746661caf0f2df961</id>
<content type='text'>
This is documented as an option but we don't actually accept it.
Support it so that it is possible to override the "rebase.autostash"
config variable.

Reported-by: Daniel Hahler &lt;genml+git-2014@thequod.de&gt;
Signed-off-by: John Keeping &lt;john@keeping.me.uk&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jk/rebase-quiet-noop'</title>
<updated>2015-05-11T21:23:49Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2015-05-11T21:23:49Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=352618287e469889c85da4f2fd32c03d5ac2f3dc'/>
<id>urn:sha1:352618287e469889c85da4f2fd32c03d5ac2f3dc</id>
<content type='text'>
"git rebase --quiet" was not quite quiet when there is nothing to
do.

* jk/rebase-quiet-noop:
  rebase: silence "git checkout" for noop rebase
</content>
</entry>
<entry>
<title>rebase: silence "git checkout" for noop rebase</title>
<updated>2015-04-28T18:38:40Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2015-04-28T05:17:37Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=22946a942627d67b09a9630a036e48ce2823cd0c'/>
<id>urn:sha1:22946a942627d67b09a9630a036e48ce2823cd0c</id>
<content type='text'>
When the branch to be rebased is already up to date, we
"git checkout" the branch, print an "up to date" message,
and end the rebase early. However, our checkout may print
"Switched to branch 'foo'" or "Already on 'foo'", even if
the user has asked for "--quiet".

We should avoid printing these messages at all, "--quiet" or
no. Since the rebase is a noop, this checkout can be seen as
optimizing out these other two checkout operations (that
happen in a real rebase):

  1. Moving to the detached HEAD to start the rebase; we
     always feed "-q" to checkout there, and instead rely on
     our own custom message (which respects --quiet).

  2. Finishing a rebase, where we move to the final branch.
     Here we actually use update-ref rather than
     git-checkout, and produce no messages.

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>*.sh: avoid hardcoding $GIT_DIR/hooks/...</title>
<updated>2014-12-01T19:00:13Z</updated>
<author>
<name>Nguyễn Thái Ngọc Duy</name>
<email>pclouds@gmail.com</email>
</author>
<published>2014-11-30T08:24:38Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=b849b954d22ee069b0edec1a12c78782ae1e629d'/>
<id>urn:sha1:b849b954d22ee069b0edec1a12c78782ae1e629d</id>
<content type='text'>
If $GIT_COMMON_DIR is set, it should be $GIT_COMMON_DIR/hooks/, not
$GIT_DIR/hooks/. Just let rev-parse --git-path handle it.

Signed-off-by: Nguyễn Thái Ngọc Duy &lt;pclouds@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>rebase: omit patch-identical commits with --fork-point</title>
<updated>2014-07-16T20:07:40Z</updated>
<author>
<name>John Keeping</name>
<email>john@keeping.me.uk</email>
</author>
<published>2014-07-16T19:23:49Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=1e0dacdbdb751caa5936b6d1510f5e8db4d1ed5f'/>
<id>urn:sha1:1e0dacdbdb751caa5936b6d1510f5e8db4d1ed5f</id>
<content type='text'>
When the `--fork-point` argument was added to `git rebase`, we changed
the value of $upstream to be the fork point instead of the point from
which we want to rebase.  When $orig_head..$upstream is empty this does
not change the behaviour, but when there are new changes in the upstream
we are no longer checking if any of them are patch-identical with
changes in $upstream..$orig_head.

Fix this by introducing a new variable to hold the fork point and using
this to restrict the range as an extra (negative) revision argument so
that the set of desired revisions becomes (in fork-point mode):

	git rev-list --cherry-pick --right-only \
		$upstream...$orig_head ^$fork_point

This allows us to correctly handle the scenario where we have the
following topology:

	    C --- D --- E  &lt;- dev
	   /
	  B  &lt;- master@{1}
	 /
	o --- B' --- C* --- D*  &lt;- master

where:
- B' is a fixed-up version of B that is not patch-identical with B;
- C* and D* are patch-identical to C and D respectively and conflict
  textually if applied in the wrong order;
- E depends textually on D.

The correct result of `git rebase master dev` is that B is identified as
the fork-point of dev and master, so that C, D, E are the commits that
need to be replayed onto master; but C and D are patch-identical with C*
and D* and so can be dropped, so that the end result is:

	o --- B' --- C* --- D* --- E  &lt;- dev

If the fork-point is not identified, then picking B onto a branch
containing B' results in a conflict and if the patch-identical commits
are not correctly identified then picking C onto a branch containing D
(or equivalently D*) results in a conflict.

This change allows us to handle both of these cases, where previously we
either identified the fork-point (with `--fork-point`) but not the
patch-identical commits *or* (with `--no-fork-point`) identified the
patch-identical commits but not the fact that master had been rewritten.

Reported-by: Ted Felix &lt;ted@tedfelix.com&gt;
Signed-off-by: John Keeping &lt;john@keeping.me.uk&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'rr/rebase-autostash-fix' into maint</title>
<updated>2014-06-25T18:49:31Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2014-06-25T18:49:31Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=d9036cd28c9b115fe38e2f629292f2ddf60fb805'/>
<id>urn:sha1:d9036cd28c9b115fe38e2f629292f2ddf60fb805</id>
<content type='text'>
The autostash mode of "git rebase -i" did not restore the dirty
working tree state if the user aborted the interactive rebase by
emptying the insn sheet.

* rr/rebase-autostash-fix:
  rebase -i: test "Nothing to do" case with autostash
  rebase -i: handle "Nothing to do" case with autostash
</content>
</entry>
<entry>
<title>Merge branch 'rr/rebase-autostash-fix'</title>
<updated>2014-06-16T17:06:57Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2014-06-16T17:06:57Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=4a43d4f98a1a6a472ce1e87c64cb6df0d1653d02'/>
<id>urn:sha1:4a43d4f98a1a6a472ce1e87c64cb6df0d1653d02</id>
<content type='text'>
* rr/rebase-autostash-fix:
  rebase -i: test "Nothing to do" case with autostash
  rebase -i: handle "Nothing to do" case with autostash
</content>
</entry>
</feed>
