Collected Nixperience
A living collection of Nix things I’d like to avoid relearning
I really like Nix. I use NixOS or nix-darwin every day. I started using NixOS for the same reason that I started using Arch: it makes a lot of things easier. This is not a hit piece! I am pro-flakes!
However, I have been saved by other blogs documenting a specific issue, so I would like to give back to the interwebsitesphere.
I am no Nix expert, but this will at least be useful for me![1]
Meta notes
- This is a living document that I will add to over time.
- I’m planning to just add stuff here when I run into it, but feel free to email any suggestions, corrections, and additions to
nixperience at domain-name
. - I will do my best to make sure that that all links continue to work because cool URIs don’t change.
- Under each heading is an “Or” section that lists less formal phrases that may lead here.[2]
- Once I have the exact words to describe my quandary, it’s usually easy to solve anyway. ↩︎
Resources
By design, this document is essentially all redundant information, so here are some Nix resources in no particular order:
- NixOS Wiki
- nixos.wiki (old?)
- NixOS Manual
- NixOS in Production
- Zero to Nix
- Nix package search
- NixOS options search
- Nix builtins search
Flakes copy without Git
Or: flake stuck copying, devshell copying, flake copies directory
Without a Git repository, Flakes will conservatively copy your tree to the store.
You can fix this by initializing a Git repository and adding your flake.nix
to it.
I ran into this when a change to the flake for my Lean fun directory caused direnv
to take a long time and rapidly use disk space.
A Reddit comment brought me to the actual problem, but this Discourse thread is a better source.