What’s the difference between:
sh myscript.sh
and
./myscript.sh
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
#!/bin/shloadsshfrom that path. If on Linux then it is likely a symbolic link tobash.sh tremor_script.shuses thePATHenvironment variable to findsh, which might be totally different.Track down which
shyou are using, maybe usingwhich sh, and following any links.Note that Android uses
ashormksh, depending on the Android version.However, messages like “junk at end of line” might come from files that have been copied from Windows without the \r\n line endings corrected to \n.