How to execute shell script in cygwin?

23,648

Is that the actual output? If so, it's looking for another script called testing.sh.

testing.sh needs to be in a directory listed in the PATH variable, or you have to run it using a full path, e.g. ./testing.sh or ~/user/testing.sh.

Also don't forget to make testing.sh executable by running chmod +x testing.sh.

Share:
23,648

Related videos on Youtube

Lily
Author by

Lily

Updated on September 18, 2022

Comments

  • Lily
    Lily almost 2 years

    I store name.sh under C:\Documents and Settings\user when i type sh name.sh in Cygwin,

    sh: testing.sh: No such file or directory
    

    any help will be appreciated!

    • Dennis Williamson
      Dennis Williamson over 13 years
      Please don't cross-post.
  • Dennis Williamson
    Dennis Williamson over 13 years
    I think you may have missed the fact that there are two different filenames involved.
  • Lily
    Lily over 13 years
    Sorry,actually there is only name.sh involved, typing error
  • Nethan
    Nethan over 13 years
    That's OK. It's easy to make mistakes when typing. That's why it's better to always post the actual output. Or if you need to hide some sensitive information, copy paste into Notepad, do a Find/Replace, then post that.