#!/bin/bash

# Checks the Python linter. Mirrors the "Python: Check linter" CI step.

set -e

if [[ -z "$PROJECT_ROOT" ]]; then
    echo "\$PROJECT_ROOT must be set" 1>&2
    exit 1
fi
if [[ -z "$VENV_DIR" ]]; then
    echo "\$VENV_DIR must be set (source env.sh first)" 1>&2
    exit 1
fi

cd "$PROJECT_ROOT"

flake8
