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
path: root/npm.js
diff options
context:
space:
mode:
authorisaacs <i@izs.me>2010-01-12 14:25:14 +0300
committerisaacs <i@izs.me>2010-01-12 14:25:14 +0300
commit2c4c5c57181a358eade8462d193f8904610345a9 (patch)
tree19b9eb90916db311ff38c00a97d1ab4472a118df /npm.js
parent7921f1c65026cc9199d057b28bffefb94522d94f (diff)
It works. call npm.install(tarball, name) to install the package at "tarball" to "name" in your ~/.node_libraries/ folder, so that you can do require(name) to get the thing that the "lib" member points to.
Diffstat (limited to 'npm.js')
-rwxr-xr-xnpm.js10
1 files changed, 10 insertions, 0 deletions
diff --git a/npm.js b/npm.js
index 9f6877d2b..78c9a205a 100755
--- a/npm.js
+++ b/npm.js
@@ -1 +1,11 @@
+var utils = require("./lib/utils");
+
exports.install = require("./lib/install");
+
+var registry = {};
+
+exports.set = set;
+exports.get = get;
+
+function set (name, data) { return utils.set(registry, name, data) };
+function get (name) { return utils.get(registry, name) };