documentation
everything she knows
A quiet reference for a cozy tool. Find what you need, take your time.
what is nina?
introNina is a NixOS Intuitive Navigation Assistant — a gentle command-line tool that wraps the full NixOS workflow in one quiet, consistent voice.
She handles package search, rebuilds, flakes, services, generation history, and remote machines — all without dropping you into a different screen, switching tools, or making you memorise long nixos-rebuild incantations.
Nina v3 is a ground-up rewrite in Zig. Zero runtime dependencies. A single binary. Runs the same on any NixOS machine.
The goal is simple: NixOS should feel like home. Nina is one step toward that.
Nina stays inline at your prompt. Search results, install confirmations, diff previews — everything comes to you. You never leave the shell you're already in.
installation
setupNina ships pre-built binaries for Linux and macOS via Kepr Builds. One command installs the right binary for your machine:
After installing, run nina setup — it handles enabling the Nix experimental features Nina needs, no manual config editing required.
nina setup
onboardingnina setup is your onboarding step. It checks whether Nix's experimental features are already enabled and enables them for you if not — no sudo required.
What it does:
- Runs before config loading — works as a true onboarding step even with no
~/.nina.conf - Checks
/etc/nix/nix.confand~/.config/nix/nix.confforexperimental-features - If
nix-commandandflakesare already enabled: prints all set and exits cleanly - If not: appends
experimental-features = nix-command flakesto~/.config/nix/nix.conf, creating the file and~/.config/nix/directory if needed - Detects NixOS via
/etc/NIXOSand shows thenix.settings.experimental-featureshint forconfiguration.nixwhen relevant
On NixOS, the permanent way to enable these features is via configuration.nix. Nina shows you the exact line to add when it detects a NixOS system.
first run
setupJust type nina help at the prompt. She'll show you every command she knows. (っ˘ω˘ς )
Then try nina hello to see the machines Nina has configured, or jump straight to nina search to find a package.
From here, search for a package, apply a change, or just wander through the tips section to see what's possible.
search & discovery
search · optionInline search that never takes over your screen. Results appear right below the prompt, and you navigate them with the keyboard. Press esc any time to go back to what you were doing.
Search nixpkgs for packages in an 18-line inline widget — no fullscreen takeover, no context switch. Runs nix search nixpkgs under the hood.
keys: ↓↑ or jk move through results · i / Enter profile install · s system install (opens editor) · t try ephemerally · c copy attr to clipboard · Esc / q exit without action
Search NixOS options in the same inline widget. Navigation and copy work the same as package search. Install actions are not available for options — copy the snippet and add it to your config manually.
packages
install · remove · profileInstall packages into your profile with a single command. Nina searches nixpkgs, shows you what it found, and asks how you want it.
Search nixpkgs for the package, then prompt for install method. Σ(°∀° )
[i] profile install — runs nix profile install nixpkgs#attr. Available immediately, no rebuild needed.
[s] system install — opens configuration.nix in your editor at the systemPackages line. Add the package, save, and Nina asks whether to apply.
[t] try now — drops you into a nix shell with the package available. Gone when you exit.
Remove a package from your active Nix profile by name.
Drop into a temporary nix shell with the package available. Exits cleanly — nothing is written to your profile or config.
Show packages in your active Nix profile.
Low-level profile management. profile list shows all profile packages. profile upgrade upgrades all profile packages at once.
Pin or unpin a flake input to a specific commit. nina unpin runs nix flake update on that input to release the pin.
system changes
diff · apply · backPreview, apply, and roll back changes to your NixOS system. Nina shows you exactly what will change before it happens, and arms a rollback the moment things go sideways.
Compare two generations using nix store diff-closures. Without arguments, compares the previous generation to the current one. Pass two generation numbers to compare any two.
Validate your configuration with nixos-rebuild build. Catches syntax errors and missing references before they reach a running system. No activation — nothing changes.
Rebuild and switch to the new generation with nixos-rebuild switch. If confirm = true in your config, Nina asks before proceeding.
--on <machine> rebuild a remote machine over SSH --dry dry-activate only — build without switching --check validate config only, same as nina check Roll back one generation using nixos-rebuild switch --rollback. To jump to a specific generation, use nina go <n>.
Generations are immutable snapshots. nina back always has somewhere to go, and nina go <n> can reach any point in your history.
flakes & dev shells
flake · develop · buildInspect flake outputs, step into dev shells, build specific outputs, and manage the flake lifecycle — all with the same quiet vocabulary.
Show what the current directory's flake exposes — packages, apps, dev shells, NixOS configurations. Parses nix flake show --json output.
Run nix flake update. Pass a specific input name to update only that one. Prints a confirmation when flake.lock is written.
Run nix flake check. Reports valid or prints the error.
Enter the flake's dev shell with nix develop. Type exit to return. develop run <cmd> runs a single command without an interactive shell. develop show builds without entering.
Build a flake output with nix build. Defaults to the default attribute. Result is linked as ./result.
Run a package without installing it. Bare names are resolved as nixpkgs#<pkg>.
inspection & care
status · service · cleanCheck on the health of your system, follow service logs, inspect the store, and reclaim disk space — without jumping between different tools.
Show the current generation and reachability of the target machine.
Run a health diagnostic. Checks the nix daemon, config syntax, and channels. Prints ok / warn / fail per check.
Manage systemd services. service logs <name> -f follows the journal live. stop and disable prompt for confirmation when confirm = true.
Inspect and maintain the Nix store. store info (default) shows total size, live paths, and reclaimable space. store gc runs garbage collection. store path <attr> evaluates a store path for a nixpkgs attribute.
Remove old generations and run garbage collection. Keeps the number of generations set by generations in your config (default: 5). --all removes all old generations regardless of that setting. ( ˘ω˘ )
generation history
history · go · gen · logYour system's whole story is saved in generations. Browse them, compare them, travel back to any of them. Nothing is gone until you clean it up.
List all system generations with their timestamps. The current generation is highlighted.
Switch to any specific generation by number using nix-env --switch-generation. Use this when nina back isn't far enough.
gen list is an alias for history. gen current prints the current generation number and nothing else. gen delete <n> removes a specific generation; gen delete old removes all non-current generations.
Show Nina's operation log from ~/.local/share/nina/nina.log. Displays the last 50 entries by default. Use --last N to show more or fewer.
Generations are your safety net. Apply freely, knowing you can always go back. nina history shows the whole story. nina go takes you there.
machine config
edit · info · channel · bootEdit your configuration safely, inspect the running system, manage channels, and set boot defaults — all without needing to remember the right file path or nixos-rebuild flag.
Open configuration.nix in your configured editor (default: vim). Pass hardware to open hardware-configuration.nix instead. After saving, run nina check to validate before applying.
Format configuration.nix with nixpkgs-fmt. --check reports whether formatting is needed without writing.
Show the NixOS version, kernel version, and uptime of the target machine.
Manage Nix channels. channel list is the default. channel update runs nix-channel --update.
List boot entries from the bootloader. Shows the current entry and all available generations.
Launch nix repl with nixpkgs loaded. Type :q to exit.
nina edit uses the editor value from ~/.nina.conf (default: vim). Set it to your editor of choice and Nina will use it everywhere.
remote machines
--on · hello · doctorThe same voice, even over SSH. Every Nina command accepts --on <machine> and behaves identically on a remote host. No separate tooling, no context switching.
Any Nina command runs on a configured remote machine. The machine name matches an entry in your Nina config file, or falls back to your SSH config.
Define remote machines in ~/.nina.conf:
nina hello list all configured machines and their kind (local / ssh) nina status --on <machine> show generation and uptime for a remote machine nina doctor --on <machine> run a full health diagnostic on any machine nina apply --on <machine> rebuild and switch a remote machine over SSH Nina keeps remote work from turning into a whole new personality. Same verbs, same little reassurances, same sense of where you are.
configuration
~/.nina.confNina's config file lives at ~/.nina.conf. The format is plain key=value, one per line. Comments start with #. All settings are optional — Nina works out of the box with no config file. (´ω`)
| option | type | default | description |
|---|---|---|---|
editor | string | vim | editor command Nina opens for nina edit |
generations | integer | 5 | how many generations to keep when running nina clean |
confirm | bool | true | prompt before destructive operations. empty input or non-'n' = yes |
teach | bool | false | print the underlying nix commands Nina runs (prefixed with =) |
color | bool | true | enable ANSI colors. also respects the NO_COLOR environment variable |
[machine] name | string | local | name used with --on <name> |
[machine] config | string | /etc/nixos | path to the directory containing configuration.nix |
[machine] local | bool | true | run commands locally. set automatically to false when host is given |
[machine] default | bool | false | use this machine when no --on flag is given |
[machine] host | string | — | SSH destination (user@host or just host) |
[machine] user | string | — | SSH user, if not included in host |
[machine] ssh_key | string | — | path to SSH private key. ~ expands to $HOME |
expressions ♡
kaomoji · moodsNina uses a few small kaomoji expressions instead of a mascot. They stay tucked into the UI, show a little feeling, and leave the work itself readable.
The rule is simple: calm most of the time, brighter when something lands, softer when something goes wrong.
Quiet and present. Nina is ready for input and not trying too hard to be noticed.
A little brighter, still tidy. Nina is doing something active and keeping the runway short.
A small burst of good news. Something finished cleanly and Nina lets herself be pleased for a second.
A softer expression for transitions, exits, and quieter actions where the UI should settle back down.
Not dramatic, just honest. Something needs attention, and Nina leaves the details where you can see them.
If you prefer a quieter experience, set color = false in your config. Nina will still show everything — just without the ANSI palette.
tips & recipes
patterns · workflowA few patterns that make daily NixOS life a little smoother. (*˘︶˘*)
A quiet morning with Nina:
Try a package without committing to it:
Push the same config change to multiple machines:
Something broke and you want to find when:
Nina works alongside home-manager. She manages NixOS system config; home-manager handles your user environment. They don't get in each other's way. (˶ᵔ ᵕ ᵔ˶) Run Nina for system changes, home-manager for dotfiles and user packages.
When something goes wrong, nina back is always there. When you're not sure what to try next, nina diff shows you the picture. And when things go right, Nina keeps the terminal feeling light.