From 607519b48a8f2a967706d5e87d87ac9e7b8082aa Mon Sep 17 00:00:00 2001 From: Vladimir Polyakov Date: Wed, 2 Mar 2016 15:03:23 +0300 Subject: [PATCH] update submodule after git checkout --- lib/scm/git.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/lib/scm/git.js b/lib/scm/git.js index 8de94ad..f9fcf62 100644 --- a/lib/scm/git.js +++ b/lib/scm/git.js @@ -172,5 +172,14 @@ Scm.prototype.getChanges = function(rev1, rev2, callback) { }; Scm.prototype.update = function(rev, callback) { - this.run({cmd: 'git', args: ['checkout', '-f', rev]}, callback); + var self = this; + Steppy( + function() { + self.run({cmd: 'git', args: ['checkout', '-f', rev]}, this.slot()); + }, + function() { + self.run({cmd: 'git', args: ['submodule', 'update']}, this.slot()); + }, + callback + ); };