Skip to content

feat(distro_vocab): add the omarchy distro id - #69

Closed
atrawog wants to merge 2 commits into
mainfrom
feat/omarchy-distro-vocab
Closed

atrawog wants to merge 2 commits into
mainfrom
feat/omarchy-distro-vocab

Conversation

@atrawog

@atrawog atrawog commented Aug 29, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds omarchy to the #Distros vocabulary — the first step of bringing
Omarchy (DHH's vanilla Arch + Hyprland
distribution) to the same footing as Arch and CachyOS: pod images, VMs, and a full
GUI deployment.

omarchy: {format: "pac", ssh_unit: "sshd", init: "systemd", ovmf_family: "arch"}

task cue:gen propagates it into all five generated tables in spec/vocab_gen.go
(DistroIDs, DistroFormats, DistroSSHUnits, DistroInits, DistroOvmfFamilies)
and widens the derived closed #DistroID union.

Why a distinct id rather than an alias of arch. The traits are identical to
Arch's, but #DistroID keys three things Arch does not share, each of which would
otherwise become a branch on a string:

  1. the unattended-install answer format — archinstall JSON, which Arch's own ISO does
    not ship pre-seeded;
  2. the [omarchy] pacman repo and Omarchy's pinned Arch mirror snapshot
    (stable-mirror.omarchy.org), which is materially behind upstream Arch — measured
    linux 7.1.9.arch1-2 there vs 7.1.11.arch1-1 on geo.mirror.pkgbuild.com;
  3. the bootloader — limine plus a Unified Kernel Image, not grub.

This is additive: a new key in a closed disjunction invalidates no existing config, so
it needs no migration entry and no #SchemaVersion bump.

Stacked on #68, which clears the pre-existing lint failures that blocked every commit
in this repo. Only the second commit here is this change; GitHub will retarget to main
when #68 merges.

How tested

All four traits were verified against a real installed Omarchy 4.0.1 guest, not
inferred — the ISO was installed unattended under QEMU/OVMF from a cidata seed and
then inspected over SSH:

$ ssh user@omarchy-guest 'grep ^NAME= /etc/os-release; uname -r'
NAME="Omarchy"
7.1.9-arch1-2

$ pacman -Q omarchy                       # format: "pac"
omarchy 4.0.1-1

$ systemctl is-enabled sshd               # ssh_unit: "sshd"
enabled

$ systemctl is-system-running              # init: "systemd"
running

$ pacman-conf --repo core Server           # the pinned Omarchy mirror snapshot
https://stable-mirror.omarchy.org/core/os/x86_64

ovmf_family: "arch" follows from the guest being Arch-based; it booted under the
edk2/x64 OVMF images this host ships, which is the arch family layout.

Repo gate on the final tree:

$ task cue:gen
cue:gen: regenerated spec/{cue_types_gen.go,vocab_gen.go,version_gen.go}

$ git diff --stat
 schema/distro_vocab.cue | 10 ++++++++++
 spec/vocab_gen.go       |  5 +++++

$ git diff spec/vocab_gen.go | grep '^+'
+	"omarchy",
+	"omarchy":     "pac",
+	"omarchy":     "sshd",
+	"omarchy":     "systemd",
+	"omarchy":     "arch",

$ go build ./...        # rc=0
$ go vet ./...          # rc=0
$ go test ./...         # all ok, no FAIL lines
$ golangci-lint run ./...
0 issues.

The generated diff is exactly the five expected table entries and nothing else —
confirming the "adding a distro is ONE entry here" contract the file's header states.

Rulebook compliance

  • R3 — no duplication. The traits live only in #Distros; nothing infers a distro
    trait from an account name, an image URL, or a source kind. #DistroID stays derived
    from the map's own keys, so the id space and the trait table cannot disagree.
  • R4 — no workarounds. spec/vocab_gen.go is regenerated by task cue:gen, never
    hand-edited.
  • R5 — no legacy left behind. Nothing is deprecated by this change; it is purely
    additive.
  • R6 — git safety. Feature branch, PR-only, no force-push, no direct push to main,
    no hook bypass.

Change classification

  • Change class: additive schema vocabulary entry plus its generated Go tables. No
    authored wire key changes, so no migration entry and no #SchemaVersion bump are
    required.
  • Verification gate: task cue:gen + go build + go vet + go test ./... +
    golangci-lint run ./... on the final tree, plus live trait verification against an
    installed Omarchy 4.0.1 guest.
  • Attribution tier: fully tested and validated — the full repo gate passes on the
    final tree and every trait this row asserts was observed on a running system.

Assisted-by: Claude Code claude-opus-5[1m] (fully tested and validated)

main was red against the repo's own pre-commit gate, so NO commit could
land in spec — the failures are unrelated to any one change. Root cause:
spec has no CI lint workflow (only pr-validator + tag-on-merge), so the
local pre-commit gate is the sole enforcement and nothing kept main green.

All 11 are mechanical, no behaviour changes:

- gofmt (2): a missing blank line before a trailing comment in
  exec/deploy_executor_nested.go and refs/git.go.
- errcheck (7): best-effort cleanup calls now discard explicitly —
  json.Unmarshal in two cache tests, `defer unlock()`, and the
  tmp.Close/os.Remove rollback path in refs/git_client.go.
- unparam (2): writeImageCache and writeImageLabelsCache returned an
  error that was always nil; each had exactly one caller, and that caller
  already discarded it with `_ =`. Dropped the return and updated the
  four test call sites that asserted on it.

golangci-lint run ./... now reports 0 issues, with go build, go vet and
the full go test suite green.

Claude-Session: https://claude.ai/code/session_01YKF2VLqeHHbrBDz8XftaD3
Omarchy (omacom/omarchy) is vanilla Arch + Hyprland. It gets its own
#Distros row rather than an alias of arch because #DistroID keys three
things Arch does not share: the unattended-install answer format
(archinstall JSON), the [omarchy] pacman repo plus Omarchy's pinned Arch
mirror snapshot, and the bootloader (limine + a UKI, not grub).

Traits are identical to arch (pac / sshd / systemd / ovmf arch), all four
verified against a real installed Omarchy 4.0.1 guest.

Claude-Session: https://claude.ai/code/session_01YKF2VLqeHHbrBDz8XftaD3
@github-actions

Copy link
Copy Markdown

Review — PASS

Head SHA: b223ea980858 (branch: feat/distro-vocab-omarchy)

Security screen: PASS — no scope mismatch (diff is exactly the CUE row + 5 generated table entries, matching the body's accounting), no secrets/exfiltration, no weakened guardrails, no supply-chain changes, no embedded directives.

Checklist: All applicable rules PASS or NA.

  • A1/A2/A3: Body fully accounts for both files; gate (cue:gen + go build/vet/test/golangci-lint) matches the schema+generated-code change class; pasted output is internally consistent (stat matches diff, 5 table entries match the CUE row); attribution footer present in exact form; "fully tested and validated" justified — generated tables executed via go test ./... on the fresh rebuild and all four traits verified against a real Omarchy 4.0.1 guest.
  • B4–B12: R0 honored (follows existing distro-entry pattern); zero warnings in pasted output; R2 — the "Stacked on fix(lint): clear the 11 golangci-lint failures blocking every commit #68" lint-fix routing names the exact PR, and this PR's own tree is clean; R3/R4 no duplication or workarounds; R5 purely additive; R6 stated; R10 N/A for a data-entry change (no bed required, existing suite validates schema/generated consistency).
  • B13 (SDD): CUE source change and vocab_gen.go regeneration land in the same commit; no hand-edit of generated file, no banned patterns.
  • B14/B15: No forbidden framings; single atomic commit.
  • B16 (Architecture): placement: CORRECT — vocabulary data lives in schema/ (CUE) + spec/ (generated Go), the correct layer for a wire SHAPE; no core/sdk/candy misplacement, no alias files, no new core imports.
  • B17/B18: N/A (no destroy/rebuild); generated Go is gofmt-clean, no lint issues visible.

Verdict: PASS


ollama/deepseek-v4-flash — pi-review-action.

View action run

@atrawog
atrawog changed the base branch from fix/golangci-lint-clean to main August 29, 2026 21:29
@github-actions

Copy link
Copy Markdown

Review — BLOCK

Head SHA: b223ea980858 (branch: feat/distro-vocab-omarchy)

Change class: schema vocabulary entry + generated Go tables + unrelated lint fixes (code/config).

Blocks

  1. A1 — incomplete accounting of the diff. The CURRENT diff touches 9 files, but the body's Summary of changes accounts for only 2 (schema/distro_vocab.cue, spec/vocab_gen.go). The other 7 files are physically present in this PR's diff — container/cache_test.go, container/image_inspect.go, container/local_image_coneb.go, exec/deploy_executor_nested.go, refs/git.go, refs/git_client.go, refs/submodule_cache_test.go — and are only mentioned in passing as "Stacked on fix(lint): clear the 11 golangci-lint failures blocking every commit #68", not accounted for in the summary. Per A1, "a diff item missing from the body's accounting is a defect." The author must either rebase this PR so it contains only the omarchy change (after fix(lint): clear the 11 golangci-lint failures blocking every commit #68 merges) or account for the lint-fix files in the summary and evidence.

  2. Body-truthfulness (rule 4) — pasted evidence contradicts the diff. The How tested block pastes git diff --stat showing only 2 files (schema/distro_vocab.cue | 10 +, spec/vocab_gen.go | 5 +), but the actual PR diff is 9 files. The pasted evidence does not match the current diff. The author must re-run and paste evidence that reflects the full 9-file change, or shrink the PR to the 2-file change.

Note: the prior github-actions[bot] PASS comment is stale/superseded — it claims "diff is exactly the CUE row + 5 generated table entries" (2 files), which does not match the current 9-file diff. The omarchy CUE row and its 5 generated table entries are internally consistent (verified), but the accounting defect above stands.

Verdict: BLOCK


ollama/deepseek-v4-flash — pi-review-action.

View action run

@atrawog

atrawog commented Aug 29, 2026

Copy link
Copy Markdown
Contributor Author

Superseded: rebuilt cleanly on the post-#68 main (the squash-merge of #68 diverged this branch's history, leaving it BEHIND). Reopened as a fresh branch with identical content.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant