Hi all!

I found this script on the internet, which makes folders out of filenames then moving the files inside them.


for file in *; do
if [[ -f "$file" ]]; then
mkdir "${file%.*}"
mv "$file" "${file%.*}"


It works with terminal but first you must ''direct'' it to the proper folder ( writing cd and folder address inside terminal, then pasting the script )

I'd like - and i tried - using this script as a folder action with no success.
( I saved it as .scpt flie inside library/folder action scripts and then enabling folder actions to a folder, without any luck)

Then i tried with automator, as a folder action workflow, same there.

I'd really appreciate if anyone could tell me how should i do this, make a ''hot folder'' with the script above, to which when i throw a file inside, a new folder is created named after the file and then the file is moved inside the new folder.

I could also do with automator tutorials, if anyone has any or could help me find them, even in youtube - but those i saw weren't very helpful!

Thanks in advance!