0.4.4 • Published 5 years ago
spm-client v0.4.4
spm-client
spm client api
Install
$ npm install spm-client -g
Usage
var client = require('spm-client');
// global configuration
client.config({
registry: 'http://registry.spmjs.io',
auth: '12345'
})
// install seajs
client.install({name: 'seajs'}, function(err) {
console.log(err);
});
// overwrite global config
client.install({name: 'seajs'}, {registry: 'http://your-registry'}, function(err) {
console.log(err);
});
API
config
Global configuration
- registry: registry url of yuan server
- global_registry: global registry, others are private
- proxy: an HTTP proxy, pass to request
- auth: the authKey that copied from spmjs accout page
- temp: the temp directory
login
Login spmjs.io, arguments below
- username: the username of registry
- authkey: the authKey that copied from spmjs accout page
install
Install a package, arguments below
- name: the package name, can also be name@version
- cwd: the dependencies of the package in the cwd will be installed, use it when name isn't specified
- destination: the directory that install to
- force: force download packages from registry, no cache
- save: save name to package.dependencies
- saveDev: save name to package.devDependencies
search
Search a package, arguments below
- name: search packages with your query name
info
Get package info, arguments below
- name: the package name
- version: the package version
publish
Publish a package, arguments below
- cwd: where is your package
- tag: publish with a given tag that you can install by name@tag, default is stable
- force: force publish when the package exists
unpublish
Unpublish a package, arguments below
- name: the package name
- version: the package version
LISENCE
Copyright (c) 2014 popomore. Licensed under the MIT license.
0.4.4
5 years ago
1.0.2
5 years ago
1.0.1
8 years ago
0.4.3
9 years ago
0.4.2
9 years ago
1.0.0
9 years ago
0.4.1
9 years ago
0.4.0
9 years ago
0.3.7
9 years ago
0.3.6
9 years ago
0.3.5
9 years ago
0.3.4
9 years ago
0.3.3
9 years ago
0.3.2
9 years ago
0.3.1
9 years ago
0.3.0
9 years ago
0.2.11
9 years ago
0.2.10
9 years ago
0.2.9
9 years ago
0.2.8
9 years ago
0.2.7
9 years ago
0.2.6
9 years ago
0.2.5
10 years ago
0.2.4
10 years ago
0.2.3
10 years ago
0.2.2
10 years ago
0.2.1
10 years ago
0.2.0
10 years ago
0.1.0
10 years ago