Mengatasi “Bash script and /bin/bash^M: bad interpreter: No such file or directory”

Instalasi software melalui file dengan ekstensi .sh. Saat hendak di-eksekusi di terminal, muncul error:

Bash script and /bin/bash^M: bad interpreter: No such file or directory

Mengatasi hal itu, buka terminal, kemudian ketik:

sed -i -e 's/\r$//' namafile.sh

Lalu kembali coba buka file tersebut:

./namafile.sh

Selamat mencoba.

Sumber:
https://stackoverflow.com/questions/14219092/bash-script-and-bin-bashm-bad-interpreter-no-such-file-or-directory
Sebagai Dokumentasi

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s