Supervisor Linked to Shell

David N Murray <>
Fri Apr 23 15:08:52 CEST 2010

Hi all,

Newbie question.  I have:

-export([start/0, init/1]).

start() ->
    supervisor:start_link(?MODULE, []).

init(_) ->
    {ok, {{one_for_one, 3, 3600}, []}}.

128> t:start().

I'm developing in Emacs.  If I make a mistake in the shell, it brings down
the supervisor:

129> crash().
** exception error: undefined shell command crash/0
     in function  erlang:error/1
        called as erlang:error({shell_undef,crash,0})

=ERROR REPORT==== 23-Apr-2010::09:06:08 ===
** Generic server <0.683.0> terminating
** Last message in was {'EXIT',<0.676.0>,
** When Server state == {state,{<0.683.0>,t},


** Reason for termination ==
** {{shell_undef,crash,0},

How can I prevent this?  From the book I'm using, it looks like
supervisor:start() was removed.  I'm using R13B04.


More information about the erlang-questions mailing list