Skip to content

Merge pull request #5 from soltanoff/version_updates #14

Merge pull request #5 from soltanoff/version_updates

Merge pull request #5 from soltanoff/version_updates #14

Workflow file for this run

name: linters
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
with:
python-version: '3.12'
- uses: syphar/restore-virtualenv@v1
id: cache-virtualenv
- uses: syphar/restore-pip-download-cache@v1
if: steps.cache-virtualenv.outputs.cache-hit != 'true'
- name: Install dependencies
if: steps.cache-virtualenv.outputs.cache-hit != 'true'
run: |
python -m pip install --upgrade pip wheel setuptools poetry
poetry config virtualenvs.create false
poetry install --no-root --no-interaction
flake8:
runs-on: ubuntu-latest
timeout-minutes: 5
needs: [ build ]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
with:
python-version: '3.12'
- uses: syphar/restore-virtualenv@v1
id: cache-virtualenv
- name: Analysing the code with flake8
run: |
python -m flake8 .
pylint:
runs-on: ubuntu-latest
timeout-minutes: 5
needs: [ build ]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
with:
python-version: '3.12'
- uses: syphar/restore-virtualenv@v1
id: cache-virtualenv
- name: Analysing the code with pylint
run: |
python -m pylint $(git ls-files '*.py')
safety:
runs-on: ubuntu-latest
timeout-minutes: 5
needs: [ build ]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
with:
python-version: '3.12'
- uses: syphar/restore-virtualenv@v1
id: cache-virtualenv
- name: Analysing the dependencies with safety
run: |
python -m safety check
bandit:
runs-on: ubuntu-latest
timeout-minutes: 5
needs: [ build ]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
with:
python-version: '3.12'
- uses: syphar/restore-virtualenv@v1
id: cache-virtualenv
- name: Analysing the common security issues in Python code
run: |
python -m bandit -c pyproject.toml -r .