Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Run script on mac prompt "Permission denied"

I'm new to mac with not familiar on terminal command, i put the dvtcolorconvert.rb file on root directory of my volume, this ruby script can converting xcode 3 themes into xcode 4 themes format, which is xxxxxxxx.dvtcolortheme format.

Then run the script /dvtcolorconvert.rb ~/Themes/ObsidianCode.xccolortheme on terminal, but it's always prompt "Permission denied".

what's wrong with this? Anybody can help me solve this problem? Thanks.

like image 600
Andy_24 Avatar asked Sep 05 '12 07:09

Andy_24


People also ask

How do you give permission to run a file on a Mac?

To grant execute permission on a Mac: Open the Mac terminal window. Type chmod -R +x * . This command adds execute permission to all files and folders inside the gradle folder.

How do I run shell script Permission denied?

To fix the permission denied error in Linux, one needs to change the file permission of the script. Use the “chmod” (change mode) command for this purpose.


1 Answers

Did you give yourself the rights to execute the script?

The following command as super user will do this for you:

sudo chmod 755 'filename'

For details you should read the man page of chmod.

like image 100
schluchc Avatar answered Sep 22 '22 08:09

schluchc