rcl
rcl copied to clipboard
Taskfile as an alternative to Ninja
Doc page: https://docs.ruuda.nl/rcl/using_ninja/
Task is a lot easier than Ninja. Here's an example:
Prevent unnecessary work
By fingerprinting locally generated files and their sources
If a task generates something, you can inform Task the source and generated files, so Task will prevent running them if not necessary.
version: '3'
tasks:
build:
deps: [js, css]
cmds:
- go build -v -i main.go
js:
cmds:
- esbuild --bundle --minify js/index.js > public/bundle.js
sources:
- src/js/**/*.js
generates:
- public/bundle.js
css:
cmds:
- esbuild --bundle --minify css/index.css > public/bundle.css
sources:
- src/css/**/*.css
generates:
- public/bundle.css