node package manager

whim

whim

NPM version Downloads Tip

A protean toolkit based on my mercurial preferences. Read the code for details.

Install

$ npm install --global whim
$ npm install --save-dev whim

Usage

  whim <task> [subtask] [options]
 
  Tasks
 
    init               Code generator.
    ├─ module
    └─ website
 
    lint               Code linter.
    ├─ all (default)
    ├─ css
    └─ js
 
    make               Code builder.
    ├─ all (default)
    ├─ clean
    ├─ css
    ├─ html
    ├─ js
    ├─ server
    ├─ statics
    └─ svg
 
    test               Code tester.
    ├─ all (default)
    ├─ browser
    ├─ node
    └─ report
 
  Options
 
    -h, --help         Display task help.
    -v, --verbose      Display runtime info.

Recommended Usage

The recommended way to use whim is to set a specific version number and invoke whim via npm run. By using an exact version number for a locally installed copy of whim you ensure that its constantly-changing nature doesn't bite you. Using a global install will very likely not work long term.

// package.json 
{
  ...
 
  "devDependencies": {
    "whim": "4.0.0"
  },
  "scripts": {
    "start": "whim make",
    "pretest": "whim lint",
    "test": "whim test",
    "report": "whim test report"
  },
 
  ...
}

Then:

$ npm start server -- -mv
# runs `whim make server -mv`

$ npm test
# runs `whim lint && whim test`

$ npm run report
# runs `whim test report`

API

test

Testing API.

import test from 'whim/lib/test';
 
test('should do something', async t => {
    t.pass();
});

Contribute

Standards for this project, including tests, code coverage, and semantics are enforced with a build tool. Pull requests must include passing tests with 100% code coverage and no linting errors.

Test

$ npm test

© Shannon Moeller me@shannonmoeller.com (http://shannonmoeller.com)

Licensed under MIT