diff options
author | Eric <[email protected]> | 2012-09-08 11:15:49 -0500 |
---|---|---|
committer | Eric <[email protected]> | 2012-09-09 18:25:49 -0500 |
commit | 9aab4d7a16fba5dfcf4d60b58a05cc765eca3335 (patch) | |
tree | c8427ae3b23a333309444ae2710f8e2974495f6c /src/rcl_util.erl | |
parent | d3debef8d90735087425f7ad03da4010d636d6a7 (diff) | |
download | relx-9aab4d7a16fba5dfcf4d60b58a05cc765eca3335.tar.gz relx-9aab4d7a16fba5dfcf4d60b58a05cc765eca3335.tar.bz2 relx-9aab4d7a16fba5dfcf4d60b58a05cc765eca3335.zip |
full argument parsing and management capability
Diffstat (limited to 'src/rcl_util.erl')
-rw-r--r-- | src/rcl_util.erl | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/rcl_util.erl b/src/rcl_util.erl index c0b5c5d..be20302 100644 --- a/src/rcl_util.erl +++ b/src/rcl_util.erl @@ -21,8 +21,10 @@ %%% @doc Trivial utility file to help handle common tasks -module(rcl_util). --export([mkdir_p/1]). +-export([mkdir_p/1, + indent/1]). +-define(ONE_LEVEL_INDENT, " "). %%============================================================================ %% types %%============================================================================ @@ -41,6 +43,11 @@ mkdir_p(Path) -> DirName = filename:join([filename:absname(Path), "tmp"]), filelib:ensure_dir(DirName). +%% @doc ident to the level specified +-spec indent(non_neg_integer()) -> iolist(). +indent(Amount) when erlang:is_integer(Amount) -> + [?ONE_LEVEL_INDENT || _ <- lists:seq(1, Amount)]. + %%%=================================================================== %%% Test Functions %%%=================================================================== |