LYR-CLI0007
several programs and none named
Reported by run, expand and build --emit for a package with several programs — [[bin]] entries — and no src/main.lyr, when --bin does not name one. The message lists the programs; the exit code is 2.
Explanation
build builds every program of a package. run, expand and --emit work on one: the package's src/main.lyr, or its only program. With several [[bin]] programs and no src/main.lyr, choosing one would be a guess.
Name the program with --bin <name>, as the message suggests.
Example
$ cat lyric.toml
[package]
name = "tools"
version = "0.1.0"
[[bin]]
name = "fmt"
entry = "src/fmt.lyr"
[[bin]]
name = "lint"
entry = "src/lint.lyr"
$ lyric5 run
error[LYR-CLI0007]: package 'tools' has several programs and no src/main.lyr: fmt, lint
= help: --bin <name> names the one to run
$ lyric5 run --bin fmt