Skip to content
One task to efficiently run all code analysis & testing tools in an Elixir project. Born out of ❤️ to Elixir and pragmatism.
Elixir
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
lib Add tool dependency system via run_after option Aug 8, 2019
priv/enable_ansi Use --erl-config to enable ANSI, extend tests Aug 1, 2019
test Add tool dependency system via run_after option Aug 8, 2019
.check.exs Restore Elixir 1.7 testing Jul 26, 2019
.credo.exs Improve naming, docs and tests Jul 19, 2019
.formatter.exs Release 0.1.0 Jul 17, 2019
.gitignore Improvements Jul 18, 2019
.travis.yml Restore Elixir 1.7 testing Jul 26, 2019
CHANGELOG.md Add tool dependency system via run_after option Aug 8, 2019
LICENSE.md
README.md Merge branch 'master' of github.com:karolsluszniak/ex_check Aug 8, 2019
mix.exs Release 0.9.0 Aug 1, 2019
mix.lock Restore Elixir 1.7 testing Jul 26, 2019

README.md

ex_check

license build status Hex version

One task to efficiently run all code analysis & testing tools in an Elixir project.

  • Runs all tools with a single convenient mix check command
  • Comes out of the box with a predefined set of curated tools
  • Checks the project consistently for all developers & on the CI
  • Facilitates custom mix tasks and scripts acting as project checks
  • Delivers results faster by running & streaming tools in parallel
  • Identifies all project issues in one go by always running all tools
  • Supports cross-tool deps for ultimate control over check workflow
  • Takes care of the little details (compile once, enable ANSI etc)

Read more and see demo on Cloudless Studio blog.

Getting started

Add ex_check to your list of dependencies in mix.exs:

def deps do
  [
    {:ex_check, ">= 0.0.0", only: :dev, runtime: false}
  ]
end

Optionally add curated tools to your list of dependencies in mix.exs:

def deps do
  [
    {:credo, ">= 0.0.0", only: :dev, runtime: false},
    {:dialyxir, ">= 0.0.0", only: :dev, runtime: false},
    {:ex_doc, ">= 0.0.0", only: :dev, runtime: false},
    {:sobelow, ">= 0.0.0", only: :dev, runtime: false}
  ]
end

Run the check:

mix check

Optionally generate config to adjust the check:

mix check.gen.config

Documentation

Learn more about curated tools, workflow, tool execution, configuration file and command line options:

mix help check

Or read docs on HexDocs.

Continuous Integration

With mix check you can consistently run the same set of checks locally and on the CI. CI configuration also becomes trivial and comes out of the box with parallelism and error output from all checks at once regardless if previous one failed.

Here's the minimal .travis.yml to get you started on Travis CI:

language: elixir

script: mix check

If you use the dialyzer tool, you'll also want to cover PLT build timeouts and caching:

# ...

before_script:
  - travis_wait mix dialyzer --plt

cache:
  directories:
    - _build
    - deps

Changelog

See CHANGELOG.md.

License

See LICENSE.md.

You can’t perform that action at this time.