• Updated input 'nixvim': 'github:nix-community/nixvim/3568de82e7e755883c80ae69fef590aaa44b65b3' (2024-06-09) → 'github:nix-community/nixvim/e604202f452c03e739b9bba6125bb830fae29350' (2024-06-11) • Updated input 'nixvim/home-manager': 'github:nix-community/home-manager/a7117efb3725e6197dd95424136f79147aa35e5b' (2024-06-04) → 'github:nix-community/home-manager/3d65009effd77cb0d6e7520b68b039836a7606cf' (2024-06-09) • Updated input 'nixvim/nix-darwin': 'github:lnl7/nix-darwin/c0d5b8c54d6828516c97f6be9f2d00c63a363df4' (2024-05-29) → 'github:lnl7/nix-darwin/315aa649ba307704db0b16c92f097a08a65ec955' (2024-06-09) • Updated input 'stylix': 'github:danth/stylix/7682713f6af1d32a33f8c4e3d3d141af5ad1761a' (2024-06-10) → 'github:danth/stylix/f060e4059b408b2cc1891ce655d0f6bef4e21a5b' (2024-06-11)
nix-config
This repo stores nix to manage my machines running NixOS and macOS.
The configuration is very specific to my own machines and setup, but it may be a useful reference for anyone else learning or experimenting with nix, whether it be on a personal workstation or a server environment.
Setup
on macOS: install the latest unstable nix from https://github.com/numtide/nix-unstable-installer (for nix flakes), and nix-darwin: https://github.com/LnL7/nix-darwin
Recipes are stored in a justfile. just is required.
To run a rebuild:
just rebuild
Update
To update nixpkgs defined in flake.nix, run:
just update
If there are updates, they should be reflected in flake.lock.
Rollback
To rollback to the previous generation:
just rollback
Garbage collection
To cleanup previous files, run nix garbage collection:
just clean
Pre-commit hooks
Pre-commit hooks are automatically activated when direnv is installed.