Stuck on Keyboard Maestro

I’ve downloaded Keyboard Maestro to have a play, and have a problem I can’t seem to solve.

I want to select a file and then kick off an action which will

  1. Copy the file name without the extension
  2. create a folder in the same folder with the copied name (i.e. the same name as the file without the Extension
  3. move the originally selected file into the folder.

I want to be able to do this anywhere in the file system, so don’t want to preselect the folder where the new folder is created.

Is this too complex for Keyboard Maestro? Do I need to delve into AppleScript.

With a file selected in Finder, this will do what you want.

Edit: I missed the ‘move the file’ part.

6 Likes

Keyboard Maestro has its own excellent forum with people who will offer help with virtually any problem if you can frame a question in a reasonable way. Check it out.

1 Like

Awesome! I didn’t know Alt+Cmd+C copied the file name. Is there an equivalent “paste in a new filename” key combo? I would guess Alt+Cmd+V but that isn’t very imaginative of me. :slight_smile:

I could imagine (and actually use) a “smart filename editor”.

1 Like

What exactly are you referring to here?

I was trying to explain a use case where you could - with eg Keyboard Maestro - take the selected file’s name and edit it and put it back by pasting.

Today I do some of this with Hazel - but that is automatic. Sometimes I want to do it manually.

Select the file in Finder, hit enter and you’re editing. Enter again and it’s renamed. :slightly_smiling_face:

I would second this for sure :slight_smile:

take the selected file’s name and edit it and put it back by pasting.

I assume you mean via some automation, like datestamping the filename, correct?

1 Like

Perfect thank you just had to add a move command at the end.

1 Like

Yes. Or changing “X.Y.Z.REPORTS” to “Z.csv” - which is a real example of mine. Automation could offer me a “yes/no” choice for this, for example.

Maybe create a dropfolder for the files if the action is repetitive? Have Hazel watch the folder, and rename anything that is dropped in there?

I do that for some of my invoices, have an invoice folder on the desktop that renames the fole (adds date + invoice and files to DT)

I do think this will be even easier in Monterey when you can use a shortcut from finder