0

I know you can query for available packages with:

nix-env -qa search_term

from man

I'm curios, how is nix-env doing the search? Is it searching in my /nix/store or will perform some request on the binary cache server https://cache.nixos.org/ ?

It looks like it will work without network connection so I'm curios how does it know about the available packages?

1 Answer 1

2

You have a local copy of nixpkgs (you can use nix-channel to manage it), nix-env should read from pkgs/top-level/all-packages.nix.

However you can override that position using nix-env -I "<nixpkgs_path> ...

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.