mix quality.plt (ExQuality v0.13.0)

View Source

Builds the Dialyzer PLT ahead of a mix quality run.

Dialyzer analyses against a PLT, a cache of every module it has already seen. Building one takes minutes; analysing against a warm one takes seconds. With no warm-up target, the first run on a cold checkout or a fresh CI container pays that cost inside a check whose only output is one line at the end, so the run looks hung.

This task is that target. It is the same work mix quality would otherwise do, moved somewhere it can be cached:

mix quality.plt

In a container image or a CI job, run it in its own step, after mix deps.get and before any check, and cache _build and ~/.mix (dialyxir keeps the core PLTs in Mix.Utils.mix_home/0 and the project's own under _build). The step is slow once and instant afterwards.

Output is not summarised: unlike a check, the whole point of this task is the progress, so dialyxir's own output is passed through as it arrives.

Requires :dialyxir. A project without it has no PLT to build.

Summary

Functions

Runs the PLT build.

Functions

run(args)

@spec run([String.t()]) :: :ok

Runs the PLT build.

Fails the task if dialyxir is not installed, or if the build itself failed.