Skip to content

refactor: simplify home-manager layout and fix terminal option drift#79

Merged
derangga merged 1 commit into
masterfrom
refactor/home-config-cleanup
Jul 9, 2026
Merged

refactor: simplify home-manager layout and fix terminal option drift#79
derangga merged 1 commit into
masterfrom
refactor/home-config-cleanup

Conversation

@derangga

@derangga derangga commented Jul 9, 2026

Copy link
Copy Markdown
Owner

Summary

Cleanup pass over the nix-darwin config: one latent bug fix plus several structural simplifications. No behavior change on the current host beyond the intended ones.

Changes

Bug fix (terminal option drift)

  • terminal.use was declared as an option in two independent module trees: nix-darwin (picks the Homebrew cask) and home-manager (picks the program config). Setting it on one side did not affect the other, so switching terminals could install the wrong cask. It is now a single terminal value set per host in flake.nix and passed to both sides. modules/terminal/options.nix deleted.

Layout

  • Folded home/home.nix into modules/default.nix; the flake imports ./modules directly and no longer threads modulesDir through extraSpecialArgs. home/ removed.
  • Standardized module entry files from config.nix to default.nix (aerospace, catppuccin, git, presenterm); imports now reference bare directories. sketchybar/nixvim untouched.

Simplification

  • Catppuccin flavor set once globally instead of repeated per program via a cfg binding.
  • Moved dev toolchains (bun, cargo, fnm, go, rustc, rust-analyzer) from environment.systemPackages to home.packages.
  • Replaced ~60 hand-written per-language starship version overrides with the bundled no-runtime-versions preset. File renamed nosymbol.nix to no-version.nix.
  • Enabled nix.optimise.automatic.

Docs

  • Fixed CLAUDE.md and README hostname-vs-username drift, refreshed the structure tree, added a Mermaid architecture diagram, and updated the flake config example to include the required terminal field.

Fold home/home.nix into modules/default.nix and import ./modules directly
from the flake, dropping the modulesDir indirection.

Make the terminal choice a single value passed from flake.nix to both the
nix-darwin (homebrew cask) and home-manager (program config) trees. Previously
terminal.use was declared as two independent options that could silently
diverge and install the wrong cask.

Also:
- deduplicate the catppuccin flavor into one global setting
- move dev toolchains (bun, cargo, fnm, go, rustc, rust-analyzer) to home.packages
- standardize module entry files to default.nix
- enable nix.optimise.automatic
- replace hand-written starship version overrides with the no-runtime-versions preset
- fix CLAUDE.md/README hostname-vs-username drift and add a structure diagram
@derangga
derangga force-pushed the refactor/home-config-cleanup branch from cbb5be1 to 71f77f5 Compare July 9, 2026 13:56
@derangga
derangga merged commit bc8a42b into master Jul 9, 2026
2 checks passed
@derangga
derangga deleted the refactor/home-config-cleanup branch July 9, 2026 13:57
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