]> gitweb.michael.orlitzky.com - emacs.d.git/commitdiff
Switch from ecmascript-mode to js-mode, which is built in to Emacs 23.2.
authorMichael Orlitzky <michael@orlitzky.com>
Sat, 25 Feb 2012 19:44:58 +0000 (14:44 -0500)
committerMichael Orlitzky <michael@orlitzky.com>
Sat, 25 Feb 2012 19:44:58 +0000 (14:44 -0500)
auto-modes.el
mode-hooks.el
mode-hooks/ecmascript-mode-hooks.el [deleted file]
mode-hooks/js-mode-hooks.el [new file with mode: 0644]

index 21149accf13e3ff2059fe1bf408f6f8b3271ebda..da87ef889929ba959c1f517478e48c40c24823ec 100644 (file)
        ;; ebuild-mode
        '("\\.ebuild$" . ebuild-mode)
 
-       ;; ecmascript-mode
-       '("\\.js$" . ecmascript-mode)
+       ;; js-mode
+       '("\\.js$" . js-mode)
 
        ;; haskell-mode
-       '("\\.hs$" . haskell-mode)
+       '("\\.l?hs$" . haskell-mode)
        
        ;; nagios-mode
        '("\\.cfg$" . nagios-mode)
        '("\\.xml$" . nxml-mode)
        '("\\.?html$" . nxml-mode)
        '("\\.config$" . nxml-mode)
-       '("\\.tpl$" . nxml-mode)
+       '("\\.tpl$" . nxml-mode) ;; Smarty templates
        '("\\.rdf$" . nxml-mode)
        '("\\.xul$" . nxml-mode)
                               
        ;; php-mode
        '("\\.php$" . php-mode)
+       '("\\.module$" . php-mode) ;; Drupal modules
                               
        ;; python-mode
        '("\\.pyx?$" . python-mode)
index ef9685e85f17e8145babbef19b20c8774224cbec..0e56534343b00057ce3c0c2ef36f30dd4aa68a5c 100644 (file)
@@ -3,7 +3,7 @@
 (load-library "basic-mode-hooks")
 (load-library "csharp-mode-hooks")
 (load-library "css-mode-hooks")
-(load-library "ecmascript-mode-hooks")
+(load-library "js-mode-hooks")
 (load-library "erc-mode-hooks")
 (load-library "haskell-mode-hooks")
 (load-library "nxml-mode-hooks")
diff --git a/mode-hooks/ecmascript-mode-hooks.el b/mode-hooks/ecmascript-mode-hooks.el
deleted file mode 100644 (file)
index 45303e4..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-(defun esm-hook()
-  (setq c-indentation-style "gnu")
-  (setq c-basic-offset 2)
-  )
-
-
-(add-hook 'ecmascript-mode-hook (function esm-hook))
diff --git a/mode-hooks/js-mode-hooks.el b/mode-hooks/js-mode-hooks.el
new file mode 100644 (file)
index 0000000..6b76b55
--- /dev/null
@@ -0,0 +1,6 @@
+(defun jsm-hook()
+  (setq js-indent-level 2)
+  )
+
+
+(add-hook 'js-mode-hook (function jsm-hook))