Merge pull request #1205 from Nitrate/renovate/pin-dependencies #158
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Linter | |
on: | |
push: | |
branches: | |
- develop | |
- main | |
pull_request: | |
branches: | |
- develop | |
jobs: | |
linters: | |
name: Run linters | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 | |
- uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f # v5 | |
with: | |
python-version: '3.10' | |
- run: | | |
sudo apt-get update | |
sudo apt-get install -y npm | |
npm install eslint@7.1.0 | |
npm install eslint-plugin-jsdoc@30.3.0 | |
export PATH="$(pwd)/node_modules/.bin:$PATH" | |
python3 -m venv venv | |
envpy=./venv/bin/python3 | |
"$envpy" -m pip install --upgrade pip | |
"$envpy" -m pip install 'tox<4.0' | |
"$envpy" -m tox -e bandit,black,flake8,docs,doc8,isort,templatelint,jslint | |
mypy: | |
name: Run mypy-${{ matrix.django-version }} checks | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
django-version: [django420] | |
steps: | |
- run: | | |
sudo apt update | |
sudo apt-get install gcc python3-dev libkrb5-dev libmariadb-dev libcrypt-dev | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 | |
- uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f # v5 | |
with: | |
python-version: 3.11 | |
- name: Install tox | |
run: | | |
python3 -m pip install --upgrade pip | |
python3 -m pip install tox | |
- run: tox -e mypy-${{ matrix.django-version }} |