unpacking 'github:NixOS/nixpkgs/c68937a0a0008af9117305874bd3da814fac1f19' into the Git cache... • Updated input 'darwin': 'github:lnl7/nix-darwin/c172f50b55b087f8e7801631de977461603bb976?narHash=sha256-ng0a4cIq3c9E3iGKomlwqKzVYs2RLOzQho2U1Mc2sqU%3D' (2025-03-04) → 'github:lnl7/nix-darwin/fc843893cecc1838a59713ee3e50e9e7edc6207c?narHash=sha256-%2BsMGqywrSr50BGMLMeY789mSrzjkoxZiu61eWjYS/8o%3D' (2025-03-28) • Updated input 'nixpkgs': 'github:NixOS/nixpkgs/d02d88f8de5b882ccdde0465d8fa2db3aa1169f7?narHash=sha256-lWc%2B79eZRyvHp/SqMhHTMzZVhpxkRvthsP1Qx6UCq0E%3D' (2025-03-25) → 'github:NixOS/nixpkgs/c570c1f5304493cafe133b8d843c7c1c4a10d3a6?narHash=sha256-tpJsHMUPEhEnzySoQxx7%2BkA%2BKUtgWqvlcUBqROYNNt0%3D' (2025-03-29) • Updated input 'nixpkgs-master': 'github:NixOS/nixpkgs/e91a742511de59a3bc6c50bc5a68ea6b8ea3773f?narHash=sha256-IR9lx7WZXcP8Ww6Zf8tj33K/oa79M9FQ4m/YggMre6M%3D' (2025-03-28) → 'github:NixOS/nixpkgs/c68937a0a0008af9117305874bd3da814fac1f19?narHash=sha256-8PahEFvafZ7SAQcAmncDyslOcSlSIkyANk9b/XXQ60k%3D' (2025-03-30) • Updated input 'nixpkgs-unstable': 'github:NixOS/nixpkgs/bd3bac8bfb542dbde7ffffb6987a1a1f9d41699f?narHash=sha256-jAIUqsiN2r3hCuHji80U7NNEafpIMBXiwKlSrjWMlpg%3D' (2025-03-26) → 'github:NixOS/nixpkgs/eb0e0f21f15c559d2ac7633dc81d079d1caf5f5f?narHash=sha256-ArWLUgRm1tKHiqlhnymyVqi5kLNCK5ghvm06mfCl4QY%3D' (2025-03-29) • Updated input 'nixvim': 'github:nix-community/nixvim/3363fe9cc6574282a8e22e447c319e761c8019e7?narHash=sha256-ySz2mfQTFJmdwHCVbMgQRzrcIHgamKwdiwcV%2BPzDXZI%3D' (2025-03-27) → 'github:nix-community/nixvim/ec72386f491c290bc77dc5fd3a6d7baf79b24680?narHash=sha256-VL/W7pfBtaKLOb6%2Baz8Ra%2B0n2nY6C2hXF4XPbcKDgrc%3D' (2025-03-29) • Updated input 'nixvim/nix-darwin': 'github:lnl7/nix-darwin/c172f50b55b087f8e7801631de977461603bb976?narHash=sha256-ng0a4cIq3c9E3iGKomlwqKzVYs2RLOzQho2U1Mc2sqU%3D' (2025-03-04) → 'github:lnl7/nix-darwin/fc843893cecc1838a59713ee3e50e9e7edc6207c?narHash=sha256-%2BsMGqywrSr50BGMLMeY789mSrzjkoxZiu61eWjYS/8o%3D' (2025-03-28) • Updated input 'nixvim/nuschtosSearch': 'github:NuschtOS/search/508752835128a3977985a4d5225ff241f7756181?narHash=sha256-i/JCrr/jApVorI9GkSV5to%2BUSrRCa0rWuQDH8JSlK2A%3D' (2025-03-22) → 'github:NuschtOS/search/2651dbfad93d6ef66c440cbbf23238938b187bde?narHash=sha256-bb/dqoIjtIWtJRzASOe8g4m8W2jUIWtuoGPXdNjM/Tk%3D' (2025-03-28) • Updated input 'nixvim/treefmt-nix': 'github:numtide/treefmt-nix/61c88349bf6dff49fa52d7dfc39b21026c2a8881?narHash=sha256-aRA6LSxjlbMI6MmMzi/M5WH/ynd8pK%2BvACD9za3MKLQ%3D' (2025-03-26) → 'github:numtide/treefmt-nix/29a3d7b768c70addce17af0869f6e2bd8f5be4b7?narHash=sha256-WRAylyYptt6OX5eCEBWyTwOEqEtD6zt33rlUkr6u3cE%3D' (2025-03-27)
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.