|
@@ -57756,6 +57756,27 @@ referencedClasses: []
|
|
|
}),
|
|
|
globals.Initer);
|
|
|
|
|
|
+smalltalk.addMethod(
|
|
|
+smalltalk.method({
|
|
|
+selector: "gruntThenDo:",
|
|
|
+protocol: 'action',
|
|
|
+fn: function (aBlock){
|
|
|
+var self=this;
|
|
|
+var child;
|
|
|
+return smalltalk.withContext(function($ctx1) {
|
|
|
+var $1;
|
|
|
+child=_st(self["@childProcess"])._exec_thenDo_(_st(self["@path"])._join_with_with_(self["@nmPath"],".bin","grunt"),aBlock);
|
|
|
+$1=_st(child)._stdout();
|
|
|
+$ctx1.sendIdx["stdout"]=1;
|
|
|
+_st($1)._pipe_options_(_st(process)._stdout(),globals.HashedCollection._newFromPairs_(["end",false]));
|
|
|
+return self}, function($ctx1) {$ctx1.fill(self,"gruntThenDo:",{aBlock:aBlock,child:child},globals.Initer)})},
|
|
|
+args: ["aBlock"],
|
|
|
+source: "gruntThenDo: aBlock\x0a\x09| child |\x0a\x09child := childProcess\x0a\x09\x09exec: (path join: nmPath with: '.bin' with: 'grunt')\x0a\x09\x09thenDo: aBlock.\x0a\x09child stdout pipe: process stdout options: #{ 'end' -> false }",
|
|
|
+messageSends: ["exec:thenDo:", "join:with:with:", "pipe:options:", "stdout"],
|
|
|
+referencedClasses: []
|
|
|
+}),
|
|
|
+globals.Initer);
|
|
|
+
|
|
|
smalltalk.addMethod(
|
|
|
smalltalk.method({
|
|
|
selector: "initialize",
|
|
@@ -57823,7 +57844,7 @@ protocol: 'action',
|
|
|
fn: function (){
|
|
|
var self=this;
|
|
|
return smalltalk.withContext(function($ctx1) {
|
|
|
-var $1,$2,$3,$4,$5,$6,$receiver;
|
|
|
+var $1,$2,$3,$4,$5,$6,$7,$8,$receiver;
|
|
|
self._gruntInitThenDo_((function(error){
|
|
|
return smalltalk.withContext(function($ctx2) {
|
|
|
if(($receiver = error) == null || $receiver.isNil){
|
|
@@ -57833,12 +57854,26 @@ if(($receiver = error2) == null || $receiver.isNil){
|
|
|
return self._npmInstallThenDo_((function(error3){
|
|
|
return smalltalk.withContext(function($ctx4) {
|
|
|
if(($receiver = error3) == null || $receiver.isNil){
|
|
|
+return self._gruntThenDo_((function(error4){
|
|
|
+return smalltalk.withContext(function($ctx5) {
|
|
|
+if(($receiver = error4) == null || $receiver.isNil){
|
|
|
return _st(process)._exit();
|
|
|
} else {
|
|
|
+$7=console;
|
|
|
+_st($7)._log_("grunt exec error:");
|
|
|
+$ctx5.sendIdx["log:"]=7;
|
|
|
+$8=_st($7)._log_(error4);
|
|
|
+$8;
|
|
|
+return _st(process)._exit();
|
|
|
+$ctx5.sendIdx["exit"]=4;
|
|
|
+};
|
|
|
+}, function($ctx5) {$ctx5.fillBlock({error4:error4},$ctx4,10)})}));
|
|
|
+} else {
|
|
|
$5=console;
|
|
|
_st($5)._log_("npm install exec error:");
|
|
|
$ctx4.sendIdx["log:"]=5;
|
|
|
$6=_st($5)._log_(error3);
|
|
|
+$ctx4.sendIdx["log:"]=6;
|
|
|
$6;
|
|
|
return _st(process)._exit();
|
|
|
$ctx4.sendIdx["exit"]=3;
|
|
@@ -57868,8 +57903,8 @@ $ctx2.sendIdx["exit"]=1;
|
|
|
}, function($ctx2) {$ctx2.fillBlock({error:error},$ctx1,1)})}));
|
|
|
return self}, function($ctx1) {$ctx1.fill(self,"start",{},globals.Initer)})},
|
|
|
args: [],
|
|
|
-source: "start\x0a\x09self gruntInitThenDo: [ :error | error\x0a\x09ifNotNil: [\x0a\x09\x09console log: 'grunt-init exec error:'; log: error.\x0a\x09\x09process exit ]\x0a\x09ifNil: [\x0a\x0a\x09self bowerInstallThenDo: [ :error2 | error2\x0a\x09ifNotNil: [\x0a\x09\x09console log: 'bower install exec error:'; log: error2.\x0a\x09\x09process exit ]\x0a\x09ifNil: [\x0a\x0a\x09self npmInstallThenDo: [ :error3 | error3\x0a\x09ifNotNil: [\x0a\x09\x09console log: 'npm install exec error:'; log: error3.\x0a\x09\x09process exit ]\x0a\x09ifNil: [\x0a\x0a\x09process exit ]]]]]]",
|
|
|
-messageSends: ["gruntInitThenDo:", "ifNotNil:ifNil:", "log:", "exit", "bowerInstallThenDo:", "npmInstallThenDo:"],
|
|
|
+source: "start\x0a\x09self gruntInitThenDo: [ :error | error\x0a\x09ifNotNil: [\x0a\x09\x09console log: 'grunt-init exec error:'; log: error.\x0a\x09\x09process exit ]\x0a\x09ifNil: [\x0a\x0a\x09self bowerInstallThenDo: [ :error2 | error2\x0a\x09ifNotNil: [\x0a\x09\x09console log: 'bower install exec error:'; log: error2.\x0a\x09\x09process exit ]\x0a\x09ifNil: [\x0a\x0a\x09self npmInstallThenDo: [ :error3 | error3\x0a\x09ifNotNil: [\x0a\x09\x09console log: 'npm install exec error:'; log: error3.\x0a\x09\x09process exit ]\x0a\x09ifNil: [\x0a\x0a\x09self gruntThenDo: [ :error4 | error4\x0a\x09ifNotNil: [\x0a\x09\x09console log: 'grunt exec error:'; log: error4.\x0a\x09\x09process exit ]\x0a\x09ifNil: [\x0a\x0a\x09process exit ]]]]]]]]",
|
|
|
+messageSends: ["gruntInitThenDo:", "ifNotNil:ifNil:", "log:", "exit", "bowerInstallThenDo:", "npmInstallThenDo:", "gruntThenDo:"],
|
|
|
referencedClasses: []
|
|
|
}),
|
|
|
globals.Initer);
|