Jump to content

ClintonStrong

Member
  • Posts

    115
  • Joined

  • Last visited

  • Days Won

    7

Reputation Activity

  1. Like
    ClintonStrong reacted to Benzi in f.lux workflow   
    This is not very foolproof and is very basic at the moment, but you can change the color temperature with Flux.
     

     
    Update 1: Now includes option to disable Flux for a minute/hour
     
     
    Download  it from here and check it out.
  2. Like
    ClintonStrong got a reaction from JMoVS in Copy Files to Clipboard   
    This is a file action to copy one or more files to the clipboard, so you can paste them into another app. Sphardy requested this in the Beta Discussion forum, and I was also wanting a similar feature, so I went ahead and put this together.
     
    Updated Oct 26, 2013: Fix for Mavericks.
     
    Download
  3. Like
    ClintonStrong got a reaction from bevesce in Copy Files to Clipboard   
    This is a file action to copy one or more files to the clipboard, so you can paste them into another app. Sphardy requested this in the Beta Discussion forum, and I was also wanting a similar feature, so I went ahead and put this together.
     
    Updated Oct 26, 2013: Fix for Mavericks.
     
    Download
  4. Like
    ClintonStrong got a reaction from CarlosNZ in Pause iTunes After This Track   
    This workflow pauses iTunes after the current track is finished playing. Useful for when you want to take a break, but don't want to interrupt the song you're listening to.
     
    I originally wrote this for Alfred 1, but I never published it. It doesn't take advantage of any Alfred 2 features, but I hope it still might be useful to someone.
     
    Download
  5. Like
    ClintonStrong reacted to sphardy in Alfred Applescript Dictionary installed multiple times   
    ta da!!
     

     
    Seems to be similar issue that causes apps to be listed multiple times in the "Open with..." menu - fixed by:
    /System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user
  6. Like
    ClintonStrong got a reaction from alkawArow in Pause iTunes After This Track   
    This workflow pauses iTunes after the current track is finished playing. Useful for when you want to take a break, but don't want to interrupt the song you're listening to.
     
    I originally wrote this for Alfred 1, but I never published it. It doesn't take advantage of any Alfred 2 features, but I hope it still might be useful to someone.
     
    Download
  7. Like
    ClintonStrong reacted to Tyler Eich in Colors—convert color formats & access the OS X color panel   
    Colors v2.0.0
     
    Get it from Packal (Recommended)
     
    Quick Summary:
    This workflow can process and convert all CSS color formats and several Objective-C formats, namely NSColor (calibrated and device) and UIColor. It also provides an interface to the OS X color panel for easier color manipulations.
     
    It's written in native code (i.e. it's really fast).
     
    Quick Preview:

    You can find a full description on Packal.
     
    Direct download • source code on Github
  8. Like
    ClintonStrong got a reaction from Tyler Eich in Colors—convert color formats & access the OS X color panel   
    This is amazing. You win the internets.
     
    Oh, and adding to the color picker code ctwise posted, you could just add a bit of AppleScript to show the color in Alfred:
     
    OUTPUT=$(osascript -e 'tell application "Finder"' -e 'activate' -e 'choose color' -e 'end tell' | ruby -e 'puts "#" + STDIN.read.split(",").map{|y| "%.2x" % [y.to_i>>8]}.join'); printf $OUTPUT | pbcopy; osascript -e 'tell application "Alfred 2"' -e "search \"$OUTPUT\"" -e 'end tell' You can paste that code in to Terminal if you want to see it in action.
  9. Like
    ClintonStrong got a reaction from mccamel in Search Safari and Chrome Tabs [Updated Feb 8, 2014]   
    Updated. You can download it here or in my original post.
    Fixed an issue with tabs not showing up for Safari. Improved performance. You may still get some slowdown if you're running multiple browsers at the same time, but that'll be fixed in the next update. I'm working on a rewrite to further improve performance and add a few new features. It's not quite ready yet, but I'll try to get it out soon.
  10. Like
    ClintonStrong got a reaction from drking in Search Safari and Chrome Tabs [Updated Feb 8, 2014]   
    Updated. You can download it here or in my original post.
    Fixed an issue with tabs not showing up for Safari. Improved performance. You may still get some slowdown if you're running multiple browsers at the same time, but that'll be fixed in the next update. I'm working on a rewrite to further improve performance and add a few new features. It's not quite ready yet, but I'll try to get it out soon.
  11. Like
    ClintonStrong reacted to ddjfreedom in Recent Downloads with Feedback   
    An Alfred workflow for opening or revealing the most recently downloaded items in “~/Downloads”.
      http://d.pr/f/yLXo   The items are sorted in decreasing order according to when they were added to the folder. Items are filtered by whether they contain the query as a subsequence. The result is displayed using the feedback functionality.   Github repo: https://github.com/ddjfreedom/recent-downloads-alfred-v2   Use config.yaml in ~/Library/Application Support/Alfred 2/Workflow Data/recentdownloads.ddjfreedom/ to control the new default behavior:  
     
    Updated: 1. added the option to delete files (holding 'ctrl') (by fmr) 2. result's icon matches file's icon 3. added the option to move files to trash (holding 'cmd') (by fmr) 4. changed the default behavior of certain files: if the item can be installed (an application, an dmg file, a zip file containing those files, etc), the workflow will prompt the user whether to install it. After the installation, if the item installed is an application, the workflow will prompt the user whether to launch it.
  12. Like
    ClintonStrong got a reaction from phyllisstein in Workflow idea: Quickly navigate to recent folders   
    I updated this to support the new type="file" attribute in b100. This means Alfred will treat the results like files, so you can use the right arrow to action them, or add them to your file buffer.
     
    I'm not sure about the keyword ("recent"), as it's been used by a couple of other workflows. Would "folders" or "finder" work better?
     
    Download: http://cl.ly/1x3J0s0L0z0h
  13. Like
    ClintonStrong got a reaction from simonbs in Google Chrome Tab Search (Workflow)   
    Noticed a bug: if there are double quotes in a tab's title, the workflow returns no results. I think you can just use `quoted form of (title of theTab)` within the JSON string, and it should add double quotes around it and escape any double quotes within.
     
    Also, you might have noticed that if you try to focus a tab that's in a background window, it won't fully bring that window to the foreground (the titlebar is grayed out, and it doesn't respond to keyboard events). You can use AXRaise to fix that. Here's the code I used in my "Search Browser Tabs" workflow:
     
    tell application "System Events" to tell process "Google Chrome" perform action "AXRaise" of window 1 end tell  
    Just add that code to the end of the AppleScript, and it should properly focus the window.
  14. Like
    ClintonStrong got a reaction from Jono in Recent Downloads with Feedback   
    Nice workflow. Just a quick tip: you can tell Alfred to make the icon match a file's icon. In the resulting XML, it'd look something like this:
     
    <icon type="fileicon">/path/to/file</icon>
  15. Like
    ClintonStrong got a reaction from hpiwzqda in Search Safari and Chrome Tabs [Updated Feb 8, 2014]   
    Search your tabs in Safari, Chrome, Chromium, Chrome Canary, and Webkit.



    When you action a result, it'll bring your browser to the front and switch to the selected tab. You can also close a tab by holding down alt when actioning a result.

    Download from Packal
     
    Updated Feb 8, 2014: Made it more resilient to an AppleScript error that could cause a blank output.
     
    Update #2, Feb 1, 2014: Fixed regression with searching. You should be able to search anchored by words (and capital letters in CamelCase words) again.
     
    Updated Feb 1, 2014: Rewrote the workflow. It now supports copying the URL of a tab, viewing a tab in QuickLook, and closing a tab with a modifier key.
     
    Updated Oct 11, 2013: Fixed issue with improper string encoding in Mavericks and Ruby 2.0 breaking the workflow.
     
    Updated Oct 9, 2013: Updated for Mavericks and Ruby 2.0.0. Removed thumbnails for now (beta versions of Safari don't seem to generate them anymore). Fixed some issues where the proper window wouldn't always focus correctly.
     
    Updated May 4, 2013: Experimental support for webpage thumbnails. Prevent launching browsers when WebKit is open.

    Updated Mar 26, 2013: (Hopefully) prevent launching browsers when it's not supposed to, and fix an issue with it not detecting WebKit.
  16. Like
    ClintonStrong got a reaction from M1m1s in Search Safari and Chrome Tabs [Updated Feb 8, 2014]   
    Search your tabs in Safari, Chrome, Chromium, Chrome Canary, and Webkit.



    When you action a result, it'll bring your browser to the front and switch to the selected tab. You can also close a tab by holding down alt when actioning a result.

    Download from Packal
     
    Updated Feb 8, 2014: Made it more resilient to an AppleScript error that could cause a blank output.
     
    Update #2, Feb 1, 2014: Fixed regression with searching. You should be able to search anchored by words (and capital letters in CamelCase words) again.
     
    Updated Feb 1, 2014: Rewrote the workflow. It now supports copying the URL of a tab, viewing a tab in QuickLook, and closing a tab with a modifier key.
     
    Updated Oct 11, 2013: Fixed issue with improper string encoding in Mavericks and Ruby 2.0 breaking the workflow.
     
    Updated Oct 9, 2013: Updated for Mavericks and Ruby 2.0.0. Removed thumbnails for now (beta versions of Safari don't seem to generate them anymore). Fixed some issues where the proper window wouldn't always focus correctly.
     
    Updated May 4, 2013: Experimental support for webpage thumbnails. Prevent launching browsers when WebKit is open.

    Updated Mar 26, 2013: (Hopefully) prevent launching browsers when it's not supposed to, and fix an issue with it not detecting WebKit.
  17. Like
    ClintonStrong reacted to CarlosNZ in EggTimer v2 [updated to 2.0 final]   
    Hey folks,
     
    I've been chugging away building a new version of my EggTimer extension to take advantage of Alfred 2's new features. And now it's ready for whoever would like to to have a playaround with it and see what they think:
     
    EggTimer v2.0
     
     
    It will also be available at Tom's Alfred Repo, but I personally haven't had a chance to test that yet, so let me know how it goes for you.
     
    Now, it's very much a beta, as there's several things that don't work as well as I'd like yet, but I'm pretty pleased with how the integration with Alfred 2's new live results feedback via the Script Filter is working. My aim is to have a really nicely polished, easy-to-use (no users fiddling with config files) workflow ready to release by the time Alfred 2 goes public, so any comments or suggestions are most welcome.  It's ready! (22 March 2013)
     
    I've included a full summary of all the functionality in the documentation included in the download (enter timer help in Alfred), but here's just a quick overview of the features:
    Simple timers Auto-repeating timers Alarms (set a specific time) Snooze function Repeat function Recent Timers list (choose one to restart) Full integration into Alfred's results window. Couple of quick caveats:
    EggTimer currently requires growlnotify to display notifications when timers finish. This is because the timer process completely decouples from Alfred to run in the background, so it can’t feed back its output to Alfred. I’m working on a solution to use a Notification Centre alert option to make this as seamless as possible to the user.
    Currently, running timers won’t restart after a crash or a reboot. I’m working on a solution to this which I aim to have working soon.
    Okay, that's about it. Enjoy, and let me know how it works for you.
     
    ----
     
    21 January 2013: Updated to beta 2
     
    Changes:
    Timers/Alarms now use a “while…” loop to check due time against time of day (instead of just sleeping for a duration). This prevents the problem of timers running late if the computer was put to sleep. (Don't know why I didn't just do this to begin with.) ----
     
    24 January 2013: Updated to beta 3
     
    Changes:
    Now uses recommended working folders for storing timer info and preferences. The main benefit from the user point of view is that future updates won’t overwrite your timers and preferences. Timers and Auto-timers now accept hour:minute input. Syntax is timer HRS:MINS Reminder. Can now stop timers from the timer list using the option-key modifier. Kind of an ugly implementation though, as it will display the same information regardless of whether it’s context-appropriate. Trying to think of a better way to make this work. (Suggestions welcome!) Timers will be restored if they have crashed. This is only partially implemented though, because it’ll only check if you actually run the workflow. It won’t restore them at login yet, which is more important. Working on it. Miscellaneous minor tweaks. ----
     
    27 January 2013: Updated to beta 4
     
    Changes:
    The big one: will now resume timers after restart/re-login. EggTimer adds an entry to the OS X launchd daemon to check for and resume timers at startup. You will be prompted to give permission for this on first launch of EggTimer. New keyword/workflow structure. Check out the workflow config panel to see what’s what. If you’d prefer the old ones (all starting with timer), just change them yourself (eg. repeat -> timer repeat). You’ll note that from the timer list (timers or hotkey Ctrl-T) you can also select to launch a new timer or alarm (courtesy of Alfred’s new Applescript-ability). Now has a “nuke” option (timer nuke) to reset EggTimer back to initial blank config. (Deletes all working folders, cancels running timers, uninstalls startup item.) Fixed bug with “08” and “09” minutes entries when using hrs:mins timer format. More specific icons and other miscellaneous UI tweaks. beta4a
    Fixed minor (and embarrassing) regression. ----
     
    28 January 2013: Updated to beta4b
     
    Changes:
    Fixed absolute path reference preventing permission dialog from launching.  
    28 January 2013: Updated to beta4c
     
    Changes:
    Doh! One more pesky absolute path eliminated. There's still a bit of weirdness with resuming timers after a login though, so I'm still trying to figure that out. Maybe answer "no" to installing startup item for now.. beta4d
    Okay, the problem was fairly minor (just me being scatterbrained ), so the startup check should work nicely now. Here's hoping! ---
     
    22 March 2013: Updated to v2.0 (final)
    I've finally integrated proper notifications for the completed timers. It will work with either Growl or Notification Centre, depending on what you have selected in the workflow config. growlnotify is no longer required, and you'll find "EggTimer" as a properly registered application within Growl's preferences (where you can tweak it). Miscellaneous tweaks and tidy-ups (including documentation - timer help to display)
  18. Like
    ClintonStrong got a reaction from OliverJAsh in Search Safari and Chrome Tabs [Updated Feb 8, 2014]   
    I plan to add support for Canary, Chromium, and Webkit (I've already coded most of it). Unfortunately I'm having some issues with my system right now, but I'll try to get it updated as soon as I can.
     
    Edit: Done.
  19. Like
    ClintonStrong got a reaction from _mk_ in Debugging your workflows   
    Just wanted to share a few quick tips for debugging. If you're using /bin/bash to run a script, you can add "2> error.log" to output errors to a file. Example:
    ruby script.rb "{query}" 2> error.log  
    All errors will then be logged to error.log in your workflow's folder.
     
    Or if you want all output logged (perhaps so you can view the xml from a script filter), you could use tee:
     
    ruby script.rb "{query}" 2>&1 | tee output.log  
    That'll log errors from stderr in addition to standard output. Note that PHP doesn't output to stderr, so if you're using PHP you'll have to check PHP's error log instead.
     
    Also, if you have any formatting errors in a script filters' XML, Alfred will log it to Console.app.
     
    Hope this helps, and feel free to share your own tips.
     
  20. Like
    ClintonStrong got a reaction from OliverJAsh in Get keyword in AppleScript   
    As far as I know it's not possible to read the keyword. However, you could have each keyword run a bash script that sends a keyword to an applescript:
     
    osascript scriptname.applescript keyword  
    You'd then just open the workflow folder and create the applescript file there. To get it to read the keyword, you'd use something like this:
     
     
    on run argv set theKeyword to item 1 of argv -- your script here end run  
    It's not as elegant as I'd like, but hopefully it'll work for you.
  21. Like
    ClintonStrong got a reaction from cands in Search Safari and Chrome Tabs [Updated Feb 8, 2014]   
    Search your tabs in Safari, Chrome, Chromium, Chrome Canary, and Webkit.



    When you action a result, it'll bring your browser to the front and switch to the selected tab. You can also close a tab by holding down alt when actioning a result.

    Download from Packal
     
    Updated Feb 8, 2014: Made it more resilient to an AppleScript error that could cause a blank output.
     
    Update #2, Feb 1, 2014: Fixed regression with searching. You should be able to search anchored by words (and capital letters in CamelCase words) again.
     
    Updated Feb 1, 2014: Rewrote the workflow. It now supports copying the URL of a tab, viewing a tab in QuickLook, and closing a tab with a modifier key.
     
    Updated Oct 11, 2013: Fixed issue with improper string encoding in Mavericks and Ruby 2.0 breaking the workflow.
     
    Updated Oct 9, 2013: Updated for Mavericks and Ruby 2.0.0. Removed thumbnails for now (beta versions of Safari don't seem to generate them anymore). Fixed some issues where the proper window wouldn't always focus correctly.
     
    Updated May 4, 2013: Experimental support for webpage thumbnails. Prevent launching browsers when WebKit is open.

    Updated Mar 26, 2013: (Hopefully) prevent launching browsers when it's not supposed to, and fix an issue with it not detecting WebKit.
  22. Like
    ClintonStrong got a reaction from OliverJAsh in Debugging your workflows   
    Just wanted to share a few quick tips for debugging. If you're using /bin/bash to run a script, you can add "2> error.log" to output errors to a file. Example:
    ruby script.rb "{query}" 2> error.log  
    All errors will then be logged to error.log in your workflow's folder.
     
    Or if you want all output logged (perhaps so you can view the xml from a script filter), you could use tee:
     
    ruby script.rb "{query}" 2>&1 | tee output.log  
    That'll log errors from stderr in addition to standard output. Note that PHP doesn't output to stderr, so if you're using PHP you'll have to check PHP's error log instead.
     
    Also, if you have any formatting errors in a script filters' XML, Alfred will log it to Console.app.
     
    Hope this helps, and feel free to share your own tips.
     
  23. Like
    ClintonStrong got a reaction from rkj in Debugging your workflows   
    Just wanted to share a few quick tips for debugging. If you're using /bin/bash to run a script, you can add "2> error.log" to output errors to a file. Example:
    ruby script.rb "{query}" 2> error.log  
    All errors will then be logged to error.log in your workflow's folder.
     
    Or if you want all output logged (perhaps so you can view the xml from a script filter), you could use tee:
     
    ruby script.rb "{query}" 2>&1 | tee output.log  
    That'll log errors from stderr in addition to standard output. Note that PHP doesn't output to stderr, so if you're using PHP you'll have to check PHP's error log instead.
     
    Also, if you have any formatting errors in a script filters' XML, Alfred will log it to Console.app.
     
    Hope this helps, and feel free to share your own tips.
     
  24. Like
    ClintonStrong got a reaction from mklement0 in Search Safari and Chrome Tabs [Updated Feb 8, 2014]   
    Search your tabs in Safari, Chrome, Chromium, Chrome Canary, and Webkit.



    When you action a result, it'll bring your browser to the front and switch to the selected tab. You can also close a tab by holding down alt when actioning a result.

    Download from Packal
     
    Updated Feb 8, 2014: Made it more resilient to an AppleScript error that could cause a blank output.
     
    Update #2, Feb 1, 2014: Fixed regression with searching. You should be able to search anchored by words (and capital letters in CamelCase words) again.
     
    Updated Feb 1, 2014: Rewrote the workflow. It now supports copying the URL of a tab, viewing a tab in QuickLook, and closing a tab with a modifier key.
     
    Updated Oct 11, 2013: Fixed issue with improper string encoding in Mavericks and Ruby 2.0 breaking the workflow.
     
    Updated Oct 9, 2013: Updated for Mavericks and Ruby 2.0.0. Removed thumbnails for now (beta versions of Safari don't seem to generate them anymore). Fixed some issues where the proper window wouldn't always focus correctly.
     
    Updated May 4, 2013: Experimental support for webpage thumbnails. Prevent launching browsers when WebKit is open.

    Updated Mar 26, 2013: (Hopefully) prevent launching browsers when it's not supposed to, and fix an issue with it not detecting WebKit.
  25. Like
    ClintonStrong got a reaction from vivek in Debugging your workflows   
    Just wanted to share a few quick tips for debugging. If you're using /bin/bash to run a script, you can add "2> error.log" to output errors to a file. Example:
    ruby script.rb "{query}" 2> error.log  
    All errors will then be logged to error.log in your workflow's folder.
     
    Or if you want all output logged (perhaps so you can view the xml from a script filter), you could use tee:
     
    ruby script.rb "{query}" 2>&1 | tee output.log  
    That'll log errors from stderr in addition to standard output. Note that PHP doesn't output to stderr, so if you're using PHP you'll have to check PHP's error log instead.
     
    Also, if you have any formatting errors in a script filters' XML, Alfred will log it to Console.app.
     
    Hope this helps, and feel free to share your own tips.
     
×
×
  • Create New...