Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorisaacs <i@izs.me>2011-03-30 07:24:31 +0400
committerisaacs <i@izs.me>2011-03-30 09:05:00 +0400
commit6deac9755a169b077a5789839e26ed17b5da9241 (patch)
tree8b5222d711d7ea9ca820ea8da3cdbe2395bfac65
parent1bf96eef8dd405379a56fbcece48903022887e85 (diff)
Define config for bindist
-rw-r--r--doc/config.md17
-rw-r--r--lib/utils/config-defs.js3
-rw-r--r--man1/config.123
-rw-r--r--man1/get.123
-rw-r--r--man1/set.123
5 files changed, 88 insertions, 1 deletions
diff --git a/doc/config.md b/doc/config.md
index d6c0a02a3..8b0d43872 100644
--- a/doc/config.md
+++ b/doc/config.md
@@ -130,6 +130,23 @@ then the user could change the behavior by doing:
## Config Settings
+### bindist
+
+* Default: Unstable node versions, `null`, otherwise
+ `"<node version>-<platform>-<os release>"`
+* Type: String or `null`
+
+Experimental: on stable versions of node, binary distributions will be
+created with this tag. If a user then installs that package, and their
+`bindist` tag is found in the list of binary distributions, they will
+get that prebuilt version.
+
+Pre-build node packages have their preinstall, install, and postinstall
+scripts stripped (since they are run prior to publishing), and do not
+have their `build` directories automatically ignored.
+
+It's yet to be seen if this is a good idea.
+
### browser
* Default: OS X: `"open"`, others: `"google-chrome"`
diff --git a/lib/utils/config-defs.js b/lib/utils/config-defs.js
index e11f62ccb..2eaca4872 100644
--- a/lib/utils/config-defs.js
+++ b/lib/utils/config-defs.js
@@ -9,7 +9,7 @@ var path = require("path")
, stableFamily = semver.parse(process.version)
, os = require("os")
-if (stableFamily && (+stableFamily[2] % 2)) stableFamily = null
+if (!stableFamily || (+stableFamily[2] % 2)) stableFamily = null
else stableFamily = stableFamily[1] + "." + stableFamily[2]
exports.defaults =
@@ -69,6 +69,7 @@ exports.defaults =
exports.types =
{ argv : NaN
+ , bindist : [String, null]
, browser : String
, cache : path
, color : ["always", Boolean]
diff --git a/man1/config.1 b/man1/config.1
index ac266ca31..741c06971 100644
--- a/man1/config.1
+++ b/man1/config.1
@@ -235,6 +235,29 @@ npm config set foo:port 80
.
.SH "Config Settings"
.
+.SS "bindist"
+.
+.IP "\(bu" 4
+Default: Unstable node versions, \fBnull\fR, otherwise \fB"<node version>\-<platform>\-<os release>"\fR
+.
+.IP "\(bu" 4
+Type: String or \fBnull\fR
+.
+.IP "" 0
+.
+.P
+Experimental: on stable versions of node, binary distributions will be
+created with this tag\. If a user then installs that package, and their \fBbindist\fR tag is found in the list of binary distributions, they will
+get that prebuilt version\.
+.
+.P
+Pre\-build node packages have their preinstall, install, and postinstall
+scripts stripped (since they are run prior to publishing), and do not
+have their \fBbuild\fR directories automatically ignored\.
+.
+.P
+It\'s yet to be seen if this is a good idea\.
+.
.SS "browser"
.
.IP "\(bu" 4
diff --git a/man1/get.1 b/man1/get.1
index ac266ca31..741c06971 100644
--- a/man1/get.1
+++ b/man1/get.1
@@ -235,6 +235,29 @@ npm config set foo:port 80
.
.SH "Config Settings"
.
+.SS "bindist"
+.
+.IP "\(bu" 4
+Default: Unstable node versions, \fBnull\fR, otherwise \fB"<node version>\-<platform>\-<os release>"\fR
+.
+.IP "\(bu" 4
+Type: String or \fBnull\fR
+.
+.IP "" 0
+.
+.P
+Experimental: on stable versions of node, binary distributions will be
+created with this tag\. If a user then installs that package, and their \fBbindist\fR tag is found in the list of binary distributions, they will
+get that prebuilt version\.
+.
+.P
+Pre\-build node packages have their preinstall, install, and postinstall
+scripts stripped (since they are run prior to publishing), and do not
+have their \fBbuild\fR directories automatically ignored\.
+.
+.P
+It\'s yet to be seen if this is a good idea\.
+.
.SS "browser"
.
.IP "\(bu" 4
diff --git a/man1/set.1 b/man1/set.1
index ac266ca31..741c06971 100644
--- a/man1/set.1
+++ b/man1/set.1
@@ -235,6 +235,29 @@ npm config set foo:port 80
.
.SH "Config Settings"
.
+.SS "bindist"
+.
+.IP "\(bu" 4
+Default: Unstable node versions, \fBnull\fR, otherwise \fB"<node version>\-<platform>\-<os release>"\fR
+.
+.IP "\(bu" 4
+Type: String or \fBnull\fR
+.
+.IP "" 0
+.
+.P
+Experimental: on stable versions of node, binary distributions will be
+created with this tag\. If a user then installs that package, and their \fBbindist\fR tag is found in the list of binary distributions, they will
+get that prebuilt version\.
+.
+.P
+Pre\-build node packages have their preinstall, install, and postinstall
+scripts stripped (since they are run prior to publishing), and do not
+have their \fBbuild\fR directories automatically ignored\.
+.
+.P
+It\'s yet to be seen if this is a good idea\.
+.
.SS "browser"
.
.IP "\(bu" 4