Jump to content

User talk:GraysonTinker

From Official NixOS Wiki

Flake File Structure text

In: Flakes

The text following the flake file structure when nix flake init is made incorrect by your recent change from GitHub to channel tarballs. I believe it should instead read

the input specified as a URL to a tarball, and an output that makes use of the input

Or similar, but I am not certain of the exact phraseology so wanted to raise to you :)

Thank you for your contributions. CallumGilly (talk) 14:23, 14 October 2026 (UTC)Reply

Thank you for pointing that out! I have applied that change as you suggested. Feel free to make such changes yourself in the future :) GraysonTinker (talk) 07:46, 25 October 2026 (UTC)Reply

Changes like "Move GitHub flakerefs to the superior channel tarballs" and such

Could you explain the changes somewhere? Maybe put a comment in the flake.nix examples that you have modified?

Where are those URLs documented? Axka (talk) 08:50, 25 October 2026 (UTC)Reply

Seems that the URLs are referenced here: https://nixos.org/manual/nixos/unstable/release-notes?utm_source=chatgpt.com#sec-release-26.11-highlights and here: https://releases.nixos.org/nixos/unstable/nixos-26.11pre1100280.3ec636362e18 Axka (talk) 08:55, 25 October 2026 (UTC)Reply
These channel tarballs are what the normal nix-channel commands use, but they're also able to be used for (and indeed are better than direct GitHub for) flake inputs. The improvements are various and range from moderate to small, but there's no sense in encouraging a bad pattern. Instead of listing them all out again, here's a link to my previous Discourse post on the subject: https://discourse.nixos.org/t/psa-use-nixos-org-tarballs-for-your-flake-inputs/79950. Really, using Github is a bad pattern that was necessary at the start but now is just being cargo-culted.

I don't believe they're specifically documented anywhere, (this is part of an effort to change that!), but FWIW, Nix's own flake uses them: https://github.com/NixOS/nix/blob/master/flake.nix. Also, they are now the default Nixpkgs input when you run nix flake init.

I'm not sure that it makes sense to put a comment in each individual instance. After all, that wasn't the expectation of the previous version, and this pattern should hopefully become more common over time. But I'm also not especially opposed to doing so if you're adamant about it.
GraysonTinker (talk) 09:00, 25 October 2026 (UTC)Reply