Jump to content

dfay

Member
  • Posts

    1,054
  • Joined

  • Last visited

  • Days Won

    62

Everything posted by dfay

  1. By the way....if you don't have it already, this is invaluable: http://www.alfredforum.com/topic/2224-reference-importer/?hl=%2Breference+%2Bimporter
  2. You can skip the copying and use a hot key with selected text as the parameter. If that doesn't make sense reply and I'll put up some examples later
  3. Assuming Postbox is handling mailto: links , you could create a workflow that would compose a URL like mailto:emailname@yourdomain.com?subject=Subject and then send it to an open URL action. This means you'd need to pass both the email address and the subject line from Alfred - there are ways to do this, but they all require a bit of work. See http://www.alfredforum.com/topic/3890-help-with-multiple-queries-for-a-gmail-compose-script/?hl=%2Bmultiple+%2Bqueriesfor a discussion.
  4. If you're using a hotkey, you can just set its argument to OS X Clipboard Contents and pass it that way. Otherwise I'd just stick in a bash script with a single line with just one line: pbpaste then connect that to your python script. I'm assuming you're just going to use an Alfred Copy to Clipboard object at the end -- otherwise there are libraries like pyperclip if you're going to be actively modifying the clipboard midway through the python script.
  5. right. set a global hotkey in Alfred that runs an Applescript that tells iTerm to activate, then proceed from there.
  6. I still don't get why you wouldn't just activate iTerm right at the start, then write one set of actions based on the knowledge that is active..... Don't you want it active at the end in any case?
  7. Check out this thread: http://www.alfredforum.com/topic/5456-a-little-baffled-by-alfred-remote/
  8. what is your question exactly? How to tell if an app is frontmost in Applescript? see http://apple.stackexchange.com/questions/171709/applescript-get-active-application It would probably be more reliable to just tell application "iTerm" to activate , then go from there -- it sounds like you always want iTerm to be activated in the end.
  9. See this thread -- on searching Postbox but it highlights PB's limits in terms of playing nicely with macOS. http://www.alfredforum.com/topic/9233-search-postbox-4-emails-from-alfred/?hl=postbox
  10. My latest updates for TaskPaper 3 and OmniFocus: do shell script "cd '/Users/username/Library/Application Support/TaskPaper/'; cat day.less > theme.less" tell application "OmniFocus" set value of preference id "OFIColorPaletteIdentifier" to "builtin:OmniFocus Light" end tell Same code but with night.less and OmniFocus Dark for night. You need to create a day.less and night.less TP3 theme.
  11. I don't know whether to love this or hate this. It looks so good that everything else on my computer looks old and grungy by comparison
  12. well it looks like it's getting an Applescript error but beyond that you should contact the developer of the script
  13. See the contextual hotkeys section towards the bottom of this page: https://www.alfredapp.com/help/workflows/triggers/hotkey/
  14. Usually I use CodeRunner (for Python & Bash) or Script Editor (for AppleScript) with test queries to get everything working before copying it into Alfred. Makes the debugging process much easier.
  15. this is the expected behavior -- as soon as you type a keyword that matches an existing script filter workflow (like the audio output one you mention, which incidentally is working fine for me with Alfred 3), the script executes -- the problem is that the script(s) fail for some reason. Alfred is working as expected, but the workflow is crashing, so Alfred is reverting to default output. another thing that can happen is that some script filter-based workflows can take a couple of seconds to execute, so you'll get the default search and then the correct results will eventually appear. If you open the debugger - https://www.alfredapp.com/help/workflows/advanced/debugger/then run one of the workflows that is turning over to google search, you'll probably see some error messages.
  16. This generally means there's a bug or some other issue that's stopping the workflow from being able to run, so it falls back on a default search. Which means you should probably search for the workflow pages in the forum or contact the authors.
  17. Yes, using a file filter: https://www.alfredapp.com/help/workflows/inputs/file-filter/
  18. Hmm....running it on an Apple Mail message .emlx gives fields like this, which allow for a lot more granularity in the search: kMDItemAuthorEmailAddresses = ( "aperson@ucr.edu" ) kMDItemAuthors = ( "That Person" )kMDItemRecipientEmailAddresses = ( "someone@ucr.edu" ) kMDItemRecipients = ( "Faculty (somepopele@server.ucr.edu)" ) kMDItemSubject = "pithy but informative subject line" So the kMDItemTextContent may be the best you can do. If you wanted to push it you could probably find a regex to parse the email out of the text field.
  19. If you run mdls on a message, what are the metadata fields displayed? (see https://www.macissues.com/2014/05/12/how-to-look-up-file-metadata-in-os-x/ ) If Postbox is saving the metadata in a form Spotlight (for which mdls is part of the backend) can read, then it should be fairly straightforward to set it up along the lines of Vero's workflow above.
  20. Often I run a workflow and then immediately think of something I should add to it. It would be great to have a way to have a keyword or hotkey that would immediate Alfred's preferences open to the last workflow I ran.
  21. http://www.alfredforum.com/topic/8845-schedule-activate-deactivate/?hl=schedule
  22. I just had this problem with Spotlight not finding (& Quicklook not displaying) my old WordPerfect files -- when I ran the terminal command to manually import a file /usr/bin/mdimport -d1 filename it was showing dyn.ah62d4rv4ge81s6de as the file type I rebuilt Launch Services (I used MainMenu.app to do this but there's a terminal command to do the same) & after that the type shows as 'com.corel.wordperfect.doc' and Spotlight & Quicklook are back to working. So maybe rebuilding Launch Services will restore the correct net.daringfireball.markdown file type.
  23. you should be able to do this the old way via AppleScript see http://www.alfredforum.com/topic/5462-use-remote-to-send-keyboard-shortcuts/?fromsearch=1
  24. nah I don't think it's possible - if Doug Adams doesn't have a script for it, you can pretty much assume it can't be done yet. In Sierra maybe.
×
×
  • Create New...