Dev
This commit is contained in:
35
.install/setup.sh
Normal file
35
.install/setup.sh
Normal file
@@ -0,0 +1,35 @@
|
||||
# ------------------------------------------------------
|
||||
# Setup
|
||||
# ------------------------------------------------------
|
||||
|
||||
cat <<"EOF"
|
||||
____ _
|
||||
/ ___| ___| |_ _ _ _ __
|
||||
\___ \ / _ \ __| | | | '_ \
|
||||
___) | __/ |_| |_| | |_) |
|
||||
|____/ \___|\__|\__,_| .__/
|
||||
|_|
|
||||
|
||||
EOF
|
||||
echo "If you could restore your keyboard layout in the step before you can select Nn and skip."
|
||||
while true; do
|
||||
read -p "Do you want to start the setup (Yy/Nn): " yn
|
||||
case $yn in
|
||||
[Yy]* )
|
||||
read -p "Enter your preferred keyboard layout (us,de,...) (default:us): " keyboard
|
||||
if [ -z "$keyboard" ]; then
|
||||
keyboard="us"
|
||||
fi
|
||||
SEARCH="kb_layout = de"
|
||||
REPLACE="kb_layout = $keyboard"
|
||||
sed -i "s/$SEARCH/$REPLACE/g" ~/dotfiles-versions/$version/hypr/conf/keyboard.conf
|
||||
|
||||
SEARCH="keyboard_layout = \"de\""
|
||||
REPLACE="keyboard_layout = \"$keyboard\""
|
||||
sed -i "s/$SEARCH/$REPLACE/g" ~/dotfiles-versions/$version/qtile/conf/keyboard.py
|
||||
break;;
|
||||
[Nn]* )
|
||||
break;;
|
||||
* ) echo "Please answer yes or no.";;
|
||||
esac
|
||||
done
|
||||
Reference in New Issue
Block a user