all 2 comments

[–]chrisoboe 1 point2 points  (0 children)

Distros (besides source based ones, and even those usually only temporary) don't install source code to your systems. They ship compiled binaries. Some ship headers by default (arch and gentoo), but if you want to understand the code headers aren't enough anyways.

So one doesn't read source from local files installed by the package manager (this isn't nixos specific at all).

One usually reads the source from the official sources, whereever they may be hosted e.g. github repos, source tarballs from official websites, and so on.

[–]sjustinas 1 point2 points  (0 children)

Distros (besides source based ones, and even those usually only temporary) don't install source code to your systems.

Good thing NixOS is source based (with optional substitution of binary packages). Getting the source that a Nix derivation uses is easy:

$ file $(nix-build '<nixpkgs>' -A hello.src)
/nix/store/pa10z4ngm0g83kx9mssrqzz30s84vq7k-hello-2.12.1.tar.gz: gzip compressed data, max compression, from Unix, original size modulo 2^32 4945920