A Yeoman generator providing (personally flavoured) tools for writing node packages
This simple generator is what I use when working on node packages. In particular, it allows for quickly spinning up unit tests backed by a testing setup that conforms to my personal likings.
$ npm install generator-jingle
Initialize a package
--skip-install
It will try to to infer appropriate defaults:
$ mkdir node-my-package && cd $\_
$ yo jingle:package
[?] Package name? (my-package)
[?] Github user? (tambourinecoder)
[?] Name? (Tambourinecoder)
[?] Email? ([email protected])
[?] Include tests? (Yes)
[?] Choose test additions:
[x] Mocha-JSHint
[ ] Sinon / Sinon-Chai
create package.json
create LICENSE
create README.md
create lib/index.js
create .jshintrc
create .jshintignore
create .gitignore
create .travis.yml
create test/mocha.opts
create test/support.js
create test/specs/jshint_spec.js
...
Generate a module along with a corresponding unit test
- module name(s)
$ yo jingle:module foo
create lib/foo/index.js
create test/specs/foo_spec.js
# hack hack...
$ yo jingle:module yo jingle:module foo bar-baz
create lib/foo/bar_baz/index.js
create test/specs/foo/bar_baz_spec.js
MIT