devenv gives you access to over 100,000 packages from Nixpkgs — the world’s largest software repository. Packages are declared once inDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/cachix/devenv/llms.txt
Use this file to discover all available pages before exploring further.
devenv.nix and automatically added to every developer’s PATH when they enter the shell. No installation scripts, no version drift, no “works on my machine.”
Declaring Packages
Add packages using thepackages option, referencing them from the pkgs argument:
devenv.nix
PATH — and libraries to the relevant search paths — as soon as you enter the shell:
Searching for Packages
Usedevenv search <NAME> to find available packages. Results are scoped to the exact version of Nixpkgs pinned in your devenv.lock:
Searching for a File
If you know a file name — for example a shared library likelibquadmath.so — but not which package provides it, you can use the nix-index-database:
Using Packages in Scripts and enterShell
Packages declared inpackages are available everywhere inside the environment — including enterShell hooks and scripts. You can reference them either by name (since they are on PATH) or by their Nix store path for precise pinning:
Pinning a Specific Package Version
By default, all packages come from the Nixpkgs revision pinned in yourdevenv.lock. If you need a newer or older version of a specific package, you can fetch it from a separate Nixpkgs input.
Run
devenv update after changing inputs in devenv.yaml to refresh the lock file.