|
|
@@ -17,16 +17,17 @@
|
|
|
-export([print/1, print/2, usage/1, usage/2]).
|
|
|
|
|
|
print(Msg) ->
|
|
|
- io:format(Msg).
|
|
|
+ io:format(Msg), lists:flatten(io_lib:format("~p", [Msg])).
|
|
|
|
|
|
print(Format, Args) ->
|
|
|
- io:format(Format, Args).
|
|
|
+ io:format(Format, Args), lists:flatten(io_lib:format(Format, Args)).
|
|
|
|
|
|
usage(CmdList) ->
|
|
|
- lists:foreach(
|
|
|
+ lists:map(
|
|
|
fun({Cmd, Descr}) ->
|
|
|
- io:format("~-48s# ~s~n", [Cmd, Descr])
|
|
|
+ io:format("~-48s# ~s~n", [Cmd, Descr]),
|
|
|
+ lists:flatten(io_lib:format("~-48s# ~s~n", [Cmd, Descr]))
|
|
|
end, CmdList).
|
|
|
|
|
|
usage(Format, Args) ->
|
|
|
- usage([{Format, Args}]).
|
|
|
+ usage([{Format, Args}]).
|