Idris syntax highlighting, interactive REPL and more things for emacs.
Emacs Lisp
Pull request Compare This branch is 684 commits behind idris-hackers:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.gitignore
COPYING
idris-commands.el
idris-common-utils.el
idris-compat.el
idris-completion.el
idris-events.el
idris-indentation.el
idris-log.el
idris-mode.el
idris-prover.el
idris-repl.el
idris-syntax.el
idris-warnings.el
inferior-idris.el
readme.markdown

readme.markdown

idris-mode for emacs

This is an emacs mode for editing Idris code.

Syntax highlighting functional languages is a little quirky; I've deferred to haskell-mode for some things (e.g. font-lock-variable-name-face for operators) and done some other things as appropriate for Idris. font-lock-type-face isn't used at all, for example, and data types declared with data use the same face as functions and values defined with =.

Screenshot

Documentation

There are some docstrings spread around the mode, thus C-h m is helpful and returns the available key bindings. The REPL also supports tab completion, thus pressing tab opens a buffer with the available completions.

Some preliminary notes are available in the pdf

Inferior Idris

There is now support for running an Idris interpreter in a buffer. Use 'C-c C-l' to load the current Idris buffer into the interpreter. This will spawn an inferior idris process and load the buffer. It will report warnings if idris reports any. Pressing C-c C-l again will reload that buffer - if you switch to a different buffer and press C-c C-l, that buffer will be loaded instead.

Customize inferior-idris-path if idris is not on your default path.

Installation

Place the elisp files somewhere in your load path and (require 'idris-mode) somewhere in ~/.emacs or ~.emacs.d/init.el.

Customization

Customize various aspects of the mode using M-x customize-group RET idris RET.