Created
October 7, 2010 15:44
-
-
Save richardpeng/615318 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/bin/bash | |
# Switch between XBMC and Boxee | |
if ps ax | grep -v grep | grep xbmc.bin > /dev/null | |
then | |
echo "XBMC running, killing process" | |
kill `pidof xbmc.bin` | |
sleep 7 | |
echo "running Boxee" | |
/usr/bin/runBoxee & | |
elif ps ax | grep -v grep | grep Boxee > /dev/null | |
then | |
echo "Boxee running, killing process" | |
kill `pidof Boxee` | |
sleep 7 | |
echo "running XBMC" | |
/usr/bin/runXBMC & | |
else | |
echo "No UI running, starting XBMC" | |
/usr/bin/runXBMC & | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment