Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
executable file 39 lines (34 sloc) 939 Bytes
#!/usr/bin/env sh
# handy: ln -s ~/work/siggu.org/chat-mode.sh /usr/local/bin/chat-mode
# consider this option: https://mathiasbynens.be/notes/shell-script-mac-apps
if [ $# -eq 0 ]
then
echo "Please specify 'on' or 'off'."
exit
fi
if [ "$1" = "on" ]
then
open /Applications/LINE.app
open /Applications/WhatsApp.app
open /Applications/Signal.app
open /Applications/Messages.app
open /Applications/Telegram.app
open /Applications/Keybase.app
open /Applications/Discord.app
open /Applications/Wire.app
exit
fi
if [ "$1" = "off" ]
then
osascript -e 'quit app "LINE"'
osascript -e 'quit app "WhatsApp"'
osascript -e 'quit app "Signal"'
osascript -e 'quit app "Messages"'
osascript -e 'quit app "Telegram"'
osascript -e 'quit app "Keybase"'
osascript -e 'quit app "Discord"'
osascript -e 'quit app "Wire"'
exit
fi
echo "Please specify 'on' or 'off'."
exit
You can’t perform that action at this time.