Jump to content

jdfwarrior

Member
  • Posts

    2,028
  • Joined

  • Last visited

  • Days Won

    55

Everything posted by jdfwarrior

  1. You are correct in that, Alfred fires a script filter as soon as you start entering data (after the keyword) and does fire at every character until your done. The alternate subtext is only shown when waiting on feedback from the script. So if the script fires back a result really fast, you may not ever see it. There isn't currently a way to pause the execution of the script for a certain amount of time, Only firing when the input reaches a certain length is how many others are doing it. I could see how that causes issues for you though. It seems that the script would need to be edited to look and make sure that it has all it needs. If it doesn't, it can return nothing or it can return a feedback item with the valid flag set to 'no' informing the user that it's still waiting on more data. So if it hasn't found two amounts and two units, return nothing or return some form of feedback saying that it's missing something. Once it sees that it has all that data, then return the actual feedback item that it should. Does all that make sense? Let me know if you still need help or have other questions.
  2. I don't use the print command at the end to return the XML, i typically use echo. So echo $w->toxml(); I'm not sure if ithat makes any difference at all or not. If the workflows class is generating XML it seems like the script is working. The only thing i'm wondering now is if there is some warning or error in the code that produces additional output that you don't see. When trying to work out things like this, what I typically would do is take all the code, put it in a php file, and run that from the command line. See if there is anything else that shows up other than the XML. If there is.. any kind of script warning or error, something else you echo'd out at one point and forgot to remove, then Alfred isn't going to to show it. Check those few things out and let me know your results. Keep me up to date, I'll help me you get this sorted out.
  3. There isn't a way to keep a persistent list of apps in Alfred. Though, using this workflow you could set your favs, then set a hotkey to execute this workflow. Then, when you wanted to access your fav apps, just press that hotkey
  4. I tried your code with one little tweak and got it to work. I removed the "on run {}" from the top, and the "end run" from the bottom. After that I created a new workflow, added a Hotkey trigger and a Run Script action. I set the language in the action to be /usr/bin/osascript and used this code: tell application "Microsoft Outlook" -- listSelectedItems : a list of all items selected in Entourage set listMessages to current messages -- Check to make sure items are selected, if not then quit if ((count of listMessages) < 1) then return display dialog "test" repeat with eachMessage in listMessages move eachMessage to folder "Todo" end repeat end tell Obviously, I changed the folder name as well but it seems to be working well. Hope this helps.
  5. That action was available for file's selected in Finder. This is still available but is available as a hotkey. Select the file you want to action and press Cmd+Opt+\
  6. That feature is definitely still available. If you are having issues with Alfred's knowledge, try resetting it and see if things pick up and start working properly. To reset his knowledge, open Alfred's preferences to the Advanced tab, and click the Clear Knowledge button toward the bottom.
  7. Unless you just really want the suffix added to the date (nd, rd, th, etc..) this could be done extremely easy in bash as well, and would probably be slightly faster. Your code DOES work. You may just have a slight hiccup in the setup. You would need to create a new Keyword input (set your keyword, title, and description), Run Script action (set the language to /usr/bin/osascript, and paste your code into the script area), and Copy to Clipboard output (enter {query} into the box at the top), then connect the three modules. Alternatively, you could use /bin/bash as your language in the second part and insert this into the script area: date +"%A, %B %d, %Y" Also, one final option, in the Copy to Clipboard output action, you could select the Automatically Paste to frontmost app option to make it so that when you run it, it auto pastes into the front app without having to paste it yourself.
  8. The text markers is a good idea as well. Thanks for mentioning this Ted.
  9. The only downside to autocomplete though is that you end up with a huge string where have to go back and parse out the project name and what task they want to do, OR you have to maintain some kind of context. So as they autocomplete, it saves data from the previous step, wipes the input box, changes the xml output, and continues on. Both are possible. Neither are extremely hard. Another alternative would be to have multiple steps in the workflow. Not saying this way is better, its all to your choosing, just mentioning it as "another way". This way involves kind of maintaining a context as well. For instance, you could have a.. keyword (script filter): add, that gives options to task or milestone. The output of this part would use Applescript to repopulate Alfred with 'project: ' which would be the keyword for a script filter to search for which project you want to add it to. That would be saved, then repopulate Alfred with 'task: ' and then you fill in the task. Pressing enter there would submit it to the site.
  10. Oh so you're going to blame it on me huh? jk, glad you were able to figure it out
  11. I was testing out the code that you provided and it didn't work, as you said, but... I tweaked it a little to do.. tell application "Mail" to set the read status of every message in every mailbox of every account to true It appeared to be working but I quit it before it finished because it was taking forever. Give me a little more time to tinker with it and see if I can't speed it up a bit. I'm going to see if I can't just grab a list of all unread messages and set just those to read. Maybe that will be slightly faster.
  12. I'm assuming that you are just trying to "open" this? I would assume that OSX probably doesn't know how to handle that because javascript exists in the browser and not OS-wide. You can still do it though. Try this instead. tell application "Safari" to do JavaScript "javascript:function iptxt(){var d=document;try{if(!d.body)throw(0);window.location='http://www.instapaper.com/text?u='+encodeURIComponent(d.location.href);}catch(e){alert('Please wait until the page has loaded.');}}iptxt();void(0)" in the current tab of the front window That triggers the javascript to run in the current tab of the front window in Safari (assuming that's what your using). We may have to tweak it a little bit if you aren't using Safari but I would think it would still be possible in the other browsers.
  13. Just wanted to drop a note back to you really quick. I spoke with Andrew and looks like we were correct. The .alfredappearance files provide a serialized NSColor object and I don't think it's going to be possible to read that. You'd be better off reading the values from the Theme URL as you mentioned above.
  14. This should still work. When you created a workflow for doing this, did you put the code in an NSAppleScript module or use a Run Script module and set the language to osascript?
  15. Without seeing the code and knowing what your doing, I'm not sure I can be of a whole lot of help right off. Have you wrapped the {query} in quotes to make sure its not dropped because of the space?
  16. I haven't looked at yours yet but another addition I find really useful to add to this is.. in the timestamp extension I made for Alfred 1, you could grab current timestamp, or pass a timestamp to it and it would read that and convert it to a human readable date/time. That would be super useful as well.
  17. i just downloaded the version of iTerm2 marked as the current stable version from their site. Everything seemed to work as it should for me. I also then got a notification that there was an update for iTerm. It appeared to be a build from 20130302. It also seems to function properly. The only kink I noticed with it was that, if iTerm wasn't open and I selected to "Open Terminal Here", it would open with 2 tabs. Could there be some setting that you have adjusted that may would be causing this?
  18. This uses the built in Amazon Search in Alfred so whatever your location is set to in the prefs is what it attempts to use.
  19. Um... let me consult with Andrew on this. I don't think it can be done by selecting a Contact, but by entering an email address you could. Maybe I'm missing something though, it's late. Give me a bit to think on it..
  20. I'm not even super sure where to being with this one. Can you provide the path that you are syncing workflows in? The issue you are describing definitely isn't normal and is something I've never heard of before. Please try to share as many details as possible so that I can try to help you figure this out.
  21. This is really strange and I'm wondering if this is a Snow Leopard issue for some reason but I'm not sure that it would be. Several have mentioned that it didn't work. As noted in the other forum, the settings file wasn't there. Its because when using my Workflows class that I use, it reads the bundleid out of the workflows info.plist file and then creates data folders for that workflow to store data. It should create.. ~/Library/Application Support/Alfred 2/Workflow Data/jdfwarrior.weather/ and then when you set your default location, create the settings.plist inside of that folder. For some reason (maybe isolated to Snow Leopard), it's not reading the info.plist and grabbing the bundleid, which is used to create the folder. Therefore the folder never gets created, the settings.plist doesn't show up in the correct location, and so the workflow thinks you haven't set one. I'll put out an update in a day or two to resolve this. I'll just move the settings back to the workflow folder.
  22. Cmd+click the border in the appearance settings. Done.
  23. Guys, the reason this doesn't exist is because all items in the list may not support QuickLook. For instance, people creating a Script Filter could potentially have results that are text, they could be an image, a url, Gary Coleman, anything.
×
×
  • Create New...