Using Elixir dependencies in Erlang (umbrella) apps

Leonard B leonard.boyce@REDACTED
Fri May 1 14:11:45 CEST 2020


Hi Marc,

We're using Elixir deps in umbrella apps for a couple of years.
There may be better approaches now.

Small slice from rebar.config which may help

{deps, [...,
          {ua_inspector, {elixir, "ua_inspector",
                        {git, "URL",
                         {branch, "BRANCH"}}}},
          ....]}.
 {plugins, [
     rebar3_hex,
    { provider_asn1, "0.2.0"},
    {rebar3_elixir_compile, ".*", {git,
"https://github.com/loucash/rebar3_elixir_compile.git", {branch,
"master"}}}
 ]}.

{provider_hooks, [
  {pre, [{compile, {ex, compile}}]}
]}.

{elixir_opts, [{env, dev}]}.

{relx, [{release, {"RELNAME", "VERSION"}, [MODS]},
          {lib_dirs,
["_elixir_build/ua_inspector/_build/dev/lib/ua_inspector/"]},
          ....]}.


On Fri, May 1, 2020 at 5:59 AM Marc Worrell <marc@REDACTED> wrote:
>
> Hi,
>
> We are investigating if it is possible to use Elixir apps in Erlang projects.
>
> There are a couple of rebar3 plugins that aim to make this possible:
>
> https://hex.pm/packages/rebar3_elixir_plugin
>
> https://hex.pm/packages/rebar3_elixirc
>
> https://hex.pm/packages/rebar3_elixir_compile
>
> Has anybody any experience using these plugins?
>
> We have an umbrella Erlang app and would like to be able to
> use some Elixir libraries that don’t have good Erlang equivalents.
>
> Might also be an option to turn our Erlang umbrella app into an Elixir
> umbrella app, anybody having experience with that? The top level Erlang
> source code is next to nothing.
>
> Cheers,
>
> Marc


More information about the erlang-questions mailing list