diff options
author | Sean Whitton <spwhitton@spwhitton.name> | 2019-11-09 09:29:35 -0700 |
---|---|---|
committer | Sean Whitton <spwhitton@spwhitton.name> | 2019-11-09 10:58:23 -0700 |
commit | aabb20fa10c487ba47177570dbaf7dcecb431226 (patch) | |
tree | bc0ff80f5db0fdf0d9fab89232cc256da4f1e5fb /bin/git-mr | |
parent | a28261e4fcab8cd1218f7ea516c7a440f77c3eaa (diff) | |
download | dotfiles-aabb20fa10c487ba47177570dbaf7dcecb431226.tar.gz |
git-mr with more helpful error msg when I don't supply all the args
Diffstat (limited to 'bin/git-mr')
-rwxr-xr-x | bin/git-mr | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/bin/git-mr b/bin/git-mr new file mode 100755 index 00000000..a71f50eb --- /dev/null +++ b/bin/git-mr @@ -0,0 +1,10 @@ +#!/usr/bin/perl + +use 5.028; +use strict; +use warnings; + +die "usage: git mr REMOTE_NAME MERGE_REQUEST_ID BRANCH_NAME\n" + unless @ARGV == 3; +system "git fetch $ARGV[0] merge-requests/$ARGV[1]/head"; +system "git checkout -b mr/$ARGV[2] FETCH_HEAD"; |