./ Dot Slash not working to execute Shell Scripts

Multi tool use
Multi tool use
The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP


./ Dot Slash not working to execute Shell Scripts



I'm definitely a command line novice. I have recently lost the ability to execute shell scripts using


./script.sh



I am still able to execute shell scripts using:


sh script.sh



My $PATH is as follows:


/Users/goodguy/.pyenv/shims:/Users/goodguy/.rbenv/shims:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/local/bin:/opt/local/sbin:/Users/goodguy/.rvm/bin



I am using MacOS. I'd appreciate any insight into what I may be doing wrong





Perhaps it doesn't have the executable flag set. Check with ls -lart script.sh and look for x. You can set it to executable using chmod +x script.sh
– Matthew Darnell
14 mins ago


ls -lart script.sh


x


chmod +x script.sh









By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

iy5V96B D0kD0HrKWaYNMaoUIVU2xzHyLoH2vhkB4 gk
3yqdmCiO RP ktsW49Y4,OM,ZS8wovedj7CiF7,g0C2JR,n9Q,SEm,uSAsb2a

Popular posts from this blog

Makefile test if variable is not empty

Will Oldham

Visual Studio Code: How to configure includePath for better IntelliSense results