emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/progmodes/sh-script.el


From: Richard M. Stallman
Subject: [Emacs-diffs] Changes to emacs/lisp/progmodes/sh-script.el
Date: Tue, 21 Feb 2006 19:55:33 +0000

Index: emacs/lisp/progmodes/sh-script.el
diff -u emacs/lisp/progmodes/sh-script.el:1.175 
emacs/lisp/progmodes/sh-script.el:1.176
--- emacs/lisp/progmodes/sh-script.el:1.175     Fri Feb 10 09:00:30 2006
+++ emacs/lisp/progmodes/sh-script.el   Tue Feb 21 19:55:33 2006
@@ -1438,6 +1438,16 @@
                 ((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))
 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]