forked from jlord/git-it
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
jlord
committed
Jan 17, 2014
1 parent
25f0827
commit c04fb70
Showing
3 changed files
with
22 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
module.exports = function () { | ||
return { args: [], stdin: null } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
console.log(true) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#!/usr/bin/env node | ||
|
||
var spawn = require('child_process').spawn | ||
var concat = require('concat-stream') | ||
|
||
var remote = spawn('git', ['remote', '-v']) | ||
|
||
remote.stdout.pipe(concat(onRemote)) | ||
|
||
// check that there is no longer a feature branch | ||
// here is what i added to test branch | ||
|
||
function onRemote(output) { | ||
var show = output.toString().trim() | ||
if (show.match("upstream") && show.match("github.com/jlord/")) | ||
console.log(true) | ||
else return console.log("no upstream remote") | ||
} |