auto-install script

This commit is contained in:
shynd 2025-02-20 00:06:55 +01:00
parent c70b8e905f
commit 15c1c33c7d
1 changed files with 13 additions and 1 deletions

View File

@ -131,3 +131,15 @@ else
fi
echo "-----"
read -rp "$CAT enter your keyboard layout: [ us ] " keyboardLayout
if [ -z "$keyboardLayout" ]; then
keyboardLayout="us"
fi
sed -i 's/keyboardLayout\s*=\s*"\([^"]*\)"/keyboardLayout = "'"$keyboardLayout"'"/' ./hosts/$hostName/variables.nix
echo "-----"
installusername=$(echo $USER)
sed -i 's/username\s*=\s*"\([^"]*\)"/username = "'"$installusername"'"/' ./flake.nix