gunk-dev/the-valley

dcr-74c3158-valley-cli-lifecycle.md

source533c1d7e7da4main's published tip history
1.4 KiB · Rendered
1---
2type: decision
3id: dcr-74c3158
4status: decided
5title: "Keep the CLI in this repository until an explicit graduation decision"
6created: 2026-07-13
7source: ratified 2026-07-13
8---
9
10# Keep the CLI in this repository until an explicit graduation decision
11
12The `valley` CLI lives at [bin/valley](../../bin/valley) because its commands apply to any valley
13project. It can run from a checkout or through the flake package with `nix run .#valley`.
14
15The initial implementation is a shell script.
16[[ida-b9f646c]](../ideas/ida-b9f646c-nix-backend-not-substrate.md) describes the portability goal
17behind that choice.
18
19## Conditions for graduation
20
21The lifecycle policy calls for moving the CLI to its own repository and a suitable implementation
22language when any of these conditions holds:
23
24- It grows beyond roughly 300 lines.
25- It needs persistent state, configuration, or a daemon.
26- It needs dependencies beyond Git and coreutils.
27- Its behavior requires substantial testing.
28- It needs nontrivial parsing or concurrency.
29
30Graduation must be recorded as an explicit decision. These conditions are intended to keep a
31convenient script from becoming difficult to understand and maintain.
32
33[[dcr-2aa1a12]](dcr-2aa1a12-valley-cli-graduation.md) records that the dependency condition has been
34reached and proposes either graduating or replacing these rules with a specification-coverage
35requirement. That proposal remains undecided.