Skip to content

Commit 60dbf64

Browse files
committed
Move some stuff around.
1 parent 59bbe46 commit 60dbf64

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

lifecycleScripts/install.js

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,6 @@ return whichNativeNodish("..")
2323
console.info("[nodegit] Must build for node-webkit/nw.js");
2424
return prepareAndBuild();
2525
}
26-
var args = []
27-
if (asVersion) {
28-
args.push("--runtime=electron")
29-
args.push("--target=" + asVersion)
3026
}
3127
// if (fs.existsSync(local("../.didntcomefromthenpmregistry"))) {
3228
// return prepareAndBuild();
@@ -39,12 +35,17 @@ return whichNativeNodish("..")
3935
console.info("[nodegit] BUILD_ONLY is set to true, no fetching allowed.");
4036
return prepareAndBuild();
4137
}
42-
return installWithPreGyp(args)
38+
var args = [];
39+
if (asVersion) {
40+
args.push("--runtime=electron");
41+
args.push("--target=" + asVersion);
42+
}
43+
return installPrebuilt(args)
4344
});
4445

45-
function installWithPreGyp(args) {
46+
function installPrebuilt(args) {
4647
console.info("[nodegit] Fetching binary from S3.");
47-
var arguments = args.join(' ')
48+
var arguments = args.join(' ');
4849
return exec("node-pre-gyp install " + arguments)
4950
.then(
5051
function() {

0 commit comments

Comments
 (0)