-func usage(cmd string) {
- var d string
- switch cmd {
- case CmdNameRedo:
- d = `Usage: redo [-j X] [-k] [-s] [-x|-xx] [options] [target ...]
-
-Forcefully and *sequentially* build specified targets.
-If no targets specified, then use "all" one.`
- case CmdNameRedoIfchange:
- d = `Usage: redo-ifchange [-j X] [-k] [-s] [-x|-xx] target [...]
-
-Build specified targets in parallel, if they are changed.
-Record them as dependencies for current target.`
- case CmdNameRedoIfcreate:
- d = `Usage: redo-ifcreate target [...]
-
-Record ifcreate dependency for current target. Unusable outside .do.`
- case CmdNameRedoAlways:
- d = `Usage: redo-always
-
-Always build current target. Unusable outside .do.`
- case CmdNameRedoCleanup:
- d = `Usage: redo-cleanup [-n] {full,log,lock,tmp} [...]
-
-Remove either all of goredo's related temporary files, or kept stderr
-logs, or lock files, or everything (including .redo directories) related.`
- case CmdNameRedoLog:
- d = `Usage: redo-log [-c] [-r] target [ | tai64nlocal ]
-
-Display kept target's stderr with TAI64N timestamped lines. Only the
-last build is kept. You must enable stderr keeping with either -logs,
-or REDO_LOGS=1. -c option show the exact command invoked, start and
-finish time. -r option recursively and linearly show also all deeper
-redo calls and their logs.`
- case CmdNameRedoDot:
- d = `Usage: redo-dot target [...]
-
-Write dependency DOT graph to stdout.`
- case CmdNameRedoStamp:
- d = `Usage: redo-stamp < [$3]
-
-Record stamp dependency for current target. Unusable outside .do.
-Stamp dependency does not play any role, as all targets are hashed
-anyway.`
- case CmdNameRedoWhichdo:
- d = `Usage: redo-whichdo target
-
-Display .do search paths for specified target. Exits successfully
-if the last .do in output if the found existing one.`
- case CmdNameRedoTargets:
- d = `Usage: redo-targets [target ...]