mirror of
https://github.com/Dejvino/pinephone-sway-poc.git
synced 2024-12-23 10:48:49 +00:00
23 lines
513 B
Bash
Executable File
23 lines
513 B
Bash
Executable File
#!/bin/bash
|
|
|
|
MENUOPTIONS=~/.menuoptions
|
|
MENUSELECT=~/.menuselect
|
|
|
|
HEIGHT=0
|
|
WIDTH=0
|
|
LINES=0
|
|
|
|
if [ ! -f $MENUOPTIONS ]
|
|
then
|
|
echo 'termite Terminal' > $MENUOPTIONS
|
|
echo 'audacious "Music Player"' >> $MENUOPTIONS
|
|
echo 'firefox "Web Browser"' >> $MENUOPTIONS
|
|
echo '"sudo reboot" Restart' >> $MENUOPTIONS
|
|
echo '"sudo poweroff" Shutdown' >> $MENUOPTIONS
|
|
fi
|
|
|
|
usleep 250000 # term stabilization
|
|
|
|
cat $MENUOPTIONS | xargs dialog --menu EXECUTE $HEIGHT $WIDTH $LINES 2>$MENUSELECT && swaymsg exec "`cat $MENUSELECT`"
|
|
|