Last active
August 29, 2015 14:06
-
-
Save simshanith/58416a2db4e468328b41 to your computer and use it in GitHub Desktop.
mc-repo-updater
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
#!/usr/bin/env node | |
var path = require('path'); | |
var repos = [ | |
'MasterCard_MCCOM', | |
'MasterCard_MCCOMServices', | |
"MasterCard_WCM", | |
"MasterCard_WCMServices", | |
'aem', | |
'mc-enterprise-osgi-configs', | |
//'mc-locator-ws-mock', | |
'mc-locator-ws-model', | |
'mccom-osgi-configs' | |
]; | |
repos.forEach(function(repo) { | |
var spawn = require('child_process').spawn; | |
var update = spawn('svn', ['update'], { | |
cwd: path.join(__dirname, repo), | |
env: process.env | |
}); | |
update.stdout.on('data', function(data) { | |
console.log(repo); | |
console.log(data.toString()); | |
}); | |
update.stderr.on('data', function(data) { | |
console.error(repo); | |
console.error(data.toString()); | |
}); | |
update.on('close', function (code) { | |
console.log('%s update exited with code %s', repo, code); | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment