Some extra stuff for erlang, wrappers, etc...
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


some extra erlang stuff for Emacs.

I noticed that Emacs erlang stuff wasn't up to date with latest erlang stuff. Particularly, there was no way of using kerl to use different erlang installations.

This is some noodling to help with those extra things in erlang.

getting going in erlang

Install erlh (this repo) - erlang mode comes with emacs

Download kerl from the kerl project.

Save this as a /.kerlrc

# kerl rc file controlling what happens for builds

mkdir for kerl erlang installations, say: /source/kerl-erlangs

Use kerl to get, build and install one or more erlangs into /source/kerl-erlangs

customize-variable erlh-kerl-installs-dir to say where the root of your kerl installations is (eg: /source/kerl-erlangs)

and customize-variable erlh-kerl-installs-pattern to a regex that will match any erlang installed there note what's this for??

C-x C-f a new .erl file (maybe in a directory you'll use for the project)

You should now be able to use C-c C-z to get an erlang shell and C-# to use the erlang man function.

what is erlh-kerl-installs-pattern for??

If you set erlh-kerl-installs-dir to a directory you keep other things than erlang installs in then you will need to distinguish them from each other. This pattern let's you do that.

Suppose you have an erlh-kerl-installs-dir of /sources (as I do):


When I choose an erlang installation I don't want to pick a name from that directory, I want to choose just erlang installs. The pattern let's me do that. Maybe there's a way of eliminating that by using kerl to tell us.