Skip to content

CI

CI #16

Workflow file for this run

name: CI
on:
pull_request:
workflow_dispatch:
defaults:
run:
shell: bash
jobs:
lint:
name: CI
runs-on: ubuntu-latest
permissions:
contents: read
packages: read
statuses: write
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Lint
uses: azohra/shell-linter@latest
with:
exclude-paths: LICENSE, Python
- name: Setup Python
uses: actions/[email protected]
with:
python-version: "3.10"
- name: Get changed Python directories
id: dirs
run: |
set -e
set -o pipefail
echo "::set-output name=dirs::$(git diff --name-only origin/master | grep '\.py$' | xargs -n1 dirname | sort -u)"
- name: Setup Poetry and install dependencies
run: |
set -e
for dir in ${{ steps.dirs.outputs.dirs }}; do
cd $dir
poetry install --no-interaction --no-root
poetry run pylint *.py
cd -
done