Running on windows 98 (with cygwin), The input ring is set
incorrectly when I run bash.
My shell command is set to "c:/Cygwin/bin/bash.exe"
So, shell-mode generates "bash.exe" as the shell when it does
(file-name-nondirectory (process-command ... ))
This causes the (string-equal shell "bash") test to fail.
(defun shell-mode ()
...
;; shell-dependent assignments.
(let ((shell (file-name-nondirectory (car
(process-command (get-buffer-process (current-buffer)))))))
(setq comint-input-ring-file-name
(or (getenv "HISTFILE")
(cond ((string-equal shell "bash") "~/.bash_history")
((string-equal shell "ksh") "~/.sh_history")
(t "~/.history"))))
...
))
So, I would suggest stripping the extension on windows with
file-name-sans-extension.
(if (eq system-type 'windows-nt)
(setq shell (file-name-sans-extension shell)))
If you like this I can submit a patch.
-jeff