Difference between revisions of "/bin/bash^M: bad interpreter: no such file or directory"

From ETCwiki
Jump to navigationJump to search
 
 
Line 1: Line 1:
 
[[Category: Linux]]
 
[[Category: Linux]]
 
I had this error and was confused why-- even though i was using Windows to write my script for bash (Notepad++), I had created it originally as a .py file which set it to DOS encoding instead of utf-8.  
 
I had this error and was confused why-- even though i was using Windows to write my script for bash (Notepad++), I had created it originally as a .py file which set it to DOS encoding instead of utf-8.  
 +
 +
/bin/bash^M: bad interpreter: no such file or directory
  
 
==solution==
 
==solution==

Latest revision as of 17:57, 24 July 2015

I had this error and was confused why-- even though i was using Windows to write my script for bash (Notepad++), I had created it originally as a .py file which set it to DOS encoding instead of utf-8.

/bin/bash^M: bad interpreter: no such file or directory

solution

recreate the file and paste your original contents using VIM or some other basic text editor.

External Links