aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorHenrik Nord <[email protected]>2014-03-19 12:02:41 +0100
committerHenrik Nord <[email protected]>2014-03-19 12:02:48 +0100
commit1ba34e263a71760d6e472a2800f5dc194847aad6 (patch)
tree615c170892f7e047339c6f54267ada0f9fdf6f0d /lib
parentdee53dd533fb4a0bd8280a9722b83fa6bcb69b59 (diff)
parentd2734c1829b92213ef9749219a1a882e6c37a810 (diff)
downloadotp-1ba34e263a71760d6e472a2800f5dc194847aad6.tar.gz
otp-1ba34e263a71760d6e472a2800f5dc194847aad6.tar.bz2
otp-1ba34e263a71760d6e472a2800f5dc194847aad6.zip
Merge branch 'technomancy/emacs-autoload'
* technomancy/emacs-autoload: Activate Emacs erlang-mode for .app files inside ebin directory. Add more file types to Emacs auto-mode-alist. Add Emacs autoloads for .erl and .app.src. OTP-11788
Diffstat (limited to 'lib')
-rw-r--r--lib/tools/emacs/erlang.el4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/tools/emacs/erlang.el b/lib/tools/emacs/erlang.el
index 27397a52fd..ec5a1f4bc5 100644
--- a/lib/tools/emacs/erlang.el
+++ b/lib/tools/emacs/erlang.el
@@ -1420,6 +1420,10 @@ Other commands:
(if (boundp 'after-change-major-mode-hook)
(run-hooks 'after-change-major-mode-hook)))
+;;;###autoload
+(dolist (r '("\\.erl$" "\\.app\\.src$" "\\.escript"
+ "\\.hrl$" "\\.xrl$" "\\.yrl" "/ebin/.+\\.app"))
+ (add-to-list 'auto-mode-alist (cons r 'erlang-mode)))
(defun erlang-syntax-table-init ()
(if (null erlang-mode-syntax-table)