Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 108 lines (79 sloc) 3.558 kB
98a5bb9 @tj Initial commit
tj authored
1
2 # component
3
d06fab4 @tj docs
tj authored
4 Component package manager.
5
6 ## Installation
7
8 $ npm install -g component
9
10 ## Installing packages
11
12 To install one or more packages, simply pass their github
13 repo names as arguments to `component install`. Dependencies
14 are resolved and the component contents are downloaded into
15 `./components` by default.
16
17 ```
18 $ component install component/tip
19
20 install : component/tip@master
21 dep : component/emitter@master
22 install : component/emitter@master
23 dep : component/jquery@master
24 install : component/jquery@master
25 fetch : component/tip:index.js
26 fetch : component/tip:tip.css
27 fetch : component/tip:tip.html
28 fetch : component/emitter:index.js
29 fetch : component/jquery:index.js
30 complete : component/emitter
31 complete : component/jquery
32 complete : component/tip
33 ```
34
35 ## Usage
36
37 Via `--help`:
38
39 ```
40 Usage: component <command> [options]
41
42 Options:
43
44 -h, --help output usage information
45 -V, --version output the version number
46
47 Commands:
48
49 install <name ...> install one or more components
50 search [query] search with the given query
51 info [prop] output json component information
52 ls list installed components
53 ```
98a5bb9 @tj Initial commit
tj authored
54
32f16ca @tj docs
tj authored
55 ## Features
56
57 - no registry required, uses github repositories
58 - fast (~2x faster than uncached npm at the time of comparison)
59 - extensible sub-commands via `component-YOURCOMMAND`
60 - hackable internals (no monolithic lib here)
61 - resolves dependencies
62
0724267 @tj docs
tj authored
63 ## Dependencies
64
65 By using GitHub as the registry, `component(1)` is automatically
66 available to you without further explicit knowledge or work
67 creating a registry account etc.
68
69 A nice side-effect of this namespaced world is that dependencies
70 are explicit and self-documenting. No longer do you need to query
71 the registry for a "repo" property that may not exist, it's simply
72 build in to the package name, for example ["visionmedia/page.js"](https://github.com/visionmedia/page.js) rather
73 than the ambiguous "page".
74
460e6fe @tj add some dev docs
tj authored
75 ## Developing component(1)
76
77 `component(1)` and sub-commands are structured much like `git(1)`,
78 in that sub-commands are simply separate executables. For example
79 `$ component info pkg` and `$ component-info pkg` are equivalent.
80
81 Because of this you'll likely want `PATH="./bin:$PATH"` in your
82 profile or session while developing component, otherwise `./bin/component`
83 will have a hard time finding the sub-commands.
84
98a5bb9 @tj Initial commit
tj authored
85 ## License
86
87 (The MIT License)
88
89 Copyright (c) 2012 TJ Holowaychuk &lt;tj@vision-media.ca&gt;
90
91 Permission is hereby granted, free of charge, to any person obtaining
92 a copy of this software and associated documentation files (the
93 'Software'), to deal in the Software without restriction, including
94 without limitation the rights to use, copy, modify, merge, publish,
95 distribute, sublicense, and/or sell copies of the Software, and to
96 permit persons to whom the Software is furnished to do so, subject to
97 the following conditions:
98
99 The above copyright notice and this permission notice shall be
100 included in all copies or substantial portions of the Software.
101
102 THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
103 EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
104 MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
105 IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
106 CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
107 TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
108 SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Something went wrong with that request. Please try again.