Skip to content
Agentmart
Submit a tool

nix-update

Update Nix flake inputs.

Skill by Gemini CLI

IndexedCC-BY-4.0
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/vorburger-nix-update

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Update Nix flake inputs.

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found
Runs as
Shell scripts

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/nix-update

What's inside

Skill name
nix-update
Description
Update Nix flake inputs.
License
CC-BY-4.0
Metadata
author: Gemini CLI
Instructions
35 lines in SKILL.md · view on GitHub

Before installing

  • Ships executable scripts

Files (2)

  • SKILL.md
  • nix-update.sh · scripts/

SKILL.md (first lines)

# Nix Update

This skill provides a robust way to update all flake inputs of a Nix project iteratively. Unlike a bulk `nix flake update`, this skill verifies each input's update independently to ensure stability. If a check fails, the specific input update is reverted while others continue. Use this when you want to safely update all flake dependencies one by one

## Core Logic

For every root input in the `flake.lock`:

1. **Backup**: Create a temporary backup of `flake.lock`.
2. **Update**: Run `nix flake update <input_name>`.
3. **Validate**: Run `nix flake check` to ensure the flake remains in a valid state.
4. **Commit/Revert**:
   - If validation succeeds: Keep the change and track it as successful.
   - If validation fails: Restore `flake.lock` from backup and track it as failed.
5. **Summary**: At the end of the script, a clear summary of all successful and failed updates is printed to the terminal.

## Usage

Execute the update script from the project root:

```bash
bash .agents/skills/nix-update/scripts/nix-update.sh
```

## Dependencies

- `nix`: The Nix package manager with flakes enabled.
- `jq`: Required to parse the flake inputs.
- `bash`: Required to run the automation script.

## Troubleshooting

- **`nix flake check` fails due to formatting**: Because `nix flake check` typically executes `treefmt` (or similar formatters) to verify repository-wide format compliance, having unformatted, modified files (even non-nix files like this shell script) in the working tree will cause the check to fail. **Solution**: Run `nix fmt` before running this script to ensure all files in your repository meet the formatting standards.

From vorburger/aifiles, CC-BY-4.0.

More from vorburger/aifiles

Signals

Stars
0
Forks
0
Open issues
0
Last commit (this folder)
May 14, 2026 (5 months ago)

From GitHub (fetched Oct 24, 2026).

Details

License
CC-BY-4.0
First seen
Oct 24, 2026
Last checked
Oct 24, 2026
Cite this page

nix-update skill. Agent Mart. https://agentmart.dev/skills/vorburger-nix-update (last updated 2026-10-24)