- v1.0.0-alpha.8Latest
- v1.0.0-alpha.7
- v1.0.0-alpha.6
- v1.0.0-alpha.5
- v1.0.0-alpha.4
- v1.0.0-alpha.3
- v1.0.0-alpha.2
- v1.0.0-alpha.1
- v1.0.0-alpha
- v0.9.0-alpha.2
- v0.9.0-alpha.1
- v0.9.0-alpha
- v0.8.0
- v0.8.0-alpha.1
- v0.8.0-alpha
- v0.7.1
- v0.7.1-alpha
- v0.7.0
- v0.6.1
- v0.6.0
- v0.6.0-alpha
- v0.5.1
- v0.5.0
- v0.4.1
- v0.4.0
- v0.3.3
- v0.3.2
- v0.3.1
- v0.3.0
- v0.2.0
- v0.1.0
- v0.0.1
- v0.0.0
edcb
edcb is a build tool and task runner for Deno. It has support for formatting, linting, testing, code coverage, bundling, and more, and it can be used via command line or TypeScript import.
Features
- Formatting, linting, and testing of TypeScript code.
- Configurable HTTP server for developing web apps.
- File watcher with automatic reload via WebSockets.
- Dynamic generation of JavaScript bundles from TypeScript modules.
- Optional coverage file generation and upload to codecov.io.
- CLI with rich diagnostic output (sub-processes, call-tree, performance).
- TypeScript API for configuration and version locking.
- Easy CI integration (see ci.yml).
CLI
Install the edcb CLI with Deno:
deno install -f -A --unstable https://deno.land/x/edcb/cli.ts
Print the help text:
edcb -h
edcb check -h
edcb serve -h
Config
Before it does anything else, edcb will look for the dev.ts module
in the working directory and run it if it exists. The edcb
CLI then
essentially becomes an alias for deno run -A --unstable dev.ts [args]
. This
allows one to lock a particular edcb version to a project, provide default
values for options, and add complex configuration such as the bundles
option.
The cli.ts module exports the cli
function, which can be used to
start the CLI manually using TypeScript. The specified options will serve as
defaults. For example, one can specify the ignore
option for the check
command, which will then be used if the --ignore
option was not provided on
the command-line. This is an example of a dev.ts
file:
// lock edcb to a particular version ('xyz' in this case)
import { cli } from "https://deno.land/x/edcb@xyz/cli.ts";
await cli({
// default options for check
check: {
ignore: "deps",
},
// default options for serve
serve: {
port: 8080,
root: ".",
webRoot: "docs",
// not available in the CLI
bundles: [{
source: "index.ts", // relative to root
target: "index.js", // relative to webRoot
}],
},
});
Use individual commands by importing them from mod.ts:
import { check } from "./mod.ts";
await check({
ignore: "deps",
});