Skip to content

Commit

Permalink
mad clean
Browse files Browse the repository at this point in the history
  • Loading branch information
5HT committed Aug 21, 2014
1 parent 877239d commit bd06d0b
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 1 deletion.
Binary file modified mad
Binary file not shown.
6 changes: 5 additions & 1 deletion src/mad.erl
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,10 @@ attach(_Cwd,_ConfigFileName,_Config,Params) ->
% io:format("Attach Params: ~p~n",[Params]),
mad_run:attach(Params).

clean(_Cwd,_ConfigFileName,_Config,Params) ->
io:format("Clean Params: ~p~n",[Params]),
mad_run:clean(Params).

stop(_Cwd,_ConfigFileName,_Config,Params) ->
io:format("Stop Params: ~p~n",[Params]),
mad_run:stop(Params).
Expand All @@ -90,5 +94,5 @@ help() ->
io:format(" params := [] | run params ~n"),
io:format(" run := command [ help | options ]~n"),
io:format(" cmd := app | lib | deps | compile | release | bundle~n"),
io:format(" start | stop | attach | repl ~n"),
io:format(" clean | start | stop | attach | repl ~n"),
halt().
2 changes: 2 additions & 0 deletions src/mad_run.erl
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,5 @@ attach(_) ->
io:format("to_erl .devbox/~n"). % use like $(mad attach)

stop(_) -> ok. % TODO: stop box

clean(_) -> [ file:delete(X) || X <- filelib:wildcard("{apps,deps}/*/ebin/**") ].
1 change: 1 addition & 0 deletions src/mad_utils.erl
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ atomize("lib"++_) -> lib;
atomize("sta"++_) -> start;
atomize("att"++_) -> attach;
atomize("sto"++_) -> stop;
atomize("cle"++_) -> clean;
atomize("rel"++_) -> release;
atomize(Else) -> Else.

Expand Down

0 comments on commit bd06d0b

Please sign in to comment.