My default shell is fish and I don't want to change it. But in Emacs Tramp doesn't work well with fish. So I just want to set bash as default shell for Emacs only. Is it possible?
From the documentation for the shell
function (C-h f shell RET
):
Program used comes from variable `explicit-shell-file-name',
or (if that is nil) from the ESHELL environment variable,
or (if that is nil) from `shell-file-name'.
So, if you want to use "/bin/bash" as the shell file in emacs buffers, you can either:
set the variable `explicit-shell-file-name' in your ~/.emacs file:
(setq-default explicit-shell-file-name "/bin/bash")
set the ESHELL environment variable in your ~/.profile file:
export ESHELL=/bin/bash
set the variable `shell-file-name' in your ~/.emacs file:
(setq-default shell-file-name "/bin/bash")
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With