1 #!/bin/sh |
|
2 set -eu |
|
3 |
|
4 case ${1:-} in *help|-h) |
|
5 exec perldoc -T $0;; |
|
6 esac |
|
7 |
|
8 BRANCH="$(git symbolic-ref --short -q HEAD)" |
|
9 BASE=$(git merge-base "@{u}" "$BRANCH") |
|
10 |
|
11 exec git rebase --interactive --autosquash "$@" "$BASE" "$BRANCH" |
|
12 |
|
13 :<<=cut |
|
14 =head1 NAME |
|
15 |
|
16 git histedit |
|
17 |
|
18 =head1 SYNOPSIS |
|
19 |
|
20 $ git histedit |
|
21 |
|
22 =head1 DESCRIPTION |
|
23 |
|
24 C<histedit> lets you edit the current branch using interactive rebase, but |
|
25 without actually I<moving> the fork point of your branch, avoiding the |
|
26 complications of fixing up your history and dealing with merge conflicts at the |
|
27 same time. |
|
28 |
|
29 See also: C<hg histedit> |
|
30 |
|
31 =cut |
|