Skype

zalmy

Registered
on mac osx hints, someone posted this:
i would love to do it, nut i have no idea how to use applescript, could u tell me how to do this thing?

"I've cobbled together a rudimentary shell script (containing an AppleScript call) to have Skype call a specified phone number. I've been using it to schedule wake-up calls and call myself for important reminders during the day.

Since I personally find phone calls to be a more effectively jarring reminder method (more so than other alarms), I've found this script to be useful. I usually schedule it using a unix at command (as described in this hint), but you could cron it, or use some other scheduling technique.

Here's the script:
#!/bin/sh
# Tell Skype to dial a number

if [ -z "$1" ]
then
echo "usage: skypecall PHONE_NUMBER"
exit 65
fi

until [ -z "$1" ]

do
osascript -l AppleScript -e "tell application "Skype" to get URL "callto://$1""
shift
done &
sleep 59
killall -m "Skype"
exit 0
I've saved the script as skypecall (and chmod 755'd it). The command line syntax is: skypecall +18005551212 (or whatever number you would use to get Skype to normally work). The sleep 59 line insures that the Skype phone call doesn't stay open indefinitely, burning through your SkypeOut minutes. It forces Skype to quit after 59 seconds. Very ugly, but effective.


 
Back
Top