Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Utiliza ruff para qualidade de código #309

Merged
merged 2 commits into from
Nov 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@ jobs:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
pip install Flake8-pyproject
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install flake8 pytest
pip install ruff pytest
- name: Lint
run: flake8 . --count --show-source --statistics
run: ruff check --output-format=github .
- name: Tests
run: pytest -v
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,13 @@ Testes
python -m unittest
```

Lint
-----------

Instalação: `pip install ruff`
Checar lint: `ruff check .`
Formatar: `ruff format .`


Documentação
-----------
Expand Down
8 changes: 4 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
[build-system]
requires = ["setuptools>=42"]
build-backend = "setuptools.build_meta"
[tool.flake8]
per-file-ignores = [
'/pynfe/entidades/__init__.py:F401'
[tool.ruff]
exclude = [
'pynfe/entidades/__init__.py'
]
max-line-length = 100
line-length = 100
Loading