An interactive NixOS package installer inspired by Arch Linux's yay. Nay helps you search, preview, install, and remove NixOS packages with ease, automatically managing them in your configuration.nix.
- Interactive package search and selection
- Exact match detection
- Try packages in a temporary shell before installing
- Interactive package removal using fuzzy search
- Automatic configuration file updates
- System rebuild automation
- Configurable configuration file path
Add nay to your NixOS configuration using Flakes:
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
nay.url = "github:christhepanda28/nay";
};
outputs = { self, nixpkgs, nay, ... }: {
nixosConfigurations.your-hostname = nixpkgs.lib.nixosSystem {
# ...
modules = [
# ...
nay.nixosModules.default
{
programs.nay = {
enable = true;
# Optional: specify a custom configuration file path
# configPath = "/path/to/your/configuration.nix";
};
}
];
};
};
}Nay can be configured through NixOS module options:
programs.nay.enable: Enable/disable nay (boolean)programs.nay.configPath: Path to your NixOS configuration file containingenvironment.systemPackages(default: "/etc/nixos/configuration.nix")
Search and install packages:
nay install package-name
# or simply
nay package-nameOr start an interactive search:
nay install
# or simply
nayWhen a package is found, you can:
- Install it permanently (adds to your configuration file and rebuilds)
- Try it in a temporary shell
To remove a package:
nay removeThis will:
- Show an interactive fuzzy-search list of installed packages
- Let you select a package to remove
- Remove it from your configuration and rebuild the system
MIT