aboutsummaryrefslogtreecommitdiff
path: root/nix
diff options
context:
space:
mode:
authorFranck Cuny <franck@fcuny.net>2024-12-17 09:25:13 -0800
committerFranck Cuny <franck@fcuny.net>2024-12-18 09:05:35 -0800
commit97124a3f122087910d8e1751f560ece16527ce86 (patch)
tree29083154ea0eb1f3c80a1bc67f4c6bc0775bcd97 /nix
parentfish defaults are fine (diff)
downloadinfra-97124a3f122087910d8e1751f560ece16527ce86.tar.gz
add support for overlays and add one for `sapi'
Diffstat (limited to 'nix')
-rw-r--r--nix/lib/overlays.nix6
-rw-r--r--nix/users/fcuny/darwin.nix2
2 files changed, 8 insertions, 0 deletions
diff --git a/nix/lib/overlays.nix b/nix/lib/overlays.nix
new file mode 100644
index 0000000..1ec6f49
--- /dev/null
+++ b/nix/lib/overlays.nix
@@ -0,0 +1,6 @@
+let path = ../../overlays;
+in with builtins;
+map (n: import (path + ("/" + n))) (filter
+ (n:
+ match ".*\\.nix" n != null || pathExists (path + ("/" + n + "/default.nix")))
+ (attrNames (readDir path)))
diff --git a/nix/users/fcuny/darwin.nix b/nix/users/fcuny/darwin.nix
index b56a67d..b882bc5 100644
--- a/nix/users/fcuny/darwin.nix
+++ b/nix/users/fcuny/darwin.nix
@@ -1,4 +1,6 @@
{ pkgs, ... }: {
+ nixpkgs.overlays = import ../../../nix/lib/overlays.nix;
+
# The user should already exist, but we need to set this up so Nix knows
# what our home directory is (https://github.com/LnL7/nix-darwin/issues/423).
users.users.fcuny = {