nix-darwin
Skill9 starsChanged 55 days agoMITView on GitHub
Configure, build and troubleshoot nix-darwin macOS system configurations and darwin-rebuild generations.
2 other projects use a version of this.
Adopted by
Most recently taken up by
- jpoehnelt/skillstheir own version, first seen Nov 1, 2026
- ahonn/dotfilestheir own version, first seen Sep 10, 2026
Other versions2 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 2
- ahonn/dotfiles★ 62same name
- jpoehnelt/skills★ 23same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository10 other files it gives its agents.
- AGENTS.mdAGENTS.md
- devenv-projectSkill
- home-managerSkill
- microvm-nixSkill
- nix-languageSkill
- nixos-coding-agentsSkill
- nixos-operationsSkill
- nixos-wikiSkill
- nixpkgs-developmentSkill
- nix-workflowSkill
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 0 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 8
Read the repository instructions, the flake (a darwinConfigurations output) or configuration.nix, its nix-darwin and Nixpkgs pins, and the …
- Very specific: line 36
Start with build to validate a change.
- Very specific: line 58
Never search /nix/store (for example find /nix/store/*foo-* -name libfoo.so) and never copy a literal store path.
- Very specific: line 62
Do not quote attribute names that are valid identifiers ([A-Za-z_][A-Za-z0-9_'-]*, dashes included).
≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
nix-darwin
Read the repository instructions, the flake (a darwinConfigurations output)
or configuration.nix, its nix-darwin and Nixpkgs pins, and the host name
before editing. The bundled README covers
prerequisites, flake and channel setups, updating and uninstalling. It
describes the snapshot in sources.json, not necessarily the
user's pin. Check version-sensitive behaviour against the user's nix-darwin
revision.
Applying configuration
darwin-rebuild builds and activates a configuration:
| Command | Effect | Needs root |
darwin-rebuild build --flake .#HOST | Build only, leaving ./result | No |
darwin-rebuild check --flake .#HOST | Build and run activation checks | Yes |
darwin-rebuild switch --flake .#HOST | Build, activate and make it the current generation | Yes |
darwin-rebuild --list-generations | List system generations | No |
darwin-rebuild --rollback | Activate the previous generation | Yes |
darwin-rebuild --switch-generation N | Activate generation N (-G N) | Yes |
darwin-rebuild changelog --flake .#HOST | Build, then page the configuration's nix-darwin change log | No |
Without .#HOST, the flake attribute defaults to the Mac's LocalHostName.
Without --flake, darwin-rebuild uses /etc/nix-darwin/flake.nix if it
exists, and otherwise the channel-based configuration.nix. Pass
--no-flake to force the latter. Commands that need root are run with
sudo.
Start with build to validate a change. check, switch, activate,
rollbacks and uninstalling change the running system. Propose them with the
exact command, and run them only with the user's authorization. The README's
uninstall steps are reference, never an action to take on your own.
Related configuration
Home Manager loaded as a nix-darwin module (home-manager.darwinModules) is
applied by darwin-rebuild, not home-manager switch. Use the
home-manager skill if it is installed, or the
Home Manager manual. Nix
settings on nix-darwin are declared through nix.settings. Do not edit
/etc/nix/nix.conf by hand. Nix itself, and its installer's choices, belong
to the host; check them before changing daemon settings.
Options are not bundled. Search them in the user's pinned nix-darwin source, or in the nix-darwin option documentation for that revision.
Modified upstream material is covered by LICENSE.
Nix style
- Never search
/nix/store(for examplefind /nix/store/*foo-* -name libfoo.so) and never copy a literal store path. Find the providing package withnix-locate, and refer to it through Nix:${pkgs.foo}/liborlib.makeLibraryPath [ pkgs.foo ]. - Do not quote attribute names that are valid identifiers
(
[A-Za-z_][A-Za-z0-9_'-]*, dashes included). Writepkgs.foo-barandpackages.x86_64-linux, notpkgs."foo-bar". Quote only other names (".config/foo","2.0"), the keywordsassert else if in inherit let or rec then with, and interpolations ("${name}"). Upstream examples in references sometimes quote needlessly; do not copy that style.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

