Template module to use as base for quickly creating bionode modules.
npm install bionode-template[![NPM version][npm-image]][npm-url]
[![Build Status][travis-image]][travis-url]
[![Coveralls Status][coveralls-image]][coveralls-url]
[![Dependency Status][depstat-image]][depstat-url]
[![Gitter chat][gitter-image]][gitter-url]
[![DOI][doi-image]][doi-url]
Principles
----------
This provides a quick template to build a bionode module. A bionode module should follow the Unix philosophy and play nice with Node.js.
That is:
* Be small, simple and do one thing well;
* Use Node's CommonJS module pattern and be available on NPM;
* Provide Node.js Streams;
* Provide a Command Line Interface compatible with Unix pipes;
* If possible, work client-side (browser) using browserify;
* Provide testing (preferably with tape and testling);
* Provide code coverage (preferably with istanbul);
* Provide code with comments and documentation (preferably with docco);
* KISS and don't abuse objects;
* Be MIT licensed.
To try to maximize the compatibility of the new module and anticipate possible use cases, the authors of the new bionode module should be aware of the existing bionode modules and other useful projects like Dat.
The following sections should be adapted and included in the README.md file.
Install
-------
Install ``bionode-template` with npm:
`sh`
$ npm install bionode-template`
To use it as a command line tool, you can install it globally by adding -g` .
Alternatively, just include bionode-template.min.js via a in your page or use Browserify.
Usage
-----
You can require the module in Node.js or in a browser:
`js`
var template = require('bionode-template')
template.greet('World').on('data', console.log)
//=> {"greeting":"Hello World"}
Please read the documentation for the methods exposed by bionode-template.
sh
$ bionode-template greet World
$ echo World | bionode-template greet
`$3
`sh
echo World | bionode-template greet | dat import --json
`Contributing
------------
To contribute, clone this repo locally and commit your code on a separate branch.
Please write unit tests for your code, and check that everything works by running the following before opening a pull-request:
`sh
$ npm test
`To test on the browser:
`sh
$ npm run test-browser
if you get "No headless browser found" do:
$ npm install -g phantomjs
$ rm ~/.config/browser-launcher/config.json
`Please also check for code coverage:
`sh
$ npm run coverage
`To rebuild and minify the module for the browser:
`sh
$ npm run build-browser
`To rebuild the documentation using the comments in the code:
`sh
$ npm run build-docs
``Contacts
--------
Bruno Vieira <mail@bmpvieira.com> @bmpvieira
Yannick Wurm (yannick.poulet.org) @yannick__
Licenses
--------
bionode-template is licensed under the MIT license.
Check ChooseALicense.com for details.
[npm-url]: http://npmjs.org/package/bionode-template
[npm-image]: http://img.shields.io/npm/v/bionode-template.svg?style=flat
[travis-url]: http:////travis-ci.org/bionode/bionode-template
[travis-image]: http://img.shields.io/travis/bionode/bionode-template.svg?style=flat
[coveralls-url]: http:////coveralls.io/r/bionode/bionode-template
[coveralls-image]: http://img.shields.io/coveralls/bionode/bionode-template.svg?style=flat
[depstat-url]: http://david-dm.org/bionode/bionode-template
[depstat-image]: http://img.shields.io/david/bionode/bionode-template.svg?style=flat
[gitter-image]: http://img.shields.io/badge/gitter-bionode/bionode--template-brightgreen.svg?style=flat
[gitter-url]: https://gitter.im/bionode/bionode-template
[doi-url]: http://dx.doi.org/10.5281/zenodo.11297
[doi-image]: http://img.shields.io/badge/doi-10.5281/zenodo.11297-blue.svg?style=flat