suite rule и suite list

- suite rule дописывает правило: номер берётся следующим за наибольшим, блоки
  раскладываются в порядке норма, ПОЧЕМУ, ПРИМЕРЫ, --after ставит правило рядом
  с тем, которое оно уточняет
- ступень называется категорией (requirement, prohibition, ...), а не словом
  языка, поэтому вызывающему не нужно знать, на каком языке записан набор
- suite list показывает темы со слоями, а с осью — что возьмёт компонент; отбор
  слоёв вынесен в suite.Assemble, откуда его возьмут проектные команды
- слои темы теперь всегда возвращаются базовым вперёд
This commit is contained in:
av
2026-07-27 11:36:19 +03:00
parent 5321fba89d
commit 8331aa1ca5
8 changed files with 706 additions and 6 deletions
+7 -1
View File
@@ -63,7 +63,7 @@ func Run(env Env, args []string) ExitCode {
func runSuite(env Env, args []string) ExitCode {
if len(args) == 0 {
fmt.Fprintln(env.Err, "convy suite: a subcommand is required — init, add, retire or check")
fmt.Fprintln(env.Err, "convy suite: a subcommand is required — init, add, rule, retire, list or check")
return Usage
}
switch args[0] {
@@ -73,8 +73,12 @@ func runSuite(env Env, args []string) ExitCode {
return runSuiteInit(env, args[1:])
case "add":
return runSuiteAdd(env, args[1:])
case "rule":
return runSuiteRule(env, args[1:])
case "retire":
return runSuiteRetire(env, args[1:])
case "list":
return runSuiteList(env, args[1:])
default:
fmt.Fprintf(env.Err, "unknown subcommand %q for convy suite\n", args[0])
return Usage
@@ -94,7 +98,9 @@ In a project:
In a suite:
convy suite init start a suite: a directory and a manifest
convy suite add add a convention: a file, a topic and a prefix
convy suite rule add a rule: the next number, the blocks in order
convy suite retire retire a rule, a convention or a topic — never reusing it
convy suite list what the suite holds, and what a component would take
convy suite check suite integrity: prefixes, topics, axes, links, form
The commands that change something run in two modes. Bare, they ask for every