diff --git a/Commands.md b/Commands.md index 252f9ba..cb41a00 100644 --- a/Commands.md +++ b/Commands.md @@ -42,6 +42,7 @@ - [`git root`](#git-root) - [`git delta`](#git-delta) - [`git merge-repo`](#git-merge-repo) + - [`git psykorebase`](#git-psykorebase) ## git extras @@ -853,3 +854,26 @@ $ git merge-repo git@github.com:tj/git-extras.git master . ``` The above merges a remote repo's `master` branch into the current repository's directory, not preserving history. + + +## git psykorebase + +Rebase a branch on top of another using a merge commit and only one conflict handling. + +```bash +$ git psykorebase master +``` + +The above rebase the current branch on top of `master` branch . + +```bash +$ git psykorebase --continue +``` + +The above continue the rebase after conflicts have been handled. + +```bash +$ git psykorebase master feature +``` + +The above rebase `feature` branch on top of `master` branch diff --git a/bin/git-psykorebase b/bin/git-psykorebase index 8059082..7351015 100755 --- a/bin/git-psykorebase +++ b/bin/git-psykorebase @@ -11,7 +11,7 @@ function current_branch() { function usage() { - echo "USAGE: ${PROGRAM} PRIMARY_BRANCH [SECONDARY_BRANCH]" + echo "USAGE: ${PROGRAM} PRIMARY_BRANCH [SECONDARY_BRANCH] [--no-ff]" echo "USAGE: ${PROGRAM} --continue" echo "" echo "OPTIONS:" diff --git a/man/git-psykorebase.1 b/man/git-psykorebase.1 new file mode 100644 index 0000000..bc65dc2 --- /dev/null +++ b/man/git-psykorebase.1 @@ -0,0 +1,67 @@ +.\" generated with Ronn/v0.7.3 +.\" http://github.com/rtomayko/ronn/tree/0.7.3 +. +.TH "GIT\-PSYKOREBASE" "1" "August 2015" "" "" +. +.SH "NAME" +\fBgit\-psykorebase\fR \- Rebase a branch with a merge commit +. +.SH "SYNOPSIS" +\fBgit\-psykorebase\fR [] [\-\-no\-ff] \fBgit\-psykorebase\fR \-\-continue +. +.SH "DESCRIPTION" +Rebase the \fBfeature_branch\fR on top of the \fBtarget_branch\fR, the \fBfeature_branch\fR defaults to the current one\. +. +.SH "OPTIONS" +\fB\-\-no\-ff\fR Force a commit message even if there are no conflicts\. \fB\-\-continue\fR Continue the rebase after conflicts have been resolved\. +. +.SH "EXAMPLES" +Rebase current branch on top of master: +. +.IP "" 4 +. +.nf + +$ git psykorebase master \-\-no\-ff +. +.fi +. +.IP "" 0 +. +.P +Handle conflicts: +. +.IP "" 4 +. +.nf + +$ git add README\.md +. +.fi +. +.IP "" 0 +. +.P +Continue rebase: +. +.IP "" 4 +. +.nf + +$ git psykorebase \-\-continue +. +.fi +. +.IP "" 0 +. +.SH "AUTHOR" +Written by Rémy Hubscher <\fIrhubscher@mozilla\.com\fR> +. +.P +Based on Benoît Bryon <\fIbenoit@marmelune\.net\fR> implementation in Python\. +. +.SH "REPORTING BUGS" +<\fIhttps://github\.com/tj/git\-extras/issues\fR> +. +.SH "SEE ALSO" +<\fIhttps://github\.com/tj/git\-extras\fR> <\fIhttps://github\.com/benoitbryon/psykorebase\fR> diff --git a/man/git-psykorebase.html b/man/git-psykorebase.html new file mode 100644 index 0000000..454fb4b --- /dev/null +++ b/man/git-psykorebase.html @@ -0,0 +1,134 @@ + + + + + + git-psykorebase(1) - Rebase a branch with a merge commit + + + + +
+ + + +
    +
  1. git-psykorebase(1)
  2. +
  3. +
  4. git-psykorebase(1)
  5. +
+ +

NAME

+

+ git-psykorebase - Rebase a branch with a merge commit +

+ +

SYNOPSIS

+ +

git-psykorebase <target_branch> [<feature_branch>] [--no-ff] +git-psykorebase --continue

+ +

DESCRIPTION

+ +

Rebase the feature_branch on top of the target_branch, the +feature_branch defaults to the current one.

+ +

OPTIONS

+ +

--no-ff Force a commit message even if there are no conflicts. + --continue Continue the rebase after conflicts have been resolved.

+ +

EXAMPLES

+ +

Rebase current branch on top of master:

+ +
$ git psykorebase master --no-ff
+
+ +

Handle conflicts:

+ +
$ git add README.md
+
+ +

Continue rebase:

+ +
$ git psykorebase --continue
+
+ +

AUTHOR

+ +

Written by Rémy Hubscher <rhubscher@mozilla.com>

+ +

Based on Benoît Bryon <benoit@marmelune.net> implementation in +Python.

+ +

REPORTING BUGS

+ +

<https://github.com/tj/git-extras/issues>

+ +

SEE ALSO

+ +

<https://github.com/tj/git-extras> +<https://github.com/benoitbryon/psykorebase>

+ + +
    +
  1. +
  2. August 2015
  3. +
  4. git-psykorebase(1)
  5. +
+ +
+ + diff --git a/man/git-psykorebase.md b/man/git-psykorebase.md new file mode 100644 index 0000000..7d02807 --- /dev/null +++ b/man/git-psykorebase.md @@ -0,0 +1,47 @@ +git-psykorebase(1) -- Rebase a branch with a merge commit +========================================================= + +## SYNOPSIS + +`git-psykorebase` <target_branch> [<feature_branch>] [--no-ff] +`git-psykorebase` --continue + +## DESCRIPTION + +Rebase the `feature_branch` on top of the `target_branch`, the +`feature_branch` defaults to the current one. + +## OPTIONS + + `--no-ff` Force a commit message even if there are no conflicts. + `--continue` Continue the rebase after conflicts have been resolved. + +## EXAMPLES + + Rebase current branch on top of master: + + $ git psykorebase master --no-ff + + Handle conflicts: + + $ git add README.md + + Continue rebase: + + $ git psykorebase --continue + +## AUTHOR + +Written by Rémy Hubscher <> + +Based on Benoît Bryon <> implementation in +Python. + +## REPORTING BUGS + +<> + +## SEE ALSO + +<> +<>