Emacs mode for Red
This is my personal fork of unchartedworks/red-mode, which fixes a few minor bugs I've had with it:
Bear in mind I'm not great with Emacs Lisp, and I've never made a mode of my own before, so the code might be written terribly.
- Make it derive from
prog-mode
. - Run
font-lock-update
inpre-command-hook
, as a crappy way to make the font locking work properly. - Replace a reference to
font-lock-doc-string-face
withfont-lock-doc-face
, which made the above fail (since the former has been renamed to the latter, according to a comment near the top ofcc-fonts.el
, which comes with Emacs). - Start
red-mode
when opening a.reds
file; not sure why this was commented out.
-
git clone https://github.com/unchartedworks/red-mode.git
into a suitable directory, e.g. ~/emacs/red-mode/ -
Add the following command to your .emacs or ~/.spacemacs:
(add-to-list 'load-path' "~/emacs/red-mode")
(load-file "~/emacs/red-mode/red-mode.el")