The Nix store is a storage system in your filesystem with its root at /nix/store
by default.
The Nix daemon stores several things in the Nix store:
.drv
such as /nix/store/<hash>-my-package.drv
/nix/store/<hash>-my-package/
.patch
such as /nix/store/<hash>-my-package.patch
Paths in the Nix store have this structure:
/nix/store/ 1. Nix store prefixsglc12hc6pc68w5ppn2k56n6jcpaci16 2. Hash part-my-package-1.0 3. Package name
Let's break store paths down into their constituent elements:
/nix/store
by default.Some important things to note about store paths in Nix:
/nix/store
doesn't conflict with other standard system paths like /usr/bin
.my-package-1.0
, for example, you may end up with a store path like /nix/store/1aq3wchnvv7yn0d6y1r3j129hjqmv2k3-my-package-1.0
.my-package
and distinguish based on the input hash.