Repository navigation
Description
Context
The repo already delivers the org toolchain as a dev-shell (mkProjectShell +
nix-direnv), a Nix-built devcontainer image, and thin package-only
homeManagerModules.default / nixosModules.default (#777). What it does not
deliver is the user-environment layer: shell/tmux/sesh/editor/git/~/.claude
configuration with org defaults and per-user overrides — today that exists only
as single-user, hand-maintained personal configuration outside the org.
This epic ports that seed into parameterized homeManagerModules.* (option
namespace vigos.*) shipped from this repo as a second product — its own CI
matrix, docs, and API policy, sharing the devTools SSoT, lockfile, and release
train. Consumers: the org's private NixOS server fleet (HM as NixOS module,
per-user opt-in), and standalone home-manager on personal
machines (aarch64-darwin first-class; x86_64-darwin best-effort). The
devcontainer image is not integrated.
Design authority: docs/rfcs/ADR-home-environment-modules.md (E1 below).
Confirmed decisions (from the ADR)
- Artifact: home-manager modules with options;
homeConfigurations.demoas
onboarding sugar only. Placement: this repo (parity SSoT; extraction later
is a URL change). - Inputs:
home-manageris the only new flake input. No nixvim (editor
module =programs.neovim+ nixpkgsvimPlugins.claudecode-nvim). No
third-party claude-code flake — keep thefastMoversoverlay on
nixpkgs-unstable, kept fresh by a scheduled lock bump. - Image: not integrated (HM activation can't run in
dockerToolsbuilds;
closure/CVE-gate/startup-time costs; container never needs the home env). ~/.claude:~/.claude.json+settings.local.jsonnever managed;
settings.jsonseeded copy-if-absent (seed updates announced in changelog,
re-seed = delete + re-activate); hooks + an org CLAUDE.md fragment
(~/.claude/vigos.md) copied viahome.activation(checksum-overwrite
with.bakof local edits) — no symlinks of any kind in.claude/;
top-level~/.claude/CLAUDE.mdstays user-owned (Claude Code writes to it)
and is seeded with a single@vigos.mdimport line; org defaults
pre-authorize nothing;DISABLE_AUTOUPDATER=1viahome.sessionVariables;
no home-level skills (repos stay the skills SSoT).- CLAUDE.md hierarchy: templates + guidelines, not managed files; optional
off-by-default symlink option with user-declared paths. - Optionality invariant: none → direnv → devcontainer → home env, strictly
additive; nothing work-required depends on the home env. - Platforms: bash and zsh; platform guards
(pkgs.stdenv.hostPlatform.isLinux, per-package availability);
aarch64-darwin CI build + Cachix push must exist before first colleague
onboarding; x86_64-darwin = eval-only best-effort, EOL at nixpkgs 26.05 EOL
(2026-12-31), fallback = amd64 devcontainer image. - Credentials: resident per-user secrets on servers for persistent
sessions (no SSH agent forwarding); canonical interface
~/.config/vigos/secrets/<NAME>(0600) + opt-in shell env export;
deployment out of scope (sops-nix backing on servers, hand-placed or
OS-native on laptops); interactive auth must keep working without it.
Hygiene: scoped/revocable only — fine-grained expiring PATs, Claude
setup-token, Cachix not per-user; SSH keys (auth + signing) minted per
user × host, never copied — signatures identify the originating machine. - Sandboxing: working agreement (autonomous runs in container), not a
security boundary; bwrap wrapper = tracked backlog, out of scope here. - Release: modules ride existing release tags; consumers pin
github:vig-os/devcontainer/<tag>; option renames get a
mkRenamedOptionModuleshim for one release + changelog modules entry.
The workspace scaffold's untaggedvigos.urlgets aligned with the policy
in E2. Dogfood exception: the maintainer's config tracksdevas
pre-release canary until the first module-bearing tag ships. - One HM mode per user per host (central XOR standalone; never both).
Scope
In:
- Tracking only — links the sub-issues below; holds decisions + dependency graph.
Out:
- Image integration (rejected; revisit-trigger in ADR).
- nixvim editor flake (personal / future).
- bwrap sandbox wrapper (backlog issue, linked, not in this epic).
- Server-fleet adoption (private infrastructure repo's change; devkit only
keeps modules cleanly importable). - nix-darwin, macOS Intel investment, home-level skills, atuin sync server.
Sub-issues
- Track E — Policy & substrate first:
- E1 (E1 — Accept and merge ADR-home-environment-modules #815) — Accept and merge
ADR-home-environment-modules(flip
status: proposed→accepted). - E2 (E2 — Module release/versioning/changelog policy + scaffold vigos.url alignment #816) — Module release/versioning/changelog policy in
docs/NIX.md+
CHANGELOG.mdmodules subcategory + align the workspace scaffold's
untaggedvigos.urlwith the pin-tags policy. - E3 (E3 — Scheduled nixpkgs-unstable lock bump workflow #817) — Scheduled
nix flake update nixpkgs-unstableworkflow (claude-code
freshness), full CI as merge gate.
- E1 (E1 — Accept and merge ADR-home-environment-modules #815) — Accept and merge
- Track A — Library core + CI substrate:
- A1 (A1 — vigos.* option namespace, module skeleton, renamed option, umbrella default #818) —
vigos.*option namespace + module skeleton;programs.vigos-devtools
→mkRenamedOptionModule; package module becomes
homeManagerModules.packages;.defaultbecomes the all-modules umbrella
(each disabled by default); modules resolve packages from devkit's locked
nixpkgs + overlay (self-pkgs, per the [CHORE] Flake polish: treefmt-nix, deadnix/statix, nixosModules/homeManagerModules, nix run .#install #777 overlay constraint); export
homeModules.*aliases. - A2 (A2 — home-manager input + per-system homeConfigurations matrix checks #819) —
home-managerflake input + per-system flake checks building the
homeConfigurations matrix:minimal(onlyvigos.shell) andfull
(every module) for synthetic userci(/home/ci;/Users/cion
darwin; pinnedstateVersion). x86_64-linux legs join the Tier-0 gate
([CHORE] Adopt git-hooks.nix with package = pkgs.prek (supersedes #40) #778/[CHORE] Flake-checks as CI Tier 0 (garnix / nix-fast-build) #779, via PR build: adopt git-hooks.nix + prek runner, expose checks.pre-commit, and gate flake checks as CI Tier 0 #791); aarch64-linux legs on arm runners; darwin legs
build in A3 only. - A3 (A3 — aarch64-darwin + aarch64-linux home-matrix CI workflow with Cachix push #820) —
aarch64-darwinCI job (macos runner) building the matrix + Cachix
darwin push. - A4 (A4 — Wave-1 modules: vigos.{shell,multiplexer,cli,direnv,git} #821) — Wave-1 modules:
vigos.shell(bash+zsh, starship, atuin, opt-in
secretsEnvexport hook per the ADR spec),vigos.multiplexer(tmux),
vigos.cli(modern-unix configuration only — packages ship solely via
homeManagerModules.packages, never duplicated),vigos.direnv,
vigos.git(identity options;signingKeyPathdefault-null, signing
activates only when set — key minting/forge registration are C2 runbook
steps; gh, lazygit, delta).
- A1 (A1 — vigos.* option namespace, module skeleton, renamed option, umbrella default #818) —
- Track B — Dogfood migration (maintainer's personal config consumes devkit):
- B1 (B1 — Dogfood wave 1 in the maintainer's personal configuration #822) — Wave 1 consumption (may close per-module; wave complete when all
private copies are deleted); acceptance = no package changes in
nvd diffandhome-filestree diff limited to the sub-issue's
expected-diff allowlist. - B2 (B2 — Wave 2: vigos.claude + canonical secrets dir into the devcontainer #823) — Wave 2:
vigos.claude(settings-seeding policy, fragment/hooks
copy management, agent runtime deps, the optional off-by-default
workspace-CLAUDE.md management option); devcontainer consumes the
canonical secrets dir via env-file/mount (compose scaffolding only,
image untouched) — the slim token path of [FEATURE] Slim Claude Code OAuth-token forwarding (replace setup-claude.sh + sed-YAML editing) #546. - B3 (B3 — Wave 3: vigos.{sesh,ghdash,editor} #824) — Wave 3:
vigos.sesh(projects option API replacing hardcoded paths),
vigos.ghdash(parameterized filters/paths),vigos.editor
(programs.neovim+claudecode-nvim, no nixvim).
- B1 (B1 — Dogfood wave 1 in the maintainer's personal configuration #822) — Wave 1 consumption (may close per-module; wave complete when all
- Track C — Onboarding & docs:
- C1 (C1 — Bootstrap guide (docs/home) #825) —
docs/home/bootstrap guide: Determinate installer, macOS
trusted-users/Cachix trap,home-manager switch --flake, dotfile-collision
adoption path (-b backup). - C2 (C2 — Override cookbook, rollback, Intel tier, credential hygiene docs #826) — Override cookbook + rollback one-pager (HM generations /
nixos-rebuild --rollback/ image-tag pin) + the spelled-out operational
meaning of best-effort Intel + credential-hygiene one-pager (PAT
scoping/expiry, per-user×host SSH keys, rotation/offboarding runbook). - C3 (C3 — templates.personal starter flake + homeConfigurations.demo #827) —
templates.personalstarter flake (20-line personal flake importing
the modules) +homeConfigurations.demo(syntheticdemouser,full
profile, all matrix systems). - C4 (C4 — CLAUDE.md template hierarchy + directory-layout convention docs #828) — CLAUDE.md template hierarchy (org/workspace/user) + directory-layout
convention docs (the workspace-CLAUDE.md management option itself lands
withvigos.claudein B2 — C4 stays docs-only).
- C1 (C1 — Bootstrap guide (docs/home) #825) —
Dependency graph & parallelism
start in parallel: E1 E2 E3
E1 ─► A1 ─► A2 ─► A3 ─┐
└──► A4 ────────┤
├─► B1 ─► B2 ─► B3
A2 ─────────► C3 │
A3 + A4 ────────────► C1 ─► C2
E1 ─────────► C4 (independent of A/B)
- Critical path (MVP):
E1 → A1 → A2 → A3 → (A4) → B1 → C1. - MVP slice (proves the architecture end-to-end): one wave-1 module with
vigos.*options + matrix checks + darwin CI/Cachix + the maintainer's
personal configuration consuming it with zero diff + a bootstrap doc the
arm-Mac colleague follows unaided. - Conservative early-exit: stopping after B1 + C1 still delivers a usable,
documented wave-1 environment on servers and the arm Mac; taking it means
explicitly re-scoping B2/B3/C4 into follow-up issues so the epic can close
against its criteria. - Sequencing vs. open work:
release/0.4.0is in flight (cutover T4.1 — Publish-cutover to the Nix image (GATED) #639
still open and gated); the release-branch cut predates all epic code, so epic PRs
merge todevfreely and ship no earlier than the next release. Library/CI
tracks are rename-proof and may start now; the C-track doc surge ideally
lands after the [CHORE] Rename devcontainer → devkit (after publish-cutover #639) #781 rename (or uses org-level URLs); nothing here touches
T4.1 — Publish-cutover to the Nix image (GATED) #639/T4.4 — Decommission the Debian path #642 (image cutover) — by design.
Acceptance criteria
- All sub-issues closed; ADR status
accepted. nix flake checkbuilds the homeConfigurations matrix; aarch64-darwin CI
green and its closures on Cachix before first colleague onboarding.- The maintainer's personal configuration imports every module landed by this
epic (no private duplicates); each wave passed the generation-diff bar (no
package changes;home-filesdiff within the wave's allowlist). - A tier-"none" user is unaffected: dev-shell, devcontainer, CI, pre-commit all
work with no home-env dependency (optionality invariant holds). - Claude Code resolves to the same pinned version via the one
fastMovers
overlay across dev-shell, image, and home modules (store paths differ per
system); the home modules setDISABLE_AUTOUPDATERvia
home.sessionVariables(dev-shell/image counterpart = linked follow-up
chore, not this epic). - Onboarding test: colleague reaches
home-manager switchon the arm Mac with
zero live help, using C1–C3 alone.
Related existing issues
| Issue | Relation | Verdict |
|---|---|---|
| #777 flake polish (module outputs, treefmt, install app) | Introduced the package-only homeManagerModules.default/nixosModules.default this epic parameterizes (A1). |
Extended — cross-link. |
#781 rename devcontainer → devkit |
Namespace vigos.* chosen rename-proof; C-track docs sequence after it where practical. |
Related — cross-link; no gate. |
| #546 slim Claude Code OAuth-token forwarding | Resolved by the canonical secrets-dir convention: container env-file/mounts ~/.config/vigos/secrets/ (B2). |
Absorbed — implement via B2, close pointing there. |
| #779 flake checks as CI Tier 0 (closed via PR #791) | A2's matrix checks join the landed Tier-0 gate. | Landed substrate — extend. |
#795 mkProjectServices helper (closed) |
Same "second product" flake-growth pattern; no dependency. | Independent — precedent landed. |
| #639 / #642 image cutover / Debian decommission | Untouched — image integration rejected by ADR Axis 4. | Independent by design. |
| #545 agent-CLI toolkit (closed) | Precedent: agent tooling as product; its host-side counterpart is B2. | Historical. |
| #625 Nix migration master (open, tracking) | Structural template for this epic; scope disjoint. | Sibling epic. |
Refs: #625
Activity
5 remaining items
ci(home): home-matrix workflow (darwin/arm + Cachix) (#836)
feat(home): wave-1 modules (shell, multiplexer, cli, direnv, git) (#837)
feat(flake): templates.personal + homeConfigurations.demo (#838)
docs(home): bootstrap, cookbook, rollback, credentials (#839)
docs(home): CLAUDE.md template hierarchy (#840)
c-vigo commentedon Jul 4, 2026
MVP night complete — all tracks landed on
feature/814-home-environment-modules; full ledger, evidence, and the morning handoff list live in draft PR #833. B2 (#823) / B3 (#824) remain for the follow-up wave.feat(home): terminal home environment modules (wave 1) (#833)
feat(home): vigos.claude — ~/.claude policy + container secrets path (#…
feat(home): vigos.sesh + vigos.ghdash + vigos.editor (wave 3) (#845)
feat(home): vigos.claude + wave-3 modules (waves 2/3) (#846)
fix(ci): use release app token for nixpkgs bump PR creation (#890)
chore: release 0.4.1 (#202)
chore: release 0.4.1 (#898)
c-vigo commentedon Jul 8, 2026
Closing — epic complete, all sub-issues closed
Tracking-only master; acceptance is "all sub-issues closed", now met. Every
track is done:
vigos.*namespace + skeleton), A2 — home-manager input + per-system homeConfigurations matrix checks #819 (home-manager input + matrix checks), A3 — aarch64-darwin + aarch64-linux home-matrix CI workflow with Cachix push #820 (aarch64 CI + Cachix), A4 — Wave-1 modules: vigos.{shell,multiplexer,cli,direnv,git} #821 (wave-1 modules)vigos.claude+ secrets dir), B3 — Wave 3: vigos.{sesh,ghdash,editor} #824 (wave 3:vigos.{sesh,ghdash,editor})templates.personal+homeConfigurations.demo), C4 — CLAUDE.md template hierarchy + directory-layout convention docs #828 (CLAUDE.md hierarchy)The terminal home environment now ships from
vig-os/devcontainerasparameterized
homeManagerModules.*under thevigos.*namespace, consumed bythe maintainer's personal config (dogfooded through waves 1–3, #822 evidence
shows a zero-package-regression switch on the live host).
Follow-on work (server-fleet adoption, bwrap sandbox wrapper, nix-darwin) is
out-of-scope per the ADR and tracked separately.