Search for and Move Tagged Files/Folders

Trying to create a macro that will perform the following actions:

  1. Search my entire Mac for files and folders with a specific tag.

  2. Move the tagged items to a different folder of my choosing.

The only thing I see on KM related to tags in KM is "Set file attribute."

Can anyone help me get started? It would be much appreciated.

You can read tags from the Get File Attribute action, so something like this should work for the tags and file part (replace placeholders with real paths and/or variables as appropriate):

Example Macro.kmmacros (2.2 KB)

Try adding a notification action before each step. That way you'll know at least where it stopped.

1 Like

YA, that wasn't supposed to be there. LOL

and notification of failure was there.

I did figure out thast there was an easy solution for all of this - Hazel.

1 Like

Could you please post/upload your solution so that others can benefit.
Thanks.

Sure, but I'm not sure how since the solution isn't via Keyboard Maestro but I used a Hazel rule that said

Look in my for files and folder with < tags > that < Contain > Red Tag

Move

files to <.New Directory/folder >

2 Likes