Nix Dependencies
Check out a package in a Nix Shell:
nix-shell -p subversion graphviz
Runtime dependencies
Print its runtime dependencies (closure):
nix-store --query --requisites $(which svn)
Build dependencies
Print the build-time dependencies of svn
:
derivation = $(nix-store --query --valid-derivers $(which svn))
nix-store --query --requisites $derivation
Dependency graph
Plot a graph with Graphviz:
nix-store --query --graph $(which svn) | dot -Tpdf > graph.pdf
Learn more
https://nixos.org/manual/nix/stable/command-ref/nix-store/query#examples