NixOS Package Management

VerifiedCaution

Helps with NixOS package management and dotfiles configuration. Activates for installing, removing, or searching packages, performing system updates, and editing NixOS configuration files. Useful for NixOS users who manage their system declaratively.

Sby Skills Guide Bot
DevOpsIntermediate
6/2/2026
Claude CodeCursorWindsurf
#nixos#package-management#dotfiles#configuration

Recommended for

Automated summary

Manages NixOS configuration, package installation/removal, system updates, and dotfiles via an nrs alias.

Strengths

  • Automates editing configuration.nix to add/remove packages
  • Runs NixOS rebuild and handles build errors
  • Version controls changes with Git and offers to push

Limitations

  • Requires a specific Dotfiles layout (~/Dotfiles)
  • Relies on user-defined nrs alias (nixos-rebuild switch)
  • Does not handle complex multi-user configurations
When to use it

For any NixOS package management or configuration task with an organized dotfiles setup.

When not to use it

On a non-NixOS system or if the user prefers manual dotfiles management.

Security analysis

Caution
Quality score85/100

The skill performs system-wide NixOS rebuilds via `nrs` (nixos-rebuild switch) which runs with elevated privileges and can modify the entire system configuration. It also commits and optionally pushes to a Git repository. These are legitimate administrative actions but come with inherent risk if misused, though the skill includes user confirmation before pushing and showing diffs. No destructive or exfiltration patterns detected.

No concerns found

How this analysis is made

Examples

Install a package
Install htop on my NixOS system.
Remove a package
Remove python2 from my user packages.
Update system
Update my NixOS flake and rebuild.

name: nix description: NixOS package management and dotfiles configuration. Activates for package install/remove/search, system updates, and configuration changes.

NixOS Package Management

Help with NixOS configuration and package management.

User input: $ARGUMENTS

Instructions

  1. Read context and config:

    • Read ~/Dotfiles/CLAUDE.md to understand the dotfiles layout
    • Read ~/Dotfiles/configuration.nix to see current packages
    • Read ~/Dotfiles/flake.nix if flake changes needed
  2. Parse the request:

    • Install package: User wants to add a package (e.g., "install htop", "add nodejs")
    • Remove package: User wants to remove a package
    • Search: User wants to find a package (e.g., "search for video editor")
    • Update: User wants to update the system
    • Other: Configuration changes, services, etc.
  3. For package install/remove:

    • Search nixpkgs to confirm exact package name: nix search nixpkgs <name>
    • Edit configuration.nix to add/remove from users.users.sasha.packages
    • Show the diff to user
  4. For search:

    • Run nix search nixpkgs <query> and summarize results
    • Suggest the most relevant package(s)
  5. For updates:

    • Run nix flake update in ~/Dotfiles
    • Then rebuild
  6. Apply changes:

    • Run: nrs (alias for nixos-rebuild switch)
    • If rebuild fails:
      • Analyze the error output
      • Identify the root cause (missing dependency, syntax error, etc.)
      • Fix the issue and retry
      • Repeat until successful or user asks to stop
    • Report success
  7. Update documentation:

    • If structural changes were made (new services, major packages), update ~/Dotfiles/CLAUDE.md
  8. Commit changes (only after successful rebuild):

    • cd ~/Dotfiles
    • git add -A
    • git commit with a descriptive message (e.g., "Add htop package", "Update flake inputs")
    • Ask user: "Ready to push to remote?"
    • Only push if user confirms

Package Locations

  • User packages: configuration.nix → users.users.sasha.packages
  • System packages: configuration.nix → environment.systemPackages
  • Flake inputs: flake.nix → for adding external flakes

From the file to a first result

The download contains exactly the content displayed on this page. This copy may differ from the latest version in the source repository.

View the source and supporting files

This download contains SKILL.md only. Any scripts, references, templates and dependencies are not included. Get the required files from the source, preserving their directory structure, before continuing.

1. Download the file

Download SKILL.md

From the root of a test project, save the file as .skill-downloads/nixos-package-management-mm8o52ci/SKILL.md, or use the command below. This folder is for inspecting the skill before installation.

Command for macOS/Linux or WSL: requires a POSIX shell and curl. On Windows without WSL, use the download button and create the folder manually.

mkdir -p '.skill-downloads/nixos-package-management-mm8o52ci' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/nixos-package-management-mm8o52ci/download' --output '.skill-downloads/nixos-package-management-mm8o52ci/SKILL.md.part' && mv '.skill-downloads/nixos-package-management-mm8o52ci/SKILL.md.part' '.skill-downloads/nixos-package-management-mm8o52ci/SKILL.md'

2. Check prerequisites

Read SKILL.md before using it. If it references scripts or external services, inspect them and prepare the required access in your test environment.

No recognized prerequisites section in this file. This does not mean it is self-contained: libraries, tools and access requirements may be mentioned elsewhere in the content or source repository.

The platforms on this page are catalog indications. The paths below follow tool documentation; they do not prove this skill has been run in those tools. No minimum tool version is confirmed for this listing.

3. Load the skill

After inspection, copy the complete folder into your project using one of the commands below, then open a new tool session. The command stops if a folder with the same name already exists: compare the files before replacing it.

Claude Code
test -f '.skill-downloads/nixos-package-management-mm8o52ci/SKILL.md' && test -s '.skill-downloads/nixos-package-management-mm8o52ci/SKILL.md' && mkdir -p '.claude/skills' && test ! -e '.claude/skills/nix' && cp -R '.skill-downloads/nixos-package-management-mm8o52ci' '.claude/skills/nix'

Cursor
test -f '.skill-downloads/nixos-package-management-mm8o52ci/SKILL.md' && test -s '.skill-downloads/nixos-package-management-mm8o52ci/SKILL.md' && mkdir -p '.cursor/skills' && test ! -e '.cursor/skills/nix' && cp -R '.skill-downloads/nixos-package-management-mm8o52ci' '.cursor/skills/nix'

OpenSkills

OpenSkills must already be installed. The local install/read procedure is checked with OpenSkills 1.5.0, which requires Node.js ≥ 20.6.0. Catalog slugs are not resolved automatically.

Official OpenSkills installation
openskills install './.skill-downloads/nixos-package-management-mm8o52ci'

openskills read 'nixos-package-management-mm8o52ci'

Reading should display the installed file content and its base directory. It does not run the skill or install its dependencies.

For an agent that reads AGENTS.md, then sync the index. This command changes AGENTS.md: review the diff before using it.

openskills sync

Manual method or another tool: attach SKILL.md to a conversation, or open it in an agent that can read files. Include any required supporting resources. No universal folder is recognized by every tool.

4. Try a first task

Use a short, synthetic input: an API endpoint, a small document or an interface brief. In a new conversation, attach the file or give the agent its path, then adapt this request:

Read .skill-downloads/nixos-package-management-mm8o52ci/SKILL.md and apply its instructions to this example: [describe a test input]. Identify any missing files, dependencies or access. Produce the result requested by the skill without inventing data or running unreviewed scripts.

Expected result: output matching the skill instructions, or a precise list of missing prerequisites. A read confirmation alone does not validate a first use. If an external resource is unavailable, that path remains untested.

Related skills