carlcaulkett Posted July 23, 2017 Author Share Posted July 23, 2017 Just to reiterate, like the "Searching for Folders" workflow, I want to be able to pass the output of the workflow back into the workflow again and only break out if the resultant link cannot be recursively scanned or if an action modifier is activated. Link to comment
deanishe Posted July 23, 2017 Share Posted July 23, 2017 (edited) 58 minutes ago, carlcaulkett said: Sorry, I didn't realise that the `zip` didn't work recursively. Yeah, that's bitten me before, too. In any case, exporting it via Alfred saves us the bother of having to change the extension so we can actually install the workflow. Here's an edited version of the workflow. I've implemented the first two levels (top-level and second-level) to show you how to connect them. I've connected them via External Triggers instead of just wiring them together, as it makes the layout more pleasant, albeit a bit more complicated. It works just the same as if they were connected via normal connections. I'll leave the further levels up to you, as the Classes pages are harder to parse, and I don't like parsing HTML (very error prone). The two main "features" I've added are filtering of the result by Alfred (by ticking the "Alfred filters results" box), so you can filter the results using a query, and very importantly, caching of the results. The way Alfred works, your workflow was downloading the webpage(s), more or less, on every single keypress. With caching, the workflow no longer hammers the server, and is much more responsive. Personally, I'd implement the workflow using a single script that understands different URL types, but that's somewhat more complicated. Also, I'd use Alfred-Workflow's filtering rather than Alfred's, as it's better-suited to things like class names. I'll also leave that as an exercise for you. Edited July 23, 2017 by deanishe Link to comment
carlcaulkett Posted July 23, 2017 Author Share Posted July 23, 2017 Dean, wow! That's amazing. Thanks very much. I'm going to learn so much from studying this. Link to comment
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now