From 2ff5309d542763aa9183ab87b27d32dda360265e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Eric=20Engestr=C3=B6m?= Date: Wed, 7 May 2014 00:00:44 +0200 Subject: [PATCH 1/3] Allow newer version of `nodejs` --- script/bootstrap | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/script/bootstrap b/script/bootstrap index a7fcc4826..2eb6c4a80 100755 --- a/script/bootstrap +++ b/script/bootstrap @@ -1,8 +1,8 @@ #!/usr/bin/env node var nodeMinorVersion = process.versions.node.split('.')[1] -if (nodeMinorVersion !== '10') { - console.warn("You must run script/bootstrap and script/build with node v0.10.x"); +if (nodeMinorVersion < '10') { + console.warn("You must run script/bootstrap and script/build with node v0.10.x or above"); process.exit(1); } From ed90a78ea5ec84255c8aa1f2935cd00cad27ea3a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Eric=20Engestr=C3=B6m?= Date: Fri, 9 May 2014 00:41:08 +0200 Subject: [PATCH 2/3] Replacing string comparison with actual int comparison --- script/bootstrap | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/script/bootstrap b/script/bootstrap index 2eb6c4a80..9519da27f 100755 --- a/script/bootstrap +++ b/script/bootstrap @@ -1,8 +1,11 @@ #!/usr/bin/env node -var nodeMinorVersion = process.versions.node.split('.')[1] -if (nodeMinorVersion < '10') { - console.warn("You must run script/bootstrap and script/build with node v0.10.x or above"); +var nodeVersion = process.versions.node.split('.') +var nodeMajorVersion = +nodeVersion[0] +var nodeMinorVersion = +nodeVersion[1] +// TODO: replace that when node 1.0 come around +if (nodeMajorVersion !== 0 || nodeMinorVersion < 10) { + console.warn("You must run script/bootstrap and script/build with node v0.10 or above"); process.exit(1); } From 9302242299ed0e891b1030e91286b380b5508f07 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Eric=20Engestr=C3=B6m?= Date: Fri, 9 May 2014 00:45:13 +0200 Subject: [PATCH 3/3] Allowing node > 1.0 (no reason not to already do that, I guess) --- script/bootstrap | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/script/bootstrap b/script/bootstrap index 9519da27f..872173f2b 100755 --- a/script/bootstrap +++ b/script/bootstrap @@ -3,8 +3,7 @@ var nodeVersion = process.versions.node.split('.') var nodeMajorVersion = +nodeVersion[0] var nodeMinorVersion = +nodeVersion[1] -// TODO: replace that when node 1.0 come around -if (nodeMajorVersion !== 0 || nodeMinorVersion < 10) { +if (nodeMajorVersion === 0 && nodeMinorVersion < 10) { console.warn("You must run script/bootstrap and script/build with node v0.10 or above"); process.exit(1); }