Skip to content

Commit f889a12

Browse files
committed
docs: add more depth to Flake input
At present, if a user copy-pastes the current documentation, a version of Nixpkgs will be added to their ``flake.lock`` lockfile. This is probably not what the user wants as Nixpkgs, the tarball, is quite large & the user likely expects the StevenBlack Flake to be used as a module to just be using the Nixpkgs of the system. This change should also help new Nix users know how to pin a Nix version if there ever comes a time where the Nix :ac:`API` changes—even if ``lib`` tries to be stable & backwards-compatible. Additionally, provide a comment about where & what the input can be—such as a mirror or a local fork for development. Format: text/x-rst
1 parent 8ca227e commit f889a12

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

readme.md

+8-1
Original file line numberDiff line numberDiff line change
@@ -433,7 +433,14 @@ like this:
433433

434434
```nix
435435
{
436-
inputs.hosts.url = "github:StevenBlack/hosts";
436+
inputs = {
437+
nixpkgs.url = "github:NixOS/nixpkgs?ref=$YOUR-REF";
438+
hosts = {
439+
url = "github:StevenBlack/hosts"; # or a fork/mirror
440+
inputs.nixpkgs.follows = "nixpkgs";
441+
};
442+
};
443+
437444
outputs = { self, nixpkgs, hosts }: {
438445
nixosConfigurations.my-hostname = {
439446
system = "<architecture>";

0 commit comments

Comments
 (0)