I'm learning bash and I tried to make a simple script that changes the directory and executes a command, like this:
#!/bin/bash
cd adf-elite-connector
<execute a command>
But I was getting the following error:
-bash: ./dc.sh: /bin/bash^M: bad interpreter: No such file or directory
If I removed the bin/bash header and have the following script:
cd adf-elite-connector
<execute a command>
I would get an error with a truncated directory name:
: No such file or directoryite-connector