Posted By

ttscoff on 01/27/09


Tagged

curl applescript api textexpander


Versions (?)

Who likes this?

3 people have marked this snippet as a favorite

aka
qbnrox
tschloss


Mac Lover Sig for TextExpander


 / Published in: AppleScript
 

I just figured out that TextExpander can execute AppleScripts. This is an experiment.

  1. set _date to do shell script "date +'Sent on %A, %b %d at %l:%M %p'|tr -s ' '"
  2.  
  3. set _quote to do shell script "curl -s 'http://www.iheartquotes.com/api/v1/random?source=macintosh&max_lines=4&show_source=0&show_permalink=0'|sed -n '$!p'"
  4.  
  5. set _out to "
  6. -Brett
  7.  
  8. " & _date & "
  9. ________________________________
  10. Brett Terpstra | [email protected]
  11. The Unofficial Apple Weblog  http://www.tuaw.com
  12.  
  13. " & _quote
  14.  
  15. return _out

Report this snippet  

You need to login to post a comment.