Ivan Gabriele
Ivan Gabriele

Reputation: 6900

Is there a way to make Dialyzer watch code changes?

I'm using dialyxir which appends a dialyzer task to Mix. But it doesn't seem to have any --watch option that would rerun the type checking on file changes.

Is there a CLI way to achieve that?

Upvotes: 3

Views: 209

Answers (2)

David MacCallum
David MacCallum

Reputation: 221

Essentially the same as the accepted answer but with more detail:

fswatch -o lib | xargs -n1 -I{} mix dialyzer

Upvotes: 2

Aleksei Matiushkin
Aleksei Matiushkin

Reputation: 121000

Why do you expect the static code analysis tool to be watching the filesystem? There is an explicit tool for that, named fswatch.

You might execute whatever you want, including mix dialyzer as shown in usage section.

Upvotes: 4

Related Questions