Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Erlang: Is there a way to reload changed modules into an already running node with rebar?

Tags:

erlang

The rebar build tool seems pretty cool, but is there a way to recompile AND reload files into a currently running node with it?

like image 292
mwt Avatar asked Jun 02 '10 05:06

mwt


1 Answers

I don't see a need to bring rebar into it.

I use reloader.erl from the Mochiweb project. Just build this module along with the rest of your program and call reloader:start() early in your app's initialization sequence.

After that call, any time a module in your program changes on disk, the reloader will replace the running copy automatically.

like image 178
Warren Young Avatar answered Oct 27 '22 15:10

Warren Young