0.1.0 • Published 7 years ago

yamscripts v0.1.0

Weekly downloads
75
License
ISC
Repository
github
Last release
7 years ago

Yamscripts

A way to write npm scripts in yaml, with a few extra fancy features.

Usage

Install globally

npm install yamscripts -g

Run init in the root of your project

yamscripts init

Write some scripts in yamscripts.yml.

scripts:
# test: This is just a way to run the tests once
  test: mocha -R spec
  start: node server.js

Run npm run yamscripts to compile changes. Now your scripts should be available as npm scripts!

Run npm run help to see help documentation generated from your comments. Any comment prefixed by {script name}: will be included in the auto-generated docs.

Examples

scripts:
  test: mocha -R spec
  start: node server.js
scripts:
  test:
    pre: ./build.js
    mocha: mocha -R spec
    karma: karma start
    post: coverage.js > coveralls
# TODO: This will be deprecated
scripts:
  test:
    _parallel: true
    pre: ./build.js
    post: coverage.js > coveralls
    mocha: mocha -R spec
    karma: karma start
# TODO: This doesn't work yet
scripts:
  test:
    parallel: true
    scripts:
      pre: ./build.js
      post: coverage.js > coveralls
      mocha: mocha -R spec
      karma: karma start
scripts:
  setup: ./setup.js
  test: =>setup && mocha -R spec
  # This compiles to:
  # npm run setup && mocha -R spec
0.1.0

7 years ago

0.0.3

9 years ago

0.0.2

9 years ago

0.0.1

9 years ago

0.0.0

9 years ago