Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ricardobeat/taks
Minimalistic ES7 async/await task runner
https://github.com/ricardobeat/taks
build grunt gulp postcss rollup task-runner tasks tasks-automation tool
Last synced: 23 days ago
JSON representation
Minimalistic ES7 async/await task runner
- Host: GitHub
- URL: https://github.com/ricardobeat/taks
- Owner: ricardobeat
- Created: 2018-03-20T14:59:15.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2022-12-07T02:10:23.000Z (about 2 years ago)
- Last Synced: 2024-11-08T17:12:10.613Z (3 months ago)
- Topics: build, grunt, gulp, postcss, rollup, task-runner, tasks, tasks-automation, tool
- Language: JavaScript
- Size: 294 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 11
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# taks
Minimalistic ES7 async/await based task runner.
Zero dependencies. It expects the consumer to provide all the necessary transforms, preserving full access to the original APIs and flexibility.
## Usage
Create a `task.js` file at the root of your project:
```js
const task = require('taks')task('styles', async function () {
await postcss('./entry.css', './dist/output.css')
})task('scripts', async function () {
await rollup('./entry.js', './dist/output.js')
})task('build', async function () {
task.parallel(['scripts', 'styles'])
})task.run(process.argv[2])
```Then run `node task build` to trigger the `build` task.
## Transforms
For a more complete example showing more complex usage of flow control, and implemenntation of [rollup](https://ghub.io/rollup), [postcss](https://ghub.io/postcss) and [uglify](https://ghub.io/uglify-es) transforms, see this [sample task.js file](https://gist.github.com/ricardobeat/606859bfcbfbdf84a030ec32382fe202).
This is the spiritual successor of [flour](http://ricardo.cc/cake-flour) and [cake-async](https://github.com/ricardobeat/cake-async) that originally used CoffeeScript and a bit of trickery to create `async` tasks back in 2013. Inspired by [taskr](https://github.com/lukeed/taskr).
## License
MIT Licensed (http://ricardo.mit-license.org)