mirror of
https://github.com/correl/rebar.git
synced 2024-12-18 03:00:17 +00:00
When profiling, save analysis results to disk
This commit is contained in:
parent
45fc18f990
commit
1c1620a244
1 changed files with 6 additions and 3 deletions
|
@ -72,9 +72,12 @@ run(RawArgs) ->
|
|||
case rebar_config:get_global(enable_profiling, false) of
|
||||
true ->
|
||||
io:format("Profiling!\n"),
|
||||
fprof:apply(fun(A) -> run_aux(A) end, [Args]),
|
||||
fprof:profile(),
|
||||
fprof:analyse();
|
||||
try
|
||||
fprof:apply(fun(A) -> run_aux(A) end, [Args])
|
||||
after
|
||||
fprof:profile(),
|
||||
fprof:analyse([{dest, "fprof.analysis"}])
|
||||
end;
|
||||
_ ->
|
||||
run_aux(Args)
|
||||
end.
|
||||
|
|
Loading…
Reference in a new issue