From c211357e7020ac25ce59b93ffaaf4f05a655c3d7 Mon Sep 17 00:00:00 2001 From: Jordan Harband Date: Tue, 17 Dec 2013 13:07:02 -0800 Subject: [PATCH 1/4] Ignore node_modules. --- .gitignore | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.gitignore b/.gitignore index 6d21b3b..a942fc1 100644 --- a/.gitignore +++ b/.gitignore @@ -7,4 +7,7 @@ alias bak .urchin.log +node_modules/ + .DS_Store + From 8143f5a618f7425ea75f2c9a50b1dfadd9b86047 Mon Sep 17 00:00:00 2001 From: Jordan Harband Date: Tue, 17 Dec 2013 13:07:52 -0800 Subject: [PATCH 2/4] ignore more urchin output. --- .gitignore | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index a942fc1..56fd724 100644 --- a/.gitignore +++ b/.gitignore @@ -4,8 +4,9 @@ v* alias # For testing -bak +test/bak .urchin.log +.urchin_stdout node_modules/ From 7afe2c5e2de4ba08809dc8a8de4b6f319dfc490a Mon Sep 17 00:00:00 2001 From: Jordan Harband Date: Tue, 17 Dec 2013 13:07:58 -0800 Subject: [PATCH 3/4] Add a package.json. --- package.json | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 package.json diff --git a/package.json b/package.json new file mode 100644 index 0000000..a444327 --- /dev/null +++ b/package.json @@ -0,0 +1,33 @@ +{ + "name": "nvm", + "version": "0.2.0", + "description": "Node Version Manager - Simple bash script to manage multiple active node.js versions", + "directories": { + "test": "test" + }, + "scripts": { + "test": "urchin test", + "test/fast": "urchin -f test/fast", + "test/slow": "urchin -f test/slow" + }, + "repository": { + "type": "git", + "url": "git://github.com/creationix/nvm.git" + }, + "keywords": [ + "nvm", + "node", + "version", + "manager" + ], + "author": "Tim Caswell ", + "license": "MIT", + "bugs": { + "url": "https://github.com/creationix/nvm/issues" + }, + "homepage": "https://github.com/creationix/nvm", + "devDependencies": { + "urchin": "~0.0.2" + } +} + From 9021cf579a5937c287220a95b7bec76d073cecbb Mon Sep 17 00:00:00 2001 From: Jordan Harband Date: Tue, 17 Dec 2013 13:09:55 -0800 Subject: [PATCH 4/4] Updating the README. --- README.markdown | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/README.markdown b/README.markdown index 51b4d19..eba57e1 100644 --- a/README.markdown +++ b/README.markdown @@ -80,26 +80,24 @@ The above copyright notice and this permission notice shall be included in all c THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ## Running tests -Tests are written in [Urchin](https://github.com/scraperwiki/urchin). Install Urchin like so. +Tests are written in [Urchin](https://github.com/scraperwiki/urchin). Install Urchin (and other dependencies) like so: - npm install -g urchin - -(Or put it some other place in your PATH.) + npm install There are slow tests and fast tests. The slow tests do things like install node and check that the right versions are used. The fast tests fake this to test things like aliases and uninstalling. From the root of the nvm git repository, run the fast tests like this. - urchin test/fast + npm run test/fast Run the slow tests like this. - urchin test/slow + npm run test/slow Run all of the tests like this - urchin test + npm test Nota bene: Avoid running nvm while the tests are running.