about summary refs log tree commit diff
path: root/users/grfn/system/home/modules
diff options
context:
space:
mode:
authorGriffin Smith <grfn@gws.fyi>2021-04-12T15·07-0400
committergrfn <grfn@gws.fyi>2021-04-12T15·17+0000
commitd339cc687d9db9066da9fa2e4f5532f96b512dd1 (patch)
treecdd32eeec39f12e1cc4c974284b9fe8ee6c8cf73 /users/grfn/system/home/modules
parente358087611f6e2b9c86625fcb9a7a3c2636e07fe (diff)
feat(grfn/home): Script to rebuild home-manager r/2487
Looks kinda like rebuild-mugwump, only for home

yes, yes, this could gc halfway through, that's so unlikely that I don't
care

Change-Id: Iab3fdac15796e9f8158a9778b897bc3fe88e536e
Reviewed-on: https://cl.tvl.fyi/c/depot/+/2942
Reviewed-by: grfn <grfn@gws.fyi>
Tested-by: BuildkiteCI
Diffstat (limited to 'users/grfn/system/home/modules')
-rw-r--r--users/grfn/system/home/modules/common.nix6
1 files changed, 6 insertions, 0 deletions
diff --git a/users/grfn/system/home/modules/common.nix b/users/grfn/system/home/modules/common.nix
index 02935aaa50f5..882488763d32 100644
--- a/users/grfn/system/home/modules/common.nix
+++ b/users/grfn/system/home/modules/common.nix
@@ -54,6 +54,12 @@
       ssh mugwump sudo nix-env -p /nix/var/nix/profiles/system --set $system
       ssh mugwump sudo $system/bin/switch-to-configuration switch
     '')
+    (writeShellScriptBin "rebuild-home" ''
+      set -eo pipefail
+      cd ~/code/depot
+      nix build -f . users.grfn.system.home.$(hostname)Home -o /tmp/home
+      /tmp/home/activate
+    '')
   ];
 
   programs.ssh = {