Permalink
Browse files

Allow fail-fast after curl

  • Loading branch information...
1 parent 9e57046 commit 609290094c0c08fe9256558b5fbfde8bdfa26008 @lennartcl committed Sep 13, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 git-list-pull-requests
View
4 git-list-pull-requests
@@ -6,9 +6,9 @@
# Copyright (c) 2012 Lennart C. L. Kats
function getPulls() {
- curl --compressed -s https://api.github.com/repos/$1/pulls?access_token=$GITHUB_TOKEN |
+ curl --compressed -s https://api.github.com/repos/$1/pulls?access_token=$GITHUB_TOKEN > /tmp/.git-list-i-$2
node -e '
- var pulls = JSON.parse(require("fs").readFileSync("/dev/stdin", "UTF-8"));
+ var pulls = JSON.parse(require("fs").readFileSync("'/tmp/.git-list-i-$2'", "UTF-8"));
pulls.map(function(p) {
if ("'$ALL'" === "-a" || p.user.login === "'$GITHUB_USER'")
console.log(p.head.ref);

0 comments on commit 6092900

Please sign in to comment.