<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/git-rebase.sh, branch v2.3.4</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.3.4</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.3.4'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2014-07-16T20:07:40Z</updated>
<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'</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>
<entry>
<title>Merge branch 'ep/shell-command-substitution'</title>
<updated>2014-06-03T19:06:45Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2014-06-03T19:06:45Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=6753d8a85d543253d95184ec2faad6dc197f2486'/>
<id>urn:sha1:6753d8a85d543253d95184ec2faad6dc197f2486</id>
<content type='text'>
Adjust shell scripts to use $(cmd) instead of `cmd`.

* ep/shell-command-substitution: (41 commits)
  t5000-tar-tree.sh: use the $( ... ) construct for command substitution
  t4204-patch-id.sh: use the $( ... ) construct for command substitution
  t4119-apply-config.sh: use the $( ... ) construct for command substitution
  t4116-apply-reverse.sh: use the $( ... ) construct for command substitution
  t4057-diff-combined-paths.sh: use the $( ... ) construct for command substitution
  t4038-diff-combined.sh: use the $( ... ) construct for command substitution
  t4036-format-patch-signer-mime.sh: use the $( ... ) construct for command substitution
  t4014-format-patch.sh: use the $( ... ) construct for command substitution
  t4013-diff-various.sh: use the $( ... ) construct for command substitution
  t4012-diff-binary.sh: use the $( ... ) construct for command substitution
  t4010-diff-pathspec.sh: use the $( ... ) construct for command substitution
  t4006-diff-mode.sh: use the $( ... ) construct for command substitution
  t3910-mac-os-precompose.sh: use the $( ... ) construct for command substitution
  t3905-stash-include-untracked.sh: use the $( ... ) construct for command substitution
  t1050-large.sh: use the $( ... ) construct for command substitution
  t1020-subdirectory.sh: use the $( ... ) construct for command substitution
  t1004-read-tree-m-u-wf.sh: use the $( ... ) construct for command substitution
  t1003-read-tree-prefix.sh: use the $( ... ) construct for command substitution
  t1002-read-tree-m-u-2way.sh: use the $( ... ) construct for command substitution
  t1001-read-tree-m-2way.sh: use the $( ... ) construct for command substitution
  ...
</content>
</entry>
<entry>
<title>rebase -i: handle "Nothing to do" case with autostash</title>
<updated>2014-05-19T22:36:24Z</updated>
<author>
<name>Ramkumar Ramachandra</name>
<email>artagnon@gmail.com</email>
</author>
<published>2014-05-19T22:05:20Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=e4244eb3957d478ca05b42d8b56aadb9ab2bc7ae'/>
<id>urn:sha1:e4244eb3957d478ca05b42d8b56aadb9ab2bc7ae</id>
<content type='text'>
When a user invokes

  $ git rebase -i @~3

with dirty files and rebase.autostash turned on, and exits the $EDITOR
with an empty buffer, the autostash fails to apply. Although the primary
focus of rr/rebase-autostash was to get the git-rebase--backend.sh
scripts to return control to git-rebase.sh, it missed this case in
git-rebase--interactive.sh. Since this case is unlike the other cases
which return control for housekeeping, assign it a special return status
and handle that return value explicitly in git-rebase.sh.

Reported-by: Karen Etheridge &lt;ether@cpan.org&gt;
Signed-off-by: Ramkumar Ramachandra &lt;artagnon@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>git-rebase.sh: use the $( ... ) construct for command substitution</title>
<updated>2014-04-23T22:17:02Z</updated>
<author>
<name>Elia Pinto</name>
<email>gitter.spiros@gmail.com</email>
</author>
<published>2014-04-23T13:44:00Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=728fc79c0016fd7133c32f1d193d0a243e552257'/>
<id>urn:sha1:728fc79c0016fd7133c32f1d193d0a243e552257</id>
<content type='text'>
The Git CodingGuidelines prefer the $(...) construct for command
substitution instead of using the backquotes `...`.

The backquoted form is the traditional method for command
substitution, and is supported by POSIX.  However, all but the
simplest uses become complicated quickly.  In particular, embedded
command substitutions and/or the use of double quotes require
careful escaping with the backslash character.

The patch was generated by:

for _f in $(find . -name "*.sh")
do
   sed -i 's@`\(.*\)`@$(\1)@g' ${_f}
done

and then carefully proof-read.

Signed-off-by: Elia Pinto &lt;gitter.spiros@gmail.com&gt;
Reviewed-by: Matthieu Moy &lt;Matthieu.Moy@imag.fr&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'km/avoid-non-function-return-in-rebase'</title>
<updated>2014-04-21T17:42:46Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2014-04-21T17:42:45Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=0b17b4331087224883878e49342037bf69717b62'/>
<id>urn:sha1:0b17b4331087224883878e49342037bf69717b62</id>
<content type='text'>
Work around /bin/sh that does not like "return" at the top-level
of a file that is dot-sourced from inside a function definition.

* km/avoid-non-function-return-in-rebase:
  Revert "rebase: fix run_specific_rebase's use of "return" on FreeBSD"
  rebase: avoid non-function use of "return" on FreeBSD
</content>
</entry>
<entry>
<title>Revert "rebase: fix run_specific_rebase's use of "return" on FreeBSD"</title>
<updated>2014-04-17T17:15:27Z</updated>
<author>
<name>Kyle J. McKay</name>
<email>mackyle@gmail.com</email>
</author>
<published>2014-04-11T08:28:18Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=8cd65967fe0084574fcee278a5f9ff3d14047c4f'/>
<id>urn:sha1:8cd65967fe0084574fcee278a5f9ff3d14047c4f</id>
<content type='text'>
This reverts commit 99855ddf4bd319cd06a0524e755ab1c1b7d39f3b.

The workaround 99855ddf introduced to deal with problematic
"return" statements in scripts run by "dot" commands located
inside functions only handles one part of the problem.  The
issue has now been addressed by not using "return" statements
in this way in the git-rebase--*.sh scripts.

This workaround is therefore no longer necessary, so clean
up the code by reverting it.

Signed-off-by: Kyle J. McKay &lt;mackyle@gmail.com&gt;
Acked-by: Matthieu Moy &lt;Matthieu.Moy@imag.fr&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'bg/rebase-off-of-previous-branch'</title>
<updated>2014-03-28T20:51:20Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2014-03-28T20:51:20Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=97345145ff33286af6c14260432f5edfb56fdc82'/>
<id>urn:sha1:97345145ff33286af6c14260432f5edfb56fdc82</id>
<content type='text'>
* bg/rebase-off-of-previous-branch:
  rebase: allow "-" short-hand for the previous branch
</content>
</entry>
<entry>
<title>rebase: allow "-" short-hand for the previous branch</title>
<updated>2014-03-19T17:52:51Z</updated>
<author>
<name>Brian Gesiak</name>
<email>modocache@gmail.com</email>
</author>
<published>2014-03-19T11:02:15Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=4f4074077fb0c3a2facc61b333337d024aeeebbf'/>
<id>urn:sha1:4f4074077fb0c3a2facc61b333337d024aeeebbf</id>
<content type='text'>
Teach rebase the same shorthand as checkout and merge to name the
branch to rebase the current branch on; that is, that "-" means "the
branch we were previously on".

Requested-by: Tim Chase &lt;git@tim.thechases.com&gt;
Signed-off-by: Brian Gesiak &lt;modocache@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>rebase: add the --gpg-sign option</title>
<updated>2014-02-11T22:48:20Z</updated>
<author>
<name>Nicolas Vigier</name>
<email>boklm@mars-attacks.org</email>
</author>
<published>2014-02-10T01:03:37Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=3ee5e54038fd32ee60b24ebd385981aeb14b80a5'/>
<id>urn:sha1:3ee5e54038fd32ee60b24ebd385981aeb14b80a5</id>
<content type='text'>
Signed-off-by: Nicolas Vigier &lt;boklm@mars-attacks.org&gt;
Signed-off-by: brian m. carlson &lt;sandals@crustytoothpaste.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
</feed>
