Skip sound start program launching flag

This commit is contained in:
Christian Colglazier 2019-12-30 12:24:17 -05:00
parent 827b6c406b
commit 9b3ab03ea3

View File

@ -16,6 +16,15 @@ function pulseHack() {
done
}
# arg parser
for arg in "$@"
do
# Skip commands for i3wm
if [[ $arg == *"-s"* ]]; then
skipi3=true
fi
done
# Close any active audio
killPulse
@ -29,5 +38,8 @@ pulseHack
sh ~/.config/scripts/start-es-8.sh
# Start up programs that use audio
sleep .1 && i3-msg 'workspace 10; exec google-play-music-desktop-player'
sleep .1 && i3-msg 'workspace 5; exec firefox'
if [ -z "$skipi3" ]; then
echo Opening i3wm sound workspaces
sleep .1 && i3-msg 'workspace 10; exec google-play-music-desktop-player'
sleep .1 && i3-msg 'workspace 5; exec firefox'
fi