From abc5b4f2c7811eb401c96c4d8e6dd567eca15e88 Mon Sep 17 00:00:00 2001 From: coderaiser Date: Fri, 30 Jan 2015 09:36:38 -0500 Subject: [PATCH] feature(publish) if publish failed, do it again --- lib/publish.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/publish.js b/lib/publish.js index e45a9ce..f75b899 100644 --- a/lib/publish.js +++ b/lib/publish.js @@ -78,7 +78,7 @@ execute(cmd, emitter, callback); }, - function (callback) { + function publish(callback) { var v = 'v' + version, repo = getRepoName(info), owner = getOwner(info), @@ -93,6 +93,10 @@ grizzly(null, data, function(error) { if (!error) emitter.emit('data', 'release: ok'); + else { + console.log('Error releasing on github. Trying again.'); + publish(callback); + } callback(error); });