From 9059f2005abb2174482dc6190dda6640899e3c8c Mon Sep 17 00:00:00 2001 From: Thales Macedo Garitezi Date: Thu, 6 Jan 2022 10:03:07 -0300 Subject: [PATCH] fix(elixir): put Patch in version and add missing deps Elixir requires that we use version of the form `Major.Minor.Patch`. Also, Mix requires dependecies to be declared in `rebar.config` so it can include the header files correctly. --- .github/workflows/elixir_release.yml | 1 + apps/emqx/include/emqx_release.hrl | 6 +++++- apps/emqx_authn/rebar.config | 1 + apps/emqx_authz/rebar.config | 4 +++- apps/emqx_prometheus/rebar.config | 3 ++- apps/emqx_statsd/rebar.config | 4 +++- 6 files changed, 15 insertions(+), 4 deletions(-) diff --git a/.github/workflows/elixir_release.yml b/.github/workflows/elixir_release.yml index dc887efbc..9a1d672a2 100644 --- a/.github/workflows/elixir_release.yml +++ b/.github/workflows/elixir_release.yml @@ -7,6 +7,7 @@ concurrency: on: pull_request: + workflow_dispatch: jobs: build: diff --git a/apps/emqx/include/emqx_release.hrl b/apps/emqx/include/emqx_release.hrl index e4bb4a123..ce70cc172 100644 --- a/apps/emqx/include/emqx_release.hrl +++ b/apps/emqx/include/emqx_release.hrl @@ -24,4 +24,8 @@ %% NOTE: This version number should be manually bumped for each release --define(EMQX_RELEASE, "5.0-beta.3"). +%% NOTE: This version number should have 3 numeric parts +%% (Major.Minor.Patch), and extra info can be added after a final +%% hyphen. + +-define(EMQX_RELEASE, "5.0.0-beta.3"). diff --git a/apps/emqx_authn/rebar.config b/apps/emqx_authn/rebar.config index 3def1d00e..582b92c0b 100644 --- a/apps/emqx_authn/rebar.config +++ b/apps/emqx_authn/rebar.config @@ -1,4 +1,5 @@ {deps, [ {emqx, {path, "../emqx"}} + , {emqx_connector, {path, "../emqx_connector"}} ]}. {edoc_opts, [{preprocess, true}]}. diff --git a/apps/emqx_authz/rebar.config b/apps/emqx_authz/rebar.config index b1479d434..fc8329542 100644 --- a/apps/emqx_authz/rebar.config +++ b/apps/emqx_authz/rebar.config @@ -1,5 +1,7 @@ {erl_opts, [debug_info, nowarn_unused_import]}. -{deps, [{emqx, {path, "../emqx"}}]}. +{deps, [ {emqx, {path, "../emqx"}} + , {emqx_connector, {path, "../emqx_connector"}} + ]}. {shell, [ % {config, "config/sys.config"}, diff --git a/apps/emqx_prometheus/rebar.config b/apps/emqx_prometheus/rebar.config index 9cd506995..61e2662bf 100644 --- a/apps/emqx_prometheus/rebar.config +++ b/apps/emqx_prometheus/rebar.config @@ -1,5 +1,6 @@ {deps, - [ %% FIXME: tag this as v3.1.3 + [ {emqx, {path, "../emqx"}}, + %% FIXME: tag this as v3.1.3 {prometheus, {git, "https://github.com/emqx/prometheus.erl", {ref, "9994c76adca40d91a2545102230ccce2423fd8a7"}}}, {hocon, {git, "https://github.com/emqx/hocon.git", {tag, "0.22.2"}}}, {minirest, {git, "https://github.com/emqx/minirest", {tag, "1.2.9"}}} diff --git a/apps/emqx_statsd/rebar.config b/apps/emqx_statsd/rebar.config index e997b1577..d54b3e25f 100644 --- a/apps/emqx_statsd/rebar.config +++ b/apps/emqx_statsd/rebar.config @@ -1,5 +1,7 @@ {erl_opts, [debug_info]}. -{deps, [{estatsd, {git, "https://github.com/emqx/estatsd", {tag, "0.1.0"}}}]}. +{deps, [ {emqx, {path, "../emqx"}} + , {estatsd, {git, "https://github.com/emqx/estatsd", {tag, "0.1.0"}}} + ]}. {shell, [ % {config, "config/sys.config"},