0

This question already has an answer here:

I have a basic start script for an application that I am trying to run. However, every time I execute it:

./start.sh

It fails with this error:

-ksh: ./start.sh: not found [No such file or directory]

This is despite the fact that I am in the same directory as the script, and I have permissions to run it. To further test, I made a simple test.sh script:

#!/bin/bash

echo test

Executing this with ./test.sh produces test.

marked as duplicate by roaima, Jeff Schaller Jun 12 at 16:18

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 1
    What is the first line of the script that doesn't work, and did you create it on your Linux system or on a Windows/Mac machine? Please edit your question to answer this - don't reply here as a comment. – roaima Jun 12 at 15:44
0

This is embarrassing - the script was written on a Windows machine with Intellij, and so was using the Windows line separators instead of Linux. Once I fixed that, the script ran like it was supposed to.

I'm sorry if I wasted anyone's time.

Not the answer you're looking for? Browse other questions tagged or ask your own question.