It’s time to introduce metacredo — the tool heavily inspired by Credo, but running on MetaAST.
MetaCredo operates on the MetaAST representation provided by Metastatic. Source files are parsed into a language-agnostic AST using Metastatic’s adapters (Elixir, Erlang, Ruby, Python, Haskell), and then checks pattern-match against the uniform
{type, keyword_meta, children}node structure. This means every check is cross-language by default.
Metacredo technically supports all the languages, supported by Metastatic. Currently it means Elixir/Erlang, Ruby to some extent, and Haskell/Python as a PoC. Once the first class support for non-beam languages landed on Metastatic, this library would [theoretically] work out of the box.
This version is a minimal viable product. It works, but it produces many not-so-true positives and I would not recommend to use it with production-grade systems (use oeditus_credo which is still fully supported instead.)
What I really need now, is a discussion on chosen design, chosen checks, chosen approach.
Screenshots:
① mix metacredo checks on metacredo itself
② Explaining one of the warnings above
Enjoy.
























