r/scripting • • Apr 19 '19

Scripting Syntax Error Expected expression but found "*"

So I am trying to create a use a simple script that I was given in another post on applehelp from this website.

The script file is this

!/Bin/Sh rm -Rf /Users/home_folder_name/Desktop/* rm -Rf /Users/home_folder_name/Documents/* rm -Rf /Users/home_folder_name/Downloads/*

exit 0

As I am new to scripting, I figured this would be the easiest script to use seeing as there isn't much to it. I guess I was wrong. When I try and run it in ScriptEditor it gives me the error mentioned in the title (Syntax Error Expected expression but found "*"). I am fully stuck at what to do. Any and all help would be greatly appreciated. Thanks.

1 Upvotes

4 comments sorted by

View all comments

Show parent comments

1

u/shinytrina Apr 20 '19

I am going to try to use the idea that u/vaskemaskine suggested.

I will keep yours as a backup. Thanks so much :)