Skip to content

aumentando espaçamento #132

aumentando espaçamento

aumentando espaçamento #132

Workflow file for this run

name: Pylint
on:
push:
branches:
- main
pull_request:
jobs:
lint:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10"]
steps:
- name: Check out the repository
uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Cache pip
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r requirements.txt
- name: Run Pylint
run: |
pylint --exit-zero --output-format=text $(git ls-files 'forunb/*.py' | grep -v 'migrations/' | grep -v 'management/' | grep -v 'templatetags/') > pylint_output.txt
pylint_score=$(tail -n 2 pylint_output.txt | head -n 1 | grep -oP '\d+\.\d+')
echo "Pylint score: $pylint_score"
if (( $(echo "$pylint_score > 8" | bc -l) )); then
echo "Pylint check passed with score $pylint_score"
else
echo "Pylint check failed with score $pylint_score"
exit 1
fi