rice.shawn
-
Posts
973 -
Joined
-
Last visited
-
Days Won
57
Content Type
Blogs
Gallery
Downloads
Events
Profiles
Forums
Articles
Media Demo
Posts posted by rice.shawn
-
-
Is it that the XML is bad because there isn't an appropriate bit of data that is escaped with CDATA?
-
I'm through and through American. I spent the first many years in Texas and the last decade in New York. But before I had to come into an office, my natural hours didn't quite match up to my timezone.
The job has definitely got me working quite a bit with much less downtime to work on my other projects (last weekend, I had to work 28 hours to save a project that was moving past deadline), but I guess this is what I get for working at a publishing company with editorial deadlines.
I've been making an effort to carve out time to work on Packal, but a lot the Alfred 3 changes have made it harder to support both Alfred 2 and Alfred 3. I don't want to ditch those still using Alfred 2. Packal still gets about 18k page views a week and has some value as a central place for workflows, so I do want to repair it. So little time...
-
-
I just (finally) pushed an update that should make this work out of the box with Alfred 3 as well as 2. Find the update on Packal, and let me know if there are any problems.
-
To follow up, if you are writing it in Python and using Dean's library, he's made some nice wrappers around these commands for ease. If you're writing it in PHP and using Alphred, then the same sort of wrappers exist. If you're doing it otherwise, then you'll have to access the commands yourself.
-
Crap. So I need to get back to work (deadline tomorrow; needing to do crap over the weekend). And I didn't manage to refresh my AS quick enough to fix the AS in the configure script. I'll get back to that after I push the final changes on the work deadline.
For now, I pushed some changes to the git repo; but I need to get on an old computer with Alfred 2 in order to export it and not break others' installations. Will do that and post here after I fix the AS problem.
-
As Andrew mentioned, among other things, Packal.org runs a virus scan on every workflow uploaded (using clamscan, and the virus database is updated daily), so I can assure you that there are no viruses in any workflow that clamscan can catch (early on I did test by uploading workflows with viruses, and Packal rejected them).
That being said, there can still be malicious activity, but I haven't seen any workflow that has done anything bad since Alfred 2 has been out. By bad, I mean intentionally bad. The problems that Dean mentioned have happened, but the community is pretty good about finding these and then reporting them and getting them changed.
S
-
Actually, caffeinate can do this. You just need to have the "emulate user activity" option selected.
-
The AS just runs a quick pop-up for the configuration, so that problem does not apply. There is no tell Alfred 2 or Alfred 3 in there (unless I'm totally forgetting something from code that I wrote three years ago -- total possibility).
(Although you could get around that problem by checking to see if they are installed, and wrapping the tell statements in an if, etc...)
-
Wouldn't have helped with the app name in the AppleScript though
That's exactly what I'm debugging right now... trying to get the system variable and convert it to a path in AS. Damn, it's been a while since I've touched AS.
-
Damn. Just report these bugs to me, and I'll take care of them. This is an insanely old workflow that existed before the environmental variables were introduced, so I had to hardcode the paths. I'll update them.
-
I just did a quick fix. It might be working again.
-
Yo. That & there in <name>Files & Folders</name> is illegal XML.
Yep. I figured that's what it was. Amazing that this particular escaping issue hasn't come up until now, especially since it's been there since Sept 15.
-
It seems like the workflow manifest is corrupt. I'll try to look into it either today or tomorrow.
-
It is, AFAIK, abandonware (at least for the time being). There are a few workflows out there that use it, but I'm fairly confident it isn't being actively developed and I'm not sure Shawn would recommend using it at this time.
I might revisit it at some point soon. I do think it is useful, and v2 was close to being done. I have a few other things on my plate before I get back to it.
-
Hi! I have been a user of Alfred (+ Powerpack) for years, but only recently decided to invest more time into customizing it with the workflows I thought were helpful.
As I am a software developer, I generally setup any new Mac OSX environment using a completely automated installer: https://github.com/kigster/pullulant
I wanted to add to Pullulant a simple bash script for installing Alfred. I can install the software itself using Homebrew, and then I was hoping to download and install my favorite workflows.
I have now spent over an hour searching online, and I am absolutely stunned to find out that Alfred, the supposedly tool for automating your OS-X life, is itself so difficult to automate!!!
What I want is a single line command I can run in Terminal (or iTerm, i.e. bash), that tells Alfred to import the given workflow. Since Alfred insists on choosing a category for a workflow (which is completely useless in my opinion), I would imagine that this command would need to tell Alfred what category to assign it.
Right now I am able to do this:
open $(curl -s -L -O -w %{filename_effective} \ https://github.com/packal/repository/raw/master/com.alfredapp.mdeboer.atom/atom.alfredworkflow)
And as you would expect, curl downloads the file, OSX then opens Alfred, which then stays open like a village fool waiting for me to choose a category for it, and I can't, for the love of life, my laptop or the universe, find a way to make this entire process non-interactive, so that I can run it in a goddamn loop and be done with it.
Why!? Why is it so hard? LOL. Cry. LOL. Cry.
Sorry, it's very late, and I am getting a bit delirious. I do not mean to offend anyone, I just hoped that I could find a solution without having to post a new question in the forum, because even after searching this entire forum for "install", "command line", "bash", "terminal", "non-interactive" I found nada.
Your truly,
Konstantin
If you want to find some code that does this, then you can look at the Packal updater. If you want some more specific code, then you can look into the v2 branch on GH, especially this file: https://github.com/shawnrice/packal-updater/blob/2.0.0/Libraries/Workflows.php.
It's all in PHP.
If you're just trying to install them and aren't worrying about upgrades or accidentally getting default hotkey values that are set in the distributed workflow, then you can do:
wget http://path/to/workflow.alfredworkflow unzip workflow.alfredworkflow mv workflow ~/path/to/installed/workflows/
-
Would love to know if there's any update on the potential to create a 'connect/disconnect' script for Bluetooth devices.
I've looked fairly extensively, and I know of no tools that let us interface with the bluetooth controllers at this level.
If someone has a good grasp of C and can parse through the lower-level bluetooth libraries, then they might be able to write a compiled tool that could do such a thing. Getting it to work across multiple versions of iOS and distribution would be a pain. The skill set is not one that I possess.
I wouldn't hold out much hope.
-
Dean's Python library is pretty damn good, and he keeps it better maintained than any other library. If you like Python or if you want to brush up on your Python or if you want to learn Python, then writing workflows with his library is a great way to go.
However, if you want to play with more Ruby, then go for it. You could always update the gems and learn from the best practices that Dean implemented with his stuff. The difficulty of Ruby dependencies is actually a bit easier than Python's dependencies (in my opinion).
-
Is it possible to add Pinyin to the results? The functionality doesn't seem to be published on Google's API documentation, however the Google API seems to support it (at least the previous version before they locked down the API) as seen in this package:
https://pypi.python.org/pypi/goslate#romanlization
I looked through the source for the but couldn't even find where this package made an API call...
It'll probably take me a while to get to this. If it were in the documentation, then it would be much easier to do, but otherwise I have to find the time to reverse engineer the API calls (which might change if they're not official).
-
These are fairly simple - https://github.com/ctwise/alfred-workflows
This is definitely the simplest way to do things. Past that, in order to write script filters, you just need to read up a bit on how Alfred reads XML and make sure that your code spits out the well-formatted XML that Alfred needs. Ruby gets a bit more complicated if you want to share your workflows because you need to be sensitive to different versions of Ruby that are installed on the systems natively (you can't assume an upgrade), and you should favor natively installed gems over including other ones (installing dependencies is a bit hard to do reliably across many different systems).
But, beyond that, you can do much of what you want.
-
Yeah, this is one of those things that I would love to be able to write/use, but it's not feasible to do it in any elegant way because Apple (for some reason) locks down Bluetooth in a rather draconian fashion. It's still a dead end as far as I know.
-
Another thought for possible failure. Google provides three months free (basically), but if you downloaded the previous version and created the project on Google then, you didn't need to add a credit card to your account. If you haven't added one by now to let it bill you, then it might be rejecting the queries based on that.
-
Can you copy/paste the INI file here? Replace the API key value with xxxxxxxxxxxxxxx
-
Still not working.
By the way, why the first result has no flag or language? Look:
P.S.: Notice, as I already pointed in this thread, that the code for Brazilian Portuguese is wrong (pt-BZ instead pt-BR).
Try deleting the config file. It should be somewhere like ~/Library/Application Support/Alfred 2/Workflow Data/com.spr.translate.api/config.ini.
Then re-enter the api key and try again. More than likely there is a null value for the first item. I'll change the code for BR soon.
Packal: Workflow and Theme Repository
in Share your Workflows
Posted
To keep Packal a bit more open, I used Github as a backend. Github restricts (unless they changed this) unknown filetypes to 10mbs. And, even though `alfredworkflow` files are `zip`, they are still technically unknown.