Add macos alert script

This commit is contained in:
2017-06-15 12:19:18 -05:00
parent 07d3d5fa07
commit 6a0029ede3
2 changed files with 6 additions and 13 deletions

6
bin/alert Executable file
View File

@@ -0,0 +1,6 @@
#!/bin/bash
MSG=$@
echo -e '\a'
osascript -e "tell application (path to frontmost application as text) to display dialog \"$MSG\" buttons {\"OK\"} with icon note" &> /dev/null

View File

@@ -1,13 +0,0 @@
#!/bin/bash
i3status | while :
do
read line
MPC=`mpc current`
if [[ -z $MPC ]]
then
echo "$line" || exit 1
else
echo "Playing: $MPC | $line" || exit 1
fi
done