This might work

This commit is contained in:
Lillian Violet 2024-03-01 16:34:55 +01:00
parent f8cf7b589b
commit b5ff78aae9

View file

@ -11,7 +11,7 @@ writeShellApplication
text = ''
# A rebuild script for NixOS
rebuild_function (){
rebuild_function () {
set -e
pushd /tmp > /dev/null
rm -rf ./rebuild
@ -25,6 +25,7 @@ writeShellApplication
popd > /dev/null
echo "NixOS Rebuilt OK!"
}
sudo bash -c "$(declare -f rebuild_function); rebuild_function"
sudo systemd-inhibit --who="NixOS Updater" --why="Updating system configuration" sudo -u lillian rebuild_function
'';
}