New custom settings in settings script

This commit is contained in:
Stephan Raabe 2023-12-10 19:17:04 +01:00
parent affb4e9b74
commit 2b799906a3
2 changed files with 43 additions and 4 deletions

View File

@ -0,0 +1,9 @@
# Add your additional Hyprland configurations here
#
# This is an additional key binding
# bind = $mainMod CTRL, up, workspace, empty
#
# Example for xwayland
# xwayland {
# force_zero_scaling = true
# }

View File

@ -1,4 +1,33 @@
#!/bin/bash
_settingsCustom() {
clear
cat <<"EOF"
____ _
/ ___| _ ___| |_ ___ _ __ ___
| | | | | / __| __/ _ \| '_ ` _ \
| |__| |_| \__ \ || (_) | | | | | |
\____\__,_|___/\__\___/|_| |_| |_|
EOF
echo "Press ESC to proceed."
echo ""
filevalue=$(gum write --show-line-numbers --height 15 --width 70 --value="$(cat ~/dotfiles/hypr/conf/custom.conf)")
clear
cat <<"EOF"
____ _
/ ___| _ ___| |_ ___ _ __ ___
| | | | | / __| __/ _ \| '_ ` _ \
| |__| |_| \__ \ || (_) | | | | | |
\____\__,_|___/\__\___/|_| |_| |_|
EOF
if gum confirm "Do you want to save your changes into ~/dotfiles/hypr/conf/custom.conf?" ;then
echo "$filevalue" > ~/dotfiles/hypr/conf/custom.conf
fi
_settingsMenu
}
_settingsDecoration() {
clear
cat <<"EOF"
@ -177,7 +206,7 @@ EOF
echo "Version: $(cat ~/dotfiles/version)"
echo ""
fi
menu=$(gum choose "Decorations" "Windows" "Animations" "Monitors" "Environments" "Keybindings" "Windowrules" "EXIT")
menu=$(gum choose "Decorations" "Windows" "Animations" "Monitors" "Environments" "Keybindings" "Windowrules" "Custom" "EXIT")
case $menu in
Decorations)
_settingsDecoration
@ -200,12 +229,13 @@ EOF
Windowrules)
_settingsWindowrule
break;;
Custom)
_settingsCustom
break;;
* )
exit
;;
esac
}
_settingsMenu
_settingsMenu