Skip to content
Skill

Upgrade nixos

Guides an agent through upgrading a NixOS flake to a new stable release

Upgrade nixos is an open-source agent skill for developer tools. It is available on Claude Code.

Scripts
None
Platforms
Claude Code
GitHub stars
39
Last commit
License
MIT
Listing updated

Similar skills

About Upgrade nixos

This skill walks an agent through moving a NixOS configuration from one stable release to the next, such as 25.05 to 25.11. It has the agent check the current NixOS and Nix versions, then find the version-pinned flake inputs (nixpkgs, home-manager, nix-darwin and stylix) that need bumping to matching release branches.

Before changing anything, the agent researches the target release's breaking changes and checks which of them touch the user's modules, with particular attention to areas such as Niri, Docker, Steam, Secure Boot and impermanence. The output is a written upgrade plan with exact file changes, verification commands and rollback steps, which the agent is expected to save into an overlay issues folder. Applying the upgrade is left until the user is ready, and the skill uses justfile recipes for updating the lock file, building and switching.

The skill assumes a flake-based NixOS setup with a justfile and the creating-plans skill available. It excludes routine flake.lock refreshes within the same release, which are handled by a separate upgrade-flake skill. Lanzaboote and nixpkgs-unstable are kept at their existing pins.

When your agent uses it

This skill upgrades NixOS to a new release version (e.g., 25.05 → 25.11). Triggers: "upgrade nixos", "upgrade to new release", "update nixos version", "move to nixos 25.11", "nixos release upgrade", "upgrade system version". Researches breaking changes, updates flake inputs, guides through upgrade. Not for flake.lock updates within same release (use upgrade-flake for that).

From the skill's SKILL.md. Your agent reads this description to decide when to load the skill.

What it can access

From a static check of its 1 file (2 KB) on GitHub on 3 December 2026. Nothing was run. Read the files before you install a skill: it can tell your agent to run anything its tools allow.

Check another skill before you install it.

Install

Copy the skill folder to ~/.claude/skills/upgrade-nixos to use it in all your projects:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/richardgill/nix.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/upgrade-nixos &&
cp -R "$tmp/.claude/skills/upgrade-nixos" ~/.claude/skills/upgrade-nixos &&
rm -rf "$tmp"

For one project only, put the folder in .claude/skills/upgrade-nixos inside it instead.

Claude Code docs on skills

Copy the skill folder to ~/.agents/skills/upgrade-nixos to use it in every repository:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/richardgill/nix.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/upgrade-nixos &&
cp -R "$tmp/.claude/skills/upgrade-nixos" ~/.agents/skills/upgrade-nixos &&
rm -rf "$tmp"

For one repository only, put the folder in .agents/skills/upgrade-nixos inside it instead.

Codex docs on skills

Copy the skill folder to ~/.cursor/skills/upgrade-nixos to use it in every project:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/richardgill/nix.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/upgrade-nixos &&
cp -R "$tmp/.claude/skills/upgrade-nixos" ~/.cursor/skills/upgrade-nixos &&
rm -rf "$tmp"

For one project only, put the folder in .cursor/skills/upgrade-nixos inside it instead.

Cursor docs on skills

Run in a terminal (add --scope workspace to install it for the current workspace only):

gemini skills install https://github.com/richardgill/nix.git --path .claude/skills/upgrade-nixos

Or copy the folder to ~/.gemini/skills/upgrade-nixos yourself.

Gemini CLI docs on skills

For GitHub Copilot in VS Code, copy the skill folder to ~/.copilot/skills/upgrade-nixos:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/richardgill/nix.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/upgrade-nixos &&
cp -R "$tmp/.claude/skills/upgrade-nixos" ~/.copilot/skills/upgrade-nixos &&
rm -rf "$tmp"

For one project only, put the folder in .github/skills/upgrade-nixos inside it instead.

VS Code docs on skills

Get the folder:

git clone --depth 1 https://github.com/richardgill/nix.git

Then copy nix/.claude/skills/upgrade-nixos into your agent's skills folder as upgrade-nixos. Agents that support SKILL.md read one folder per skill.

The SKILL.md format

What it does

Version input bumping
Updates nixpkgs, home-manager, nix-darwin and stylix pins to the matching new release branches.
Breaking change research
Looks up release notes and flags changes that affect the configured modules.
Written upgrade plan
Produces a plan with exact file edits, verification commands and rollback instructions.
Safe build before switch
Runs a build check before applying the new system generation.
Post-upgrade verification
Checks NixOS, Nix, Docker, tailscaled and Niri versions and service status after the upgrade.
Rollback guidance
Lists commands to roll back the system generation and restore flake files.

Good for

  • Upgrade my NixOS flake from 25.05 to 25.11
  • Check whether the new NixOS release breaks my Niri or Docker setup
  • Write a plan for moving my config to the next NixOS stable release
  • Bump home-manager and stylix to their matching release branches

Upgrade nixos FAQ

When does Upgrade nixos trigger?

It triggers on requests such as upgrade nixos, upgrade to new release, update nixos version, or nixos release upgrade. It is not meant for flake.lock updates within the same release.

What does Upgrade nixos change on my system?

It edits version-pinned flake inputs and writes an upgrade plan file. The actual switch to the new configuration happens only when the user is ready.

Which inputs are left alone?

Lanzaboote stays on its explicit version pin, nixpkgs-unstable keeps tracking unstable, and inputs that follow nixpkgs update automatically.

How do I roll back if the upgrade fails?

The skill prints rollback steps: run sudo nixos-rebuild switch --rollback and restore flake/flake.nix and flake/flake.lock from git.

How do I install Upgrade nixos in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/upgrade-nixos to use it in all your projects, or to .claude/skills/upgrade-nixos in one project.

Does Upgrade nixos run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

Which AI agents can use Upgrade nixos?

Claude Code. It reads skills in the SKILL.md format; the install steps on this page show where to put the folder.

What are the best alternatives to Upgrade nixos?

The closest alternatives to Upgrade nixos are Upgrade flake, Vue upgrade, Dependency upgrade, Upgrading react native and Doca upgrade.

Where this comes from

  • Description: from the skill's own SKILL.md.

More from richardgill/nix

  1. Updates NixOS flake.lock to newest input commits without changing the release

    • Open source
    • 39 GitHub stars
    • Developer tools
  2. Proposes short, durable additions to AGENTS.md and CLAUDE.md files after a lesson is

    • Open source
    • 39 GitHub stars
    • Developer tools
  3. Lets your agent drive a browser: open pages, read elements, fill forms and capture results

    • Open source
    • 39 GitHub stars
    • Browser automation
  4. Builds a JSON-driven guided code tour and opens it in your running Neovim

    • Open source
    • 39 GitHub stars
    • Developer tools
  5. Shows all uncommitted git changes, staged, unstaged and untracked, in one view

    • Open source
    • 39 GitHub stars
    • Developer tools
  6. Guides an agent through creating, editing, syncing and merging stacked GitHub pull

    • Open source
    • 39 GitHub stars
    • Developer tools