This documents the fact that nix-build, nix-env, nix-instantiate, and nix-shell accept an extended syntax for their file arguments, including some well-known (but not well documented) aspects, like being able to specify `<nixpkgs>`, but also https:// tarball URLs, `flake:` prefixed flakerefs, and the cursed `channel:` prefixed hardcoded URLs Same thing for the new CLI incoming :) Change-Id: Ib6d68594a16132805ba5d97526e16f7b3633117e
951 B
951 B
- A normal filesystem path, like
/home/meow/nixfiles/default.nix- Or a directory, like
/home/meow/nixfiles, equivalent to above
- Or a directory, like
- A single lookup path, like
<nixpkgs>or<nixos> - A URL to a tarball, like
https://github.com/NixOS/nixpkgs/archive/refs/heads/release-23.11.tar.gz - A flakeref, introduced by the prefix
flake:, likeflake:git+https://git.lix.systems/lix-project/lix - A nixpkgs channel tarball name, introduced by the prefix
channel:, likechannel:nixos-unstable.- This uses a hard-coded URL pattern and is not related to the subscribed channels managed by the nix-channel command.