diff --git a/Readme.md b/Readme.md index ed277b2..5e1802f 100644 --- a/Readme.md +++ b/Readme.md @@ -26,6 +26,7 @@ Brew (buggy): - git pull-request - git count - git create-branch + - git apply-branch - git delete-branch - git delete-submodule - git delete-tag @@ -125,6 +126,16 @@ of commits included in the commitish: $ git summary v42.. +## git-apply-branch <name> + + Applies the diff of the given branch `name`: + + $ git apply-branch mybranch + + Effectively a shortcut for: + + $ git diff ..mybranch | git apply + ## git-repl GIT read-eval-print-loop: diff --git a/bin/git-apply-branch b/bin/git-apply-branch new file mode 100755 index 0000000..8b43b19 --- /dev/null +++ b/bin/git-apply-branch @@ -0,0 +1,3 @@ +#!/bin/sh + +git diff ..$1 | git apply \ No newline at end of file