From a347d19a1e61897350b74208510ed1b8f00aa772 Mon Sep 17 00:00:00 2001 From: Martin Wiso Date: Tue, 12 Apr 2016 21:06:19 +0200 Subject: [PATCH] Move to rebar3 --- README.md | 4 ++++ rebar.config | 6 +----- rebar.config.script | 12 ++++++++++++ src/erlpocket.app.src | 6 ++++-- 4 files changed, 21 insertions(+), 7 deletions(-) create mode 100644 rebar.config.script diff --git a/README.md b/README.md index 46f1038..c7368c2 100755 --- a/README.md +++ b/README.md @@ -7,6 +7,10 @@ An Erlang library for Pocket API (www.getpocket.com) v3. For more details see [d Project depends on [jiffy][3] library for JSON parsing. ``` +$ rebar3 update compile +``` +or +``` $ rebar get-deps compile ``` diff --git a/rebar.config b/rebar.config index 80f9911..c5d4e81 100644 --- a/rebar.config +++ b/rebar.config @@ -2,11 +2,7 @@ {erl_opts, [debug_info]}. -{deps, [ - {jiffy, ".*", - {git, "git://github.com/davisp/jiffy.git", {branch, "master"} - }} -]}. +{deps, [ {jiffy, "0.14.7"} ]}. {cover_enabled, true}. {cover_print_enabled, true}. diff --git a/rebar.config.script b/rebar.config.script new file mode 100644 index 0000000..440bcb6 --- /dev/null +++ b/rebar.config.script @@ -0,0 +1,12 @@ +case erlang:function_exported(rebar3, main, 1) of + true -> + %% rebar3 + CONFIG; + false -> + %% rebar 2.x or older + NewConf = lists:keystore(deps_dir, 1, CONFIG, {deps_dir, "deps"}), + Deps = [{jiffy, "0.*", + {git, "https://github.com/davisp/jiffy.git", "0.14.7"}} + ], + lists:keystore(deps, 1, NewConf, {deps, Deps}) +end. diff --git a/src/erlpocket.app.src b/src/erlpocket.app.src index c7ded86..364e56f 100755 --- a/src/erlpocket.app.src +++ b/src/erlpocket.app.src @@ -1,11 +1,13 @@ {application, erlpocket, [{description, "Erlang library for Pocket API"}, - {vsn, "0.1"}, + {vsn, "v1.2"}, {registered, []}, {applications, [stdlib, kernel ]}, - {modules, []}, {env, [{verbose, false}]} + {maintainers,["Martin Wiso"]}, + {licenses,["MIT"]}, + {links,[{"Github","https://github.com/tgrk/erlpocket"}]} ] }.