diff --git a/config/xinitrc_example b/config/xinitrc_example index 6240aa9..017bed2 100644 --- a/config/xinitrc_example +++ b/config/xinitrc_example @@ -1,4 +1,4 @@ -wms_value.sh & +cp $HOME/.config/wms/mws_var /tmp/wms_var & xrdb -merge .Xresources & diff --git a/wms_backgroundize.sh b/wms_backgroundize.sh index 2f1bd21..6c45ead 100755 --- a/wms_backgroundize.sh +++ b/wms_backgroundize.sh @@ -3,7 +3,7 @@ ## send windows to desktop background ## ## it depends of wms_mainrole.sh ## -. $HOME/.config/wms/wms_var +. /tmp/wms_var FLAG=$1 FW=$(pfw) # focused window diff --git a/wms_batlarm.sh b/wms_batlarm.sh index 3aa3f0e..9b34ec8 100755 --- a/wms_batlarm.sh +++ b/wms_batlarm.sh @@ -3,7 +3,7 @@ ## alternating window border colors depending on battery charge ## ## this script depends on power.sh which is in the /others repo ## -. $HOME/.config/wms/wms_var +. /tmp/wms_var FREQ=0.5 # freq COLORS="aa0000 $AC" # alternate colors diff --git a/wms_clearer.sh b/wms_clearer.sh index 02bc7ca..dab7a90 100755 --- a/wms_clearer.sh +++ b/wms_clearer.sh @@ -2,7 +2,7 @@ ## clean screen ## -. $HOME/.config/wms/wms_var +. /tmp/wms_var FLAG=$1 FW=$(pfw) # focused window diff --git a/wms_mainrole.sh b/wms_mainrole.sh index fc6330b..cffeaaf 100755 --- a/wms_mainrole.sh +++ b/wms_mainrole.sh @@ -2,7 +2,7 @@ ## give windows the stardom ## -. $HOME/.config/wms/wms_var +. /tmp/wms_var FLAG=$1 FW=$(pfw) diff --git a/wms_moveresize.sh b/wms_moveresize.sh index e8b62ce..ba8427b 100755 --- a/wms_moveresize.sh +++ b/wms_moveresize.sh @@ -2,7 +2,7 @@ ## move and resize windows ## -. $HOME/.config/wms/wms_var +. /tmp/wms_var FLAG=$1 # flag FW=$(pfw) # focused window id diff --git a/wms_screensaver.sh b/wms_screensaver.sh index 909ec93..142a73b 100755 --- a/wms_screensaver.sh +++ b/wms_screensaver.sh @@ -2,7 +2,7 @@ ## use the windows on the desktop as screensavers by moving them randomly -. $HOME/.config/wms/wms_var +. /tmp/wms_var INPUT=$1 # input FW=$(pfw) # focused window diff --git a/wms_session.sh b/wms_session.sh index c9e4d49..becfde8 100755 --- a/wms_session.sh +++ b/wms_session.sh @@ -2,16 +2,16 @@ ## manage session and some more things ## -. $HOME/.config/wms/wms_var +. /tmp/wms_var KBRELOAD="pkill -usr1 -x sxhkd" # keybindings reload LOCK="slock" # lock screen monitor MOFF="xset dpms force off" # poweroff monitor -HB="doas pm-hibernate" # hibernate +HB="doas zzz -Z" # hibernate RB="doas shutdown -r now" # reboot POFF="doas shutdown -h now" # poweroff EXIT="pkill wew && pkill sxhkd" # exit session -PROMPT="reload-key\nlock\nmonitor-off\nhalt\nreboot\nsuspend\nlogout" +PROMPT="reload-key\nlock\nmonitor-off\nhalt\nreboot\nhibernate\nexit" option=`echo $PROMPT | $XMENU` if [ ${#option} -gt 0 ]; then @@ -25,7 +25,7 @@ if [ ${#option} -gt 0 ]; then monitor-off) $MOFF ;; - suspend) + hibernate) $HB ;; halt) @@ -34,7 +34,7 @@ if [ ${#option} -gt 0 ]; then reboot) $RB ;; - logout) + exit) $EXIT ;; *) diff --git a/wms_shepperd.sh b/wms_shepperd.sh index 5edba41..f927161 100755 --- a/wms_shepperd.sh +++ b/wms_shepperd.sh @@ -2,7 +2,7 @@ ## sort windows by herds/flock ## -. $HOME/.config/wms/wms_var +. /tmp/wms_var FLAG=$1 # input FW=$(pfw) # focused window id diff --git a/wms_switcher.sh b/wms_switcher.sh index 6f4ff25..8fdc3c7 100755 --- a/wms_switcher.sh +++ b/wms_switcher.sh @@ -2,7 +2,7 @@ ## switch between windows ## -. $HOME/.config/wms/wms_var +. /tmp/wms_var TARGET=$(\ for wid in $(lsw); do # print id, class and name in xmenu diff --git a/wms_termrename.sh b/wms_termrename.sh index 76dd497..e6c32ab 100755 --- a/wms_termrename.sh +++ b/wms_termrename.sh @@ -2,7 +2,7 @@ ## rename terminals ## -. $HOME/.config/wms/wms_var +. /tmp/wms_var TARGET=$(pfw) # focused window NAMES="$HOME/.config/wms/wms_names" diff --git a/wms_termtogle.sh b/wms_termtogle.sh index 430499a..63ab534 100755 --- a/wms_termtogle.sh +++ b/wms_termtogle.sh @@ -2,7 +2,7 @@ ## toggle between terminals ## -. $HOME/.config/wms/wms_var +. /tmp/wms_var TNAME=$(echo $TERMINAL | cut -d ' ' -f 1) # terminal name diff --git a/wms_usher.sh b/wms_usher.sh index 7e3bada..8efd97d 100755 --- a/wms_usher.sh +++ b/wms_usher.sh @@ -2,7 +2,7 @@ ## some layouts to order the windows ## -. $HOME/.config/wms/wms_var +. /tmp/wms_var FLAG=$1 # input RID=$(lsw -r) # root window id diff --git a/wms_value.sh b/wms_value.sh index 5049607..634cad4 100755 --- a/wms_value.sh +++ b/wms_value.sh @@ -1,9 +1,10 @@ #!/bin/sh -. $HOME/.config/wms/wms_var +. /tmp/wms_var FLAG=$1 RID=$(lsw -r) # root window id +WMSVAR="/tmp/wms_var" usage() { cat<