using terms from application "Quicksilver" on process text tweet set wordcount to do shell script "echo " & quoted form of tweet & " | wc -c" set wordcount to do shell script "echo " & quoted form of wordcount & " | sed 's/^[ ]*//'" if wordcount as integer > 140 then my growlRegister() growlNotify("Tweet too long", "(" & wordcount & ") characters") return nothing end if set twitter_key_account to "YOUR_EMAIL" set twitter_key_pass to "YOUR_PASSWORD" set twitter_login to quoted form of (twitter_key_account & ":" & twitter_key_pass) set twitter_status to quoted form of ("status=" & tweet) set results to do shell script "curl --user " & twitter_login & " -F " & twitter_status & " http://twitter.com/statuses/update.json" -- display dialog results my growlRegister() growlNotify("Tweet Sent", tweet) tell application "System Events" if exists process "iChat" then tell application "iChat" set the status message to tweet end tell end if end tell end process text end using terms from using terms from application "GrowlHelperApp" -- Register Growl on growlRegister() tell application "GrowlHelperApp" register as application "Tweet" all notifications {"Alert"} default notifications {"Alert"} icon of application "Twitterrific.app" end tell end growlRegister -- Notify using Growl -- Example: growlNotify("This is an Alert","This is a test of the Growl Alert System") on growlNotify(grrTitle, grrDescription) tell application "GrowlHelperApp" notify with name "Alert" title grrTitle description grrDescription application name "Tweet" end tell end growlNotify end using terms from