fun with macs, ssh, and osascript..

Posted by sergio_101 on Jan 23rd, 2007
2007
Jan 23

if you wanna have a little fun with someone’s mac, and are not afraid of the command line.. check out osascript..

here’s the scoop.. log into their machine using ssh.. you have to turn ssh on first.. it’s in system preferences/sharing. then, have at it..

i got most of my initial ideas from macoshints but you can have some real fun by automating these pranks..

here is some ruby code that we used to stir up trouble here:


phrases = ["im feeling kinda gay up in here", "charlie murphy",
            "i like boys", "does this shirt go with these shoes, darling?",
            "somewhere... over the rainbow", "im driving a boat",
            "Cold Blooded", "unity-eee", "my processor has informed me that your are gay",
            "i bet your favorite movie is brokeback mountain", "stihl chainsaws rule.. if you are a  homo",
            "your middle name is gaylord","hand check!", "check that price again, corey!"]
            
voices = ["Agnes", "Kathy", "Princess", "Vicki", "Victoria",
          "Bruce", "Fred", "Junior", "Ralph", "Hysterical"]

loop do
  phrase = phrases[rand(phrases.length)]
  voice = voices[rand(voices.length)]
  `sudo osascript -e 'say "#{phrase}" using "#{voice}"'`
  sleep_time = rand(300)+300
  puts "Sleep Time: " + sleep_time.to_s
  sleep(sleep_time)
end

Leave a Comment




XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Please note: Comment moderation is enabled and may delay your comment. There is no need to resubmit your comment.