dotfiles: Skill for Claude Code

.claude/skills/nix-darwin/SKILL.md

nix-darwin is a skill for Claude Code from ahonn/dotfiles. It costs 31 tokens per session (580 once invoked), scanned A, original, MIT.

A guide for organizing macOS configuration with nix-darwin, Home Manager, and Homebrew. It separates system settings, user settings, and graphical applications into layers.

In plain words
What is it for?
Use it to add or enable programs, manage workstation and homelab configurations, and organize Nix-based macOS settings.
Why use it?
It gives a consistent structure for maintaining a Mac setup across different machines. It helps keep host-specific changes from being mixed into shared configuration.

Skill for Claude Code

Written for Claude Code: user-invocable in frontmatter. Also seen: mentions CLAUDE.md.

This is ahonn/dotfiles's own configuration. It tells Claude Code how to work on dotfiles itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything dotfiles configures →

Reuse

Borrowing it

Nothing to install: this file belongs to ahonn/dotfiles. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/ahonn/dotfiles/master/.claude/skills/nix-darwin/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/ahonn/dotfiles

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for nix-darwin

README.md
[![agentmods](https://agentmods.dev/badge/skills/ahonn/dotfiles/nix-darwin/github.svg)](https://agentmods.dev/skills/ahonn/dotfiles/nix-darwin)
Your own site
<a href="https://agentmods.dev/skills/ahonn/dotfiles/nix-darwin"><img src="https://agentmods.dev/badge/skills/ahonn/dotfiles/nix-darwin/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for nix-darwin

Your own site · 80×15
<a href="https://agentmods.dev/skills/ahonn/dotfiles/nix-darwin"><img src="https://agentmods.dev/badge/skills/ahonn/dotfiles/nix-darwin.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 31 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 580 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 2 findings, up to medium

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • medium Privilege Escalation · line 73
    Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
    Fix: Avoid sudo/root unless strictly required. Prefer least-privilege patterns. If elevation is needed, document the justification and scope.
  • medium Privilege Escalation · line 74
    Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
    Fix: Avoid sudo/root unless strictly required. Prefer least-privilege patterns. If elevation is needed, document the justification and scope.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00031 $0.00580
Opus 5.5 $0.00012 $0.00232
Sonnet 5.5 $0.00006 $0.00116
Haiku 4.5 $0.00003 $0.00058

Measured 1mo ago against content hash e260af61155e, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

nix-darwin scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/nix-darwin/SKILL.md · 35 lines

How it starts

The opening of the file, as written. The whole thing — 35 lines — stays where its author put it; the contents beside it link to each section on GitHub.

nix-darwin Configuration

Two hosts (workstation, homelab) are built by mkDarwinConfig in flake.nix from three layers: darwin modules (system) → home-manager (user) → nix-homebrew (GUI apps and taps). Both hosts share nixpkgs-unstable. Read the host's home.nix and homebrew.nix for what is currently enabled; do not rely on remembered program lists.

Conventions

New programs follow templates/program-module.md: an options.my.<program>.enable module under modules/home-manager/programs/, imported by the host's home.nix and enabled there. Shared programs are imported by modules/home-manager/base.nix instead.

Config delivery When to use Example
mkOutOfStoreSymlink Config edited often, applied without rebuild neovim, aerospace
builtins.readFile Config copied into the Nix store zed-editor
Inline Nix settings Small, Nix-native config ghostty, starship

Naming: kebab-case.nix files and host names, my.<program>.enable options, symlink/<name>.symlink dotfiles, and conventional commit scopes such as feat(neovim): or fix(darwin):.

Read by problem

Problem or decision Reference
Where a module is wired in, or why the layout is shaped this way architecture.md
Build, rollback, generations, input updates, garbage collection commands.md
darwin-rebuild or evaluation failure, Homebrew DSL or tap errors, macOS compatibility gotchas.md
The user asks how to restructure or improve the configuration community-patterns.md — check each pattern's status in this repo first

Complete the change

Evaluate each affected host with nix eval --raw .#darwinConfigurations.<host>.system.drvPath. nix flake check only checks formatting and passes even when a host fails to evaluate; nix fmt fixes formatting. Changes under modules/, hosts/, or flake.nix take effect only after darwin-rebuild switch; follow the project CLAUDE.md for when that needs confirmation.

Read the full file on GitHub · 35 lines

Files

What ships with it

5 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago Changed · -81 lines · -36 tokens per session scan B → A e260af61155e
  2. 1mo ago First seen · 116 lines · 67 tokens per session scan B a42e5b11c955

Subscribe to this mod's changes

nix-darwin is a skill published in the GitHub repository ahonn/dotfiles (63 stars, last pushed 6d ago), licensed MIT. It adds 31 tokens to every session and 580 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

coding

Principles for writing, changing, and testing code, covering readability at every scale, abstraction and naming, interfaces, comments and documentation, tests as maintained code, and standards of evidence for claims about code behavior.

ryota2357/dotfiles · 44 tokens

astropy

Core Python library for astronomy and astrophysics workflows that need Astropy APIs, including units/quantities, coordinates, FITS I/O, tables, time systems, WCS, and cosmology. Use when implementing or debugging astronomical data analysis code with Astropy.

magic3007/dotfiles · 56 tokens

benchling-integration

Benchling Python SDK and REST API integration for registry entities, inventory, ELN entries, workflows, Benchling Apps, and Data Warehouse queries. Use when automating lab data with benchling-sdk or the v2 API.

magic3007/dotfiles · 50 tokens

toil-offloading-pi

Orchestrate decomposable workloads with pi subagents (afang-subagent extension): the strong-but-slow root agent clarifies goals, cuts the work into contract-bearing subtasks, fans them out to cheap-and-fast subagents, grades delivery risk, runs an independent review where it pays, and accepts the result. Use when the…

magic3007/dotfiles · 111 tokens

mcp-notion-usage-guide

A usage guide for connecting AI agents to Notion databases through MCP. Notion is a workspace for documents and databases, while a database view is a saved way of displaying database records.

magic3007/dotfiles · 174 tokens

esm

Comprehensive toolkit for EvolutionaryScale protein language models including ESM3 (generative multimodal design across sequence, structure, and function) and ESM C (efficient embeddings). Use for protein sequence/structure/function tasks, inverse folding, embeddings, variant design, and ESMFold2 structure prediction…

magic3007/dotfiles · 96 tokens