pon-task-basic

Basic task set for pon

Usage no npm install needed!

<script type="module">
  import ponTaskBasic from 'https://cdn.skypack.dev/pon-task-basic';
</script>

README

pon-task-basic

Build Status npm Version JS Standard

Basic task set for pon

Installation

$ npm install pon-task-basic --save

Usage

'use strict'

const pon = require('pon')
const {fs} = require('pon-task-basic')
const {mkdir} = fs

async function tryExample () {
  const run = pon({
    'fs:mkdir': mkdir(['lib', 'test', 'tmp']),
  })

  run('test:*')
}

tryExample()

Signatures

cron(when, task, options) -> function

Pon task to define cron

Param type Description
when string Cron time
task string&#124;function Task to run
options Object Command

define(options) -> function

Define task

Param type Description
options Object Optional settings
options.mocha Array Args for pon-task-mocha
options.fmtjson Array Args for pon-fmtjson-task
options.command Array Args for pon-command-task
options.env Array Args for pon-env-task
options.task Array Args for pon-task-task

install(options) -> function

pon task to install package

Param type Description
options Object Optional settings

sub(ponfile) -> function

define sub task

Param type Description
ponfile string

License

This software is released under the Apache-2.0 License.

Links