Create an automator script to create folder + move files into created folder

automatorfinderscript

Looking to create a service in Automator so when I select multiple files in the Finder, I can in one right-click create a new folder and move the selected files into that newly created folder. This action could include a step that will ask me to name this folder but it's not mandatory. Any idea?

Best Answer

Here is an alternate solution.

Not sure if you're aware of this but there's already a keyboard shortcut in Finder, (control + command + N) which creates a new folder containing the selected finder items. This can also be accessed through the contextual menu when right clicking on selected Finder items.

This AppleScript code works for me using the latest version of macOS Mojave.

enter image description here