aboutsummaryrefslogtreecommitdiff
path: root/src/econf.erl
diff options
context:
space:
mode:
authorEvgeny Khramtsov <ekhramtsov@process-one.net>2019-07-16 18:10:45 +0300
committerEvgeny Khramtsov <ekhramtsov@process-one.net>2019-07-16 18:10:45 +0300
commita7a53f601e80ac4cc318590dfa00596938579496 (patch)
tree7f6a991e1c732f3948c122b2b676b2f9d373f3b3 /src/econf.erl
parentFix opt_type.sh script and re-generate options (diff)
Add econf:string/2 validator
Diffstat (limited to 'src/econf.erl')
-rw-r--r--src/econf.erl5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/econf.erl b/src/econf.erl
index a2c22a43e..b150056ca 100644
--- a/src/econf.erl
+++ b/src/econf.erl
@@ -28,7 +28,7 @@
-export([pos_int/0, pos_int/1, non_neg_int/0, non_neg_int/1]).
-export([int/0, int/2, number/1, octal/0]).
-export([binary/0, binary/1, binary/2]).
--export([string/0, string/1]).
+-export([string/0, string/1, string/2]).
-export([enum/1, bool/0, atom/0, any/0]).
%% Complex types
-export([url/0, url/1]).
@@ -272,6 +272,9 @@ string() ->
string(Re) ->
yconf:string(Re).
+string(Re, Opts) ->
+ yconf:string(Re, Opts).
+
any() ->
yconf:any().