From f96266feb81c8388cef37c219e3f60fbac49d473 Mon Sep 17 00:00:00 2001 From: Noah Pederson Date: Mon, 22 Jun 2026 14:59:22 -0500 Subject: [PATCH] Add readme --- README.md | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..c7d20f9 --- /dev/null +++ b/README.md @@ -0,0 +1,35 @@ +# disag + +Run commands concurrently and mirror their output. + +## Usage + +```sh +./disag.js \ + 'npm test' -n TEST -f ./test.log \ + 'npm run lint' -n LINT -f ./lint.log +``` + +Options apply to the command immediately before them. + +## Options + +- `-n, --name `: prefix displayed lines with `[name]`. +- `-f, --file `: write raw stdout/stderr to a log file. +- `-s, --shell`: run the command with `sh -c`. +- `-r, --retry`: retry until the command exits with code 0. +- `--sleep `: wait before retrying, e.g. `250ms`, `1s`, or `0`. +- `-z, --no-color`: disable ANSI color. +- `-h, --help`: show help. + +Retry until success: + +```sh +./disag.js 'flaky-command' -r --sleep 250ms -n FLAKY +``` + +Use shell syntax: + +```sh +./disag.js 'echo out; echo err >&2' -s -n SHELL +``` -- 2.51.2