diameterc(1)

✨ NAME ✨

okay so bestie, this is diameterc(1) β€” the Erlang module definition girlies' fave little compiler. Her whole job? Compile a diameter dictionary to Erlang source. That's it. That's the gig. πŸ’…


πŸŽ€ SYNOPSIS πŸŽ€

diameterc [<options>] <file>

πŸ¦‹ DESCRIPTION πŸ¦‹

So the diameterc utility is what you use to compile a diameter dictionary file into Erlang source. The resulting source implements the interface diameter needs to encode and decode the dictionary's messages and AVPs. Slay.

Also, heads up: the module diameter_make provides an alternate compilation interface. Two roads, same destination, pick your fighter. ✨


πŸ’– USAGE πŸ’–

Compile a single dictionary file to Erlang source. The valid options are as follows, and yes we're going through every single one, no skips. πŸ‘‘

  • -i <dir> β€” Prepend the specified directory to the code path. Use this to point at beam files compiled from inherited dictionaries β€” like, @inherits in a dictionary file creates a beam dependency, not an erl/hrl dependency. Just so you know.

You can specify multiple -i options. Stack 'em up. 🫢

  • -o <dir> β€” Write the generated source to the specified directory. Defaults to the current working directory.
  • -E β€” Suppress .erl file generation. No .erl for you. πŸ™ˆ
  • -H β€” Suppress .hrl file generation. Similarly, no .hrl. πŸ’€
  • --name <name> β€” Name the output module. Give her a name, she deserves one. ⭐
  • --prefix <prefix> β€” Transform the input dictionary before compilation, setting @name or @prefix to the specified string.
  • --inherits <arg> β€” Transform the input dictionary before compilation, appending @inherits of the specified string.

Two forms of --inherits have special meaning:

  1. --inherits -
  2. --inherits Prev/Mod

The first one has the effect of clearing any previous inherits. The second one replaces a previous inherits of Prev to one of Mod. Which like β€” iconic behaviour, because it lets you change the semantics of the input dictionary without modifying the file itself. No touchy the file. 🧚

Multiple --inherits options can be specified.

  • --indirect-inherits β€” Enables the indirect inherits feature, see more here.

πŸ’œ EXIT STATUS πŸ’œ

Returns 0 on success, non-zero on failure. Simple as that, bestie. πŸ“


🌈 SEE ALSO 🌈


and that's the whole thing!! πŸ’– go forth and compile, you absolute main character. this was Ericsson AB's diameterc, from diameter 2.7.2 β€” ty for coming to my ted talk, mwah πŸŽ€βœ¨πŸ‘‘

πŸ“¦ where this page comes from