2 part question:
I\'m simply trying to run programs using applescript from the terminal, so I tried:
$ osascript tell application \"iTunes\" to activate
you need to put single quotes around the tell:
osascript -e 'tell app "iTunes" to activate'
otherwise you're defining a variable when you run -e