3 ms·
This seems interesting because it feels like I can gain more control over the desktop which previously I felt limited to by Bash or Python. Being a web dev I ne
by cdnsteve 12y ago
This seems interesting because it feels like I can gain more control over the desktop which previously I felt limited to by Bash or Python. Being a web dev I never wanted to get into Obj. C or Swift so this seems like it's opening some doors to a broader audience. It's funny they are showcasing Mail - does anyone actually use the desktop mail client? I thought that's been dead since 2003?
Can you leverage this API from within Node.js running on OSX ? Then we can start to see some cool, realtime desktop stuff.
EG:
How I think this could be used for a developer:
"Applet" or script that opens up a dev project you're working on.
- Open Sublime text (or whatever IDE)
- Pull latest down from Git
- Fire up your respective local server if needed
- Run tests
- Release unicorns if everything goes Green through Desktop notifications of some type
- dubcanada 12y agoOSA was always AppleScript, and it's not really that bad of a language.
- matthewmacleod 12y agoI don't agree - it's a hideous, imprecise, undocumented language. Truly awful to work with.
- dubcanada 12y agoAppleScript is very thoroughly documented? And I don't think hideous is a complaint, hideous is a personal opinion. Imprecise, you'll have to expand on. While certain things, depending on you want to do turn into a wild goose chase requiring multiple hundred lines of code to get something simple. That will not change with JavaScript, in some instances it looks like it may require even more lines with JavaScript. And it is a natural language, language. I don't think it is as terrible as you make it out too be.
- e40 12y agoAppleScript is very thoroughly documented? As a recent Mac OS user, there were a bunch of things I wanted to automate with AS. I looked and looked for documentation and basically never found a coherent set of docs anywhere. So, I'd (still) love to see the thorough documentation.
- steveax 12y agoThe best documentation is Matt Neuburg's _AppleScript: The Definitive Guide_ [1] although it may be a bit dated now. Matt is one of the most talented tech writers out there. [1]: http://shop.oreilly.com/product/9780596102111.do http://shop.oreilly.com/product/9780596102111.do
- tjl 12y agoWell, AppleScript is well documented. See Apple's Developer Site, https://developer.apple.com/library/mac/documentation/AppleScript/conceptual/AppleScriptlangguide/introduction/ASLR_intro.html https://developer.apple.com/library/mac/documentation/AppleS... But, that's just AppleScript. The problem is that the scripting dictionaries for applications are inconsistent. But, that's the fault of the developers and you'll run into the same problem with Javascript. Oh, for a good overall site, I'd recommend Mac OS X Automation, http://www.macosxautomation.com http://www.macosxautomation.com which has pointers to a lot of resources for AppleScript, Automator, and Services.
- sigzero 12y agoWhen OSX first came on the scene there was a javascript OSA. A company called "Late Night Software" or some such had a drop in that allowed you to use js.
- vezzy-fnord 12y agoIt's funny they are showcasing Mail - does anyone actually use the desktop mail client? I thought that's been dead since 2003? I'm not sure if you're referring to OS X Mail in particular or desktop mail clients in general, but I personally still use the latter (Thunderbird) very frequently. Binding all of your webmail addresses into a single local application is quite convenient.
- weaksauce 12y agoI have been using mailmate as a successor to thunderbird because thunderbird's search was so slow amongst many other show stopping bugs for me. It's worth checking it out if you search your mail a lot or have power user mail needs... The smart folders are a neat feature that are very powerful and fast.
- weaksauce 12y agoI have used AppleScript to open the current finder location in a new iTerm tab and to open all selected files in vim or the folder if nothing's selected... AppleScript is terrible but the end product is useful. Another one was to merge a folder of PDFs into one document and another to convert a bunch of images into one PDF. Useful stuff but a bit awkward to create it initially.
- coldtea 12y ago>It's funny they are showcasing Mail - does anyone actually use the desktop mail client? I thought that's been dead since 2003? Were did you get that idea? Extrapolating your personal usage habits? Mail.app is one of the most frequently used OS X programs. From 30+ Mac users I know, most of them use Mail. Not everybody has switched to webmail (or wants to). I personally use it with a Gmail account.
- MiddleEndian 12y ago>It's funny they are showcasing Mail - does anyone actually use the desktop mail client? I thought that's been dead since 2003? I switched away from OS X in 2011, and I still miss Mail.app.