Jump to content

deanishe

Member
  • Posts

    8,759
  • Joined

  • Last visited

  • Days Won

    522

Everything posted by deanishe

  1. Welp, it looks like we have our answer. No Dashlane integration possible till Dashlane supports 3rd-party integration. Out of interest, what features did you want from 1Password?
  2. I'm going to invoke the power of Cunningham's Law a wee bit to get someone who knows Ruby well to answer your question, too… Absolutely Python. No question. It's much more readable than Ruby and has a much better community. When it comes to Alfred workflows in particular, my Alfred-Workflow library for Python is streets ahead of the Ruby competition in terms of how much of the grunt work it can take off your hands. There are awesome tutorials available for Python: Dive Into Python How to Think Like a Computer Scientist Learn Python the Hard Way (it's not actually hard) A Byte of Python And my own tutorial for writing workflows in Python with Alfred-Workflow.
  3. Just had another idea. If you can get the proxy.pac URL from the system (which is simple enough), you could use pacparser to execute the proxy.pac file and determine the correct proxy settings. But I imagine it would slow your workflow down quite a bit.
  4. You can extract workflow keywords from each workflows info.plist file. Shawn wrote a workflow that does this.
  5. There are a couple of ways to turn off your display (which locks the machine if you have set it to require a password immediately after sleep/screensaver). This doesn't mess up the network connection (in my experience), nor continue to draw power for the display (like with a screensaver). You can use the keyboard shortcut CTRL+SHIFT+EJECT or CTRL+SHIFT+POWER (depending on which button your Mac has). Alternatively, the shell command pmset displaysleepnow does the same thing, if you want to use an Alfred keyword. There are also a few apps that do the same thing.
  6. It's possible the API is blocking him because he's been hammering it. The Google Translate API is largely a paid service these days. Try restarting your router (to get a new IP address) and/or altering the user agent in the script. Or just don't use the workflow for a day.
  7. That was the biggest reason for my caveat I use the shit out of my own workflows because I wrote almost every one of them to scratch a personal itch. Of other people's workflows, only your Markdown to BB code and Robin's ssh workflow make my top 10 most used. Even when I find a workflow that is really useful, I often end up re-implementing, or at least hacking it so it fits my needs (a bit) better.
  8. Does anyone know if it's even possible for arbitrary 3rd-party applications to integrate with Dashlane? I've had a poke around the website and googled a wee bit, and I can't find any indication that it's possible. It's possible you could abuse utilise the interface used by browser extensions to communicate with the app, but if it's not official, I can't see Andrew going for it. Alfred offers 1Password integration because 1Password has an official (and fairly simple) way for 3rd-party apps to integrate with it.
  9. I looked into this for my Searchio! workflow. DDG's search suggestion API doesn't support bangs. You might be able to hack something together by parsing the HTML or hacking some unofficial API, but that would be slow and liable to break.
  10. You're quite likely to run into problems trying something like this. This issue is that the app receiving the keystrokes can't tell the difference between the modifiers specified in the AppleScript and the ones you're currently holding down to activate the workflow action via Alfred. That is to say, if you set up a hotkey in Alfred, say CMD+SHIFT+A, to send CMD+ALT+S to an application, the application will register CMD+SHIFT+ALT+S because you've probably still got your finger on the SHIFT key. You should make sure that the modifiers you assign in Alfred are the same as, or a subset of the modifiers you want to send to the application.
  11. Yeah, but not quite like that. In Alfred's workflow GUI, you can specify an application to open the given files with. On the command line (or in a Run Script action in Alfred), you use open -a "Marked 2" <path to file>
  12. I don't want to do it. I just thought it should be in this thread. Perhaps on the wiki, too.
  13. Could somebody more familiar with Ruby explain how to bundle gems with your workflow? As with Python, asking users to install gems in the system Ruby is a recipe for disaster.
  14. Is it possible to install the gems within the workflow itself before distributing it? It seems excessively complex to require users to install rvm or the like, so as not to mess up the system Ruby.
  15. The package is a bit messed up. Somehow, there are >30 copies of workflow in there: zipinfo of-create.alfredworkflow … … workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/spec/app/omnifocus_spec.rb -rw-r--r-- 3.0 unx 973 tx defN 24-Apr-15 19:14 workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/spec/app/task_generator_spec.rb -rw-r--r-- 3.0 unx 3001 tx defN 24-Apr-15 19:21 workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/spec/app/task_spec.rb -rw-r--r-- 3.0 unx 4376 tx defN 24-Apr-15 16:31 workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/workflow/spec/spec_helper.rb
  16. I doubt very much that AppleScript will work with Windows applications running in Parallels beyond very basic "open" or "activate" commands (which are performed by the system and don't require an app to be scriptable). I looked into this a bit. When you run Parallels in shared-application mode, it creates stub Mac applications in ~/Applications, which is what your script was acting upon. Any scripting that requires explicit support by the application (the AppleScript dictionary David was talking about) almost certainly won't work. FWIW, you might want to look into editing the stub applications created by Parallels. You could rename the "Google Chrome" one to "Google Chrome (Win)", for example, to avoid the issue. You'd probably have to edit the Info.plist file inside the app bundle and change the application name in there as well.
  17. Yeah. But it would let us know whether it's possible to talk to Mac Chrome when Parallels is up and running. The problem appears to be that Parallels is registering Win Chrome as "Google Chrome", so all the calls are going to that application. Until that problem is solved, the rest of the script is moot. There are a couple of other ways to call an application that might work: 1. By bundle id: tell application id "com.google.Chrome" … end tell 2. By path: tell application "/Applications/Google Chrome.app" … end tell Give those a try instead.
  18. Are you good with Perl? If not, you might want to consider using another language like Ruby or Python. They're a lot easier to use, and you'll get more help on here because they're much more popular with workflow authors.
  19. I can't test this, as I don't use Parallels (because I think it's a scummy company), but it might work if you call Chrome via open instead. Replace the Chrome part of the AppleScript with: do shell script "open -a 'Google Chrome' " & quoted form of currentSafariURLBut if Parallels is dicking about with AppleScript dictionaries/definitions, that likely won't work.
  20. Hover the mouse cursor briefly over the point where the lines join your "movies" keyword object. You should see a little "nub" appear. Click on the nub (keeping the mouse button pressed down) and drag a connection to the left-hand side of your trakt.tv action.
  21. Updated to allow you to easily add your own generators.
  22. A very silly bug crept in while I was fixing the last one. 2.1.3 should run as intended. Update as described above.
×
×
  • Create New...