sh-mode usually does a great job of auto-magically detecting which shell a file is intended to be run by. It looks at the shebang, for instance. However, I have a bunch of files that are intended to be sourced, not run as executables, and thus I don't have a shebang.
I have my
$SHELL environment variable set to
bash, but when I open the file,
sh-mode still defaults to
sh. How do I get it to default to
I've tried running
(getenv "SHELL") in both
*scratch* and with
eval-expression in the shell file's buffer, and they both report
"usr/loca/bin/bash". Why doesn't
sh-mode respect this? I've been digging through the source code and it really seems like this should be working.