Jump to content

[Request] Airmail workflow

Recommended Posts

The airmail app has just been released out of beta and it would be awesome to integrate it with alfred




Alfred should work with it perfectly for composing new messages since Alfred uses the default method for opening a new mail message. Where Alfred won't support AirMail is attaching files. Alfred cannot support that at the moment because he relies on AppleScript support in the application in order to do that. AirMail doesn't really have much support for AppleScript beyond the basic window manipulations. At a quick glance I didn't see any documentation on the site to indicate otherwise either. I purchased AirMail yesterday also. I used it a good bit during the beta. If they add AppleScript support or some other method for attaching files programmatically, perhaps support could be added for it then.

Link to comment
  • 3 months later...

Just a note that AppleScript appears to have been improved but I don't know which versions are supported yet.




There was an error with the AppleScript support in some of the previous versions but if you have some of the newer betas of Airmail, this should work.



Drop it in ~/Library/Application Support/Alfred 2/Plugins/Email

Link to comment
  • 2 months later...

@Alfred Guru, I've dragged and dropped your script as instructed, restarted Alfred / Computer, but still can't get Alfred to send files via Airmail.app...

Maybe because of Alfred AND Airmail recent updates?




This script was originally created when the AppleScript support for Airmail was available only in the beta version. It is now available in the stable release. To get the linked script above to work, change the file name to just Airmail.applescript, and in the script, when it tells "Airmail Beta", change the name to just "Airmail". Drop in the same location mentioned above and it should work fine.

Link to comment
  • 2 weeks later...

There's a very handy workflow working with Airmail already shared at these forums. I can't take any credit for it whatsoever, but it's useful.


The default mail functionality works with any mail client because it opens a standard mailto: link. The workflow we are referencing here adds the ability to attach files to mail in Airmail. That functionality isn't available for all clients because it relies on Applescript. 

Link to comment
  • 2 months later...

@Alfred Guru i downloaded the script and went into my library, then application support, however there is no Alfred 2 folder for some reason? i created one, then also created a subfolder for plugsins, then email and dropped the script into there. no luck however. any ideas? thanks in advance 


That folder should exist.. Are you using Alfred 1 or 2?

Link to comment
  • 1 month later...

I've dropped the AppleScript file into the proper location, ~/Library/Application Support/Alfred 2/Plugins/Email.


What is supposed to happen after that? Is the "Email" file action now supposed to call the Airmail script instead of the default Mail.app one? Because nothing has changed for me. Mail still opens by default.


I've properly changed both the filename of the script and its contents to replace "AirMail Beta" with "Airmail" but that doesn't seem to make a difference. I have also restarted both Alfred and Airmail.


Yeah it should. What version of Alfred are you using? If the defat mail client isn't Alfred, when composing a message with an attachment, Alfred (2.0.7 and above, released August 8, 2013) should check to see if an mail plugin is available for that mail client and use it to create the new message with attachment.

Link to comment
  • 2 weeks later...

Oh, cool. Looks like this functionality is now baked-in to Alfred with the new 2.2 update: http://www.alfredapp.com/changelog


Default support for Airmail.app added for creating emails with attachments


So this specific script is no longer required.


I did notice however that Alfred does not by default use the Airmail application located in /Applications. I had a backup copy of Airmail.app sitting on my desktop, and on using the "Email" file action as usual, the Desktop copy launched instead of my /Applications copy. (Build 243)


The script we were referring to is the same script that is used with the built-in support that was added. Alfred relies on AppleScript to add support for mail applications. That being said, the script just does a..

tell application "Airmail"

So, it sounds like the one that is in /Applications isn't set as the default mail app. I'd open the version residing in /Application, go to the General preferences and untick and then tick the "Make default mail application" option to try and make sure that it is the default app.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...