diff options
author | Jesse Luehrs <doy@tozt.net> | 2011-09-05 20:06:11 -0500 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2011-09-05 20:08:10 -0500 |
commit | b60ae4d5578eba82b7382dabaef88faa660a3f2b (patch) | |
tree | 81957a0512edec45bed0e8a9c9cc114499b15e7d | |
parent | 0a58dd8ca4d962998b077da24b3985988b3f3092 (diff) | |
download | conf-b60ae4d5578eba82b7382dabaef88faa660a3f2b.tar.gz conf-b60ae4d5578eba82b7382dabaef88faa660a3f2b.zip |
add command for getting pull requests from github
-rwxr-xr-x | bin/git/git-hub | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/bin/git/git-hub b/bin/git/git-hub index bf489be..953aa9c 100755 --- a/bin/git/git-hub +++ b/bin/git/git-hub @@ -199,6 +199,16 @@ sub run_command_add { git "fetch $remote"; } +sub run_command_pull { + my $self = shift; + die "usage: git hub pull <num>" + unless @_ == 1; + my ($num) = @_; + + my $remote = (any { /\bgithub\b/ } git "remote") ? 'github' : 'origin'; + git "fetch $remote refs/pull/$num/head:pull-$num"; +} + sub _github { my $self = shift; my %opts = @_; |