AlCheck

A parallel code quality checker for Elixir projects. AlCheck runs multiple code quality checks (format, compile, credo, dialyzer, and tests) concurrently with smart test partitioning.

Features

Installation

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

def deps do
  [
    {:al_check, "~> 0.1.0"}
  ]
end

Then install globally:

mix deps.get
mix check.install
# if u use asdf
asdf reshim

Usage

CLI Usage

Run all checks:

check

Common Options

# Run only fast checks (format, compile, credo)
check --fast

# Run specific checks only
check --only format,test
check --only credo

# Run tests with custom partition count
check --partitions 4

# Run tests from specific directory
check --dir test/my_app/feature/

# Re-run only failed tests from previous run
check --failed

# Apply auto-fixes from stored credo output
check --fix

# Monitor test partition files in real-time
check --watch

Available Checks

Workflows

Failed Test Workflow

When tests fail, failed test locations are automatically saved:

check --only test     # Run tests and save failures
cat check/failed_tests.txt    # View failed tests
check --failed        # Re-run only the failed tests

Auto-fix Workflow

Credo output is stored for later use with --fix:

check --only credo    # Run checks and store output
check --fix           # Apply fixes from stored output

Test Partitioning

Tests run in parallel partitions (default: 3). Each partition uses its own database. Customize based on your CPU cores:

check --partitions 3  # Run with 3 partitions

Output Files

AlCheck creates a check/ directory with the following files:

Requirements

Documentation

Full documentation is available at https://hexdocs.pm/al_check.

License

This project is licensed under the MIT License - see the LICENSE file for details.