feat: do sudo before nh and exit on fail
This commit is contained in:
parent
7f627ec2d3
commit
526498ce2a
1 changed files with 1 additions and 0 deletions
|
|
@ -110,6 +110,7 @@
|
||||||
let
|
let
|
||||||
pkgs = nixpkgs.legacyPackages.x86_64-linux;
|
pkgs = nixpkgs.legacyPackages.x86_64-linux;
|
||||||
nhs = pkgs.writeShellScriptBin "nhs" ''
|
nhs = pkgs.writeShellScriptBin "nhs" ''
|
||||||
|
sudo -v || exit $?
|
||||||
nh os switch --hostname framework path:. "$@"
|
nh os switch --hostname framework path:. "$@"
|
||||||
'';
|
'';
|
||||||
in
|
in
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue