about summary refs log tree commit diff
path: root/users
diff options
context:
space:
mode:
Diffstat (limited to 'users')
-rw-r--r--users/wpcarro/Makefile20
-rw-r--r--users/wpcarro/configs/default.nix11
2 files changed, 25 insertions, 6 deletions
diff --git a/users/wpcarro/Makefile b/users/wpcarro/Makefile
index 52f46d0ea68b..4e3361b80086 100644
--- a/users/wpcarro/Makefile
+++ b/users/wpcarro/Makefile
@@ -1,9 +1,17 @@
-install:
-	source "${WPCARRO}/configs/install"
+install-cli-tools:
+	nix-env -f "${BRIEFCASE}" -iA shared.cliTools
 
-uninstall:
-	source "${WPCARRO}/configs/uninstall"
+install-configs:
+	nix-build -A configs.install && \
+	./result && \
+	rm ./result
+
+uninstall-configs:
+	nix-build -A configs.uninstall && \
+	./result && \
+	rm ./result
 
 list-broken-links:
-	find "${HOME}" -maxdepth 1 -xtype l && \
-	find "${HOME}/.config" -maxdepth 1 -xtype l
+	nix-build -A tools.symlinkManager && \
+	./result/bin/symlink-mgr -audit && \
+	rm ./result
diff --git a/users/wpcarro/configs/default.nix b/users/wpcarro/configs/default.nix
new file mode 100644
index 000000000000..5b0b6a7dcc31
--- /dev/null
+++ b/users/wpcarro/configs/default.nix
@@ -0,0 +1,11 @@
+{ pkgs, ... }:
+
+{
+  install = pkgs.writeShellScript "install-configs" ''
+    cd "$WPCARRO/configs" && ${pkgs.stow}/bin/stow --target="$HOME" .
+  '';
+
+  uninstall = pkgs.writeShellScript "uninstall-configs" ''
+    cd "$WPCARRO/configs" && ${pkgs.stow}/bin/stow --delete --target="$HOME" .
+  '';
+}