#!/bin/sh

service bluetooth status > /dev/null && PTT_BTSTATUS=running  || PTT_BTSTATUS=stopped

if [ "$PTT_BTSTATUS" = "running" ]; then
	sudo pttbtstop
	notify-send "`basename $0`" "BT stopped."
fi
if [ "$PTT_BTSTATUS" = "stopped" ]; then
	PTT_NOTIFY=`sudo pttbtstart`
	notify-send "`basename $0`" "$PTT_NOTIFY"
fi

