Skip to content

Instantly share code, notes, and snippets.

@afragen
Created June 17, 2013 18:29
Show Gist options
  • Save afragen/5799062 to your computer and use it in GitHub Desktop.
Save afragen/5799062 to your computer and use it in GitHub Desktop.
Helper script with mount.sh. In this case makes sure iTunes is running after calling mount.sh. I use this script on my media server for LAN wide iTunes sharing.
#!/usr/bin/env bash
# script to start/keep iTunes running after mount.sh
# call from mount.sh
myProcess="/Applications/iTunes.app"
# sleep 5
ps ax | grep -v grep | grep -v iTunesHelper | grep $myProcess > /dev/null && exit 0
echo "opening $myProcess"
open -g $myProcess
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment