The manpage for `nix build` & `nix shell` goes to `nix-build` & `nix-shell` the stable, non-experimental command which do not need a file as an arg since they are more developer-friendly. The `nix-command` experimental stuff is documented somewhere else—maybe
https://nix.dev/manual/nix/2.35/command-ref/new-cli/nix.html... is good enough for the concept. `man nixos-rebuild`, `man nix profile` have `--file, -F` documented.