Jump to content


  • Content Count

  • Joined

  • Last visited

Reputation Activity

  1. Like
    JAAE reacted to deanishe in Screenshot to folder / tagger   
    Yes, but you'll need to do some coding.

    It appears you need:
    A Hotkey to trigger your workflow A Script Filter thatTells the system to take a screenshot and save it to a specific location Shows a list of pre-determined folders A script that accepts the path of the folder from the Script Filter and moves the screenshot to it. You can probably grab the screenshot with screencapture.

    With Alfred-Workflow, showing a list of folders is simple:
    import os from workflow import Workflow folders = [ '~/Documents/Stuff', '~/Desktop/More Stuff', '~/Dropbox/Screenshots', ] wf = Workflow() for path in folders: p = os.path.expanduser(path) wf.add_item(os.path.basename(path), path, arg=p, valid=True, type='file') wf.send_feedback() If you stick that in folders.py in your workflow, your Script Filter (Language = /bin/bash) might be:
    set -e screencapture -o $HOME/.temporary-screenshot.png /usr/bin/python folders.py And you'd connect that to a Run Script Action (also /bin/bash):
    mv $HOME/.temporary-screenshot.png "{query}"
  2. Like
    JAAE reacted to deanishe in Troubles with File filter (workflow input) and mkv files   
    Not really, no. As mentioned, it's a fundamental problem with the OS X metadata database and application developers naughtily declaring their own UTIs. Some developers are even too dumb to declare that their UTI for MKV is a subclass of "public.movie".
    There's nothing Alfred can do about this.
    If you have all your MKVs in one or two folders, and aren't afraid of Terminal, this should fix the issue:
    # See what UTIs are assigned to your MKV files. # This searches the current directory and its subdirectories. find /PATH/TO/MOVIES/FOLDER -name '*.mkv' -exec mdls -name kMDItemContentType {} \; # Tell the metadata subsystem to re-import the files. # This will update the UTI to whatever your system currently thinks # is the right one. find /PATH/TO/MOVIES/FOLDER -name '*.mkv' -exec mdimport {} \; # See what has changed find /PATH/TO/MOVIES/FOLDER -name '*.mkv' -exec mdls -name kMDItemContentType {} \; Obviously, you need to change "/PATH/TO/MOVIES/FOLDER" to the path to your movies folder. Run again for each root folder that contains MKVs (e.g. "~/Movies" and/or "/Volumes/Media/Movies").
    Your MKV files should now all have the same UTI. Make sure that's included in your File Filter. BTW, in the latest version of Alfred, you can manually add UTIs to the File Types list in your File Filter config screen. No need to edit info.plist any more.
  • Create New...