Introduction - nixos-cli

nixos-cli is a robust, cohesive, drop-in replacement for NixOS tooling such as nixos-rebuild, among many other tools.

Why?

NixOS tooling today is fragmented across large, aging shell and Perl scripts that are difficult to maintain or extend. Prolific examples include:

These tools contain deep functionality, but much of it is hidden, hard to modify, or locked behind poor ergonomics.

nixos-cli aims to modernize this experience by:

  • Replacing and improving existing tooling
  • Providing a consistent interface across all commands
  • Making functionality more accessible and extensible
  • Offering a clean, discoverable CLI experience for both users and developers

In summary, this tool has one goal: to create a modular NixOS CLI that mirrors or enhances the functionality of all current NixOS tooling in nixpkgs, adds on to it if needed, and eventually come to replace it entirely.

Yes, this is already being done somewhat by switch-to-configuration-ng and nixos-rebuild-ng. However, nixos-cli strives to achieve further goals, including (but not limited to the following)

  • Enhanced usability (and looking nice! Who doesn't love eye candy?)
  • Deeper integration with NixOS internals
  • Creating a self-contained NixOS manager binary that includes routine scripts such as switch-to-configuration activation functionality
  • Plugins for further NixOS tooling to be developed out-of-tree

Key Features

  • Drop-in replacements for common NixOS tools (with better names!)
  • An integrated NixOS option search UI
  • An improved generation manager, with an additional UI (more fine-tuned than nix-collect-garbage -d)

Check out the overview page for more information about key features.

More features are planned; see the roadmap for more information.

Status

This tool is under active development, but is not yet stable.
Until a 1.0 release, the CLI interface and configuration may change without notice.

Watch the Releases page for:

  • Breaking changes
  • Feature updates
  • Bug fixes

Core contributors:

Contributions, testing, and bug reports/general feedback are highly encouraged, since there are few people working on this project actively.

Talk!

Join the Matrix room at #nixos-cli:matrix.org! It's open for chatting about NixOS in general, and for making it a better experience for all that involved.