Generation 99 2024-04-22 16:05:47 (current)
This commit is contained in:
@@ -3,6 +3,19 @@
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
home-rebuild =
|
||||
pkgs.writeShellScriptBin ".home-rebuild"
|
||||
''
|
||||
set -e
|
||||
pushd ~/.nixos/
|
||||
${pkgs.alejandra}/bin/alejandra . &>/dev/null
|
||||
${pkgs.git}/bin/git diff -U0
|
||||
echo "NixOS Rebuilding..."
|
||||
${pkgs.unstable.nh}/bin/nh home switch ~/.nixos
|
||||
gen=$(home-manager generations | head -n1 | ${pkgs.awk} '{print "Gen" $5 " @ " $1}')
|
||||
${pkgs.git}/bin/git commit --no-gpg-sign -am "Home $gen"
|
||||
popd
|
||||
'';
|
||||
rebuild =
|
||||
pkgs.writeShellScriptBin ".nixos-rebuild"
|
||||
''
|
||||
|
||||
Reference in New Issue
Block a user