Name: mix_dia_compiler
Owner: xerions
Description: Diameter source files compiler for Mix and Elixir
Created: 2016-07-06 15:46:29.0
Updated: 2017-07-07 19:00:04.0
Pushed: 2016-07-10 12:42:23.0
Size: 13
Language: Elixir
GitHub Committers
User | Most Recent Commit | # Commits |
---|
Other Committers
User | Most Recent Commit | # Commits |
---|
A Diameter source files compiler for mix. It was inspired by rebar_dia_compiler
and it should work the same way expect dia_first_files
option.
There are some unresolved questions:
Diameter sources have the inherits and it requires the correct file order. If b inherits a then a should be compiled before b. In rebar_dia_compiler it is solved by dia_first_files but it is not possible to add that kind of option to this compile so I may suggest to use alphabetic order to naming dia sources for now.
Diameter compiler generates erl and hrl file. It is possible in Elixir to work with records from hrl file but I don't know a good way to work with defined constants.
If available in Hex, the package can be installed as:
Add mix_dia_compiler to your list of dependencies in mix.exs
:
def deps do
[{:mix_dia_compiler, "~> 0.1.0"}]
end
Add :dia
to compilers:
def application do
compilers: [:dia, :erlang, :elixir, :app],
end