Improve some configs

This commit is contained in:
Tobias Reisinger 2024-06-13 18:29:58 +02:00
parent 0ed1633be6
commit 0edf379835
Signed by: serguzim
GPG key ID: 13AD60C237A28DFE
8 changed files with 46 additions and 11 deletions

View file

@ -2,7 +2,8 @@
modes="std
single
single-sec"
single-sec
layout"
portalo_mode_std () {
echo "Loading portalo standard screen layout"
@ -22,6 +23,15 @@ portalo_mode_single_sec () {
yadm config --add local.class monitor-single-sec
}
portalo_mode_layout () {
layout_dir="$HOME/.config/hypr/layouts"
layouts=$(\ls -1 "$layout_dir")
layout=$(echo "$layouts" | $DMENU -p "layout")
if [ -n "$layout" ]; then
"$layout_dir/$layout"
fi
}
if [ -z "$1" ]; then
mode=$(echo "$modes" | $DMENU -p "mode")
else
@ -32,5 +42,6 @@ case $mode in
"std") portalo_mode_std ;;
"single") portalo_mode_single ;;
"single-sec") portalo_mode_single_sec ;;
"layout") portalo_mode_layout ;;
*) echo "'$mode' is not a valid mode (single, std)" ;;
esac