1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-01-01 11:14:55 +00:00

(sh-mode): Set shell type based on file name if no other specific basis.

This commit is contained in:
Richard M. Stallman 2006-02-21 19:55:46 +00:00
parent fe541a2743
commit f623a9d2e6
2 changed files with 32 additions and 0 deletions

View File

@ -1,3 +1,25 @@
2006-02-21 Richard M. Stallman <rms@gnu.org>
* progmodes/sh-script.el (sh-mode): Set shell type based on file name
if there's no other specific basis.
* emacs-lisp/unsafep.el (unsafep): Don't treat &rest or &optional
as variables at all.
(unsafep-variable): Rename arg; doc fix.
* abbrevlist.el (list-one-abbrev-table): Add autoload.
* calendar/appt.el (diary-selective-display): Add defvar.
* sort.el (sort-columns): Use Posix arg syntax for `sort'.
* isearch.el (search-whitespace-regexp): Fix custom type.
* help.el (describe-key-briefly): Compute interactive args
in same was as before previous change.
* files.el (enable-local-variables): Doc fix.
2006-02-21 Kim F. Storm <storm@cua.dk>
* fringe.el: Cleanup as file is now pre-loaded.

View File

@ -1438,6 +1438,16 @@ with your script for an edit-interpret-debug cycle."
((and buffer-file-name
(string-match "\\.m?spec\\'" buffer-file-name))
"rpm")))))
(unless interpreter
(setq interpreter
(cond ((string-match "[.]sh\\>" buffer-file-name)
"sh")
((string-match "[.]bash\\>" buffer-file-name)
"bash")
((string-match "[.]ksh\\>" buffer-file-name)
"ksh")
((string-match "[.]csh\\>" buffer-file-name)
"csh"))))
(sh-set-shell (or interpreter sh-shell-file) nil nil))
(run-mode-hooks 'sh-mode-hook))