Skip to content

Commit

Permalink
Merge pull request #28 from unb-mds/task/add-linter
Browse files Browse the repository at this point in the history
task(.github): Adicionar linter básico para projeto.
  • Loading branch information
EnzoEmir authored Jan 31, 2025
2 parents 22146a9 + 93900c5 commit c2d7f27
Show file tree
Hide file tree
Showing 3 changed files with 67 additions and 1 deletion.
31 changes: 31 additions & 0 deletions .github/workflows/lint-critical.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Lint Critical Status
on:
workflow_dispatch:
push:
branches:
- main
- task/add-linter
pull_request:
branches:
- main


jobs:
lint-critical:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.12.6

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8
- name: Run Flake8
run: |
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
30 changes: 30 additions & 0 deletions .github/workflows/lint-style.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Lint Style Check

on:
push:
branches:
- main
- task/add-linter
pull_request:
branches:
- main

jobs:
lint-style:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.12.6

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8
- name: Run Flake8 (Style)
run: |
flake8 . --exclude=migrations,__pycache__,.venv --show-source --statistics
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
# 📚 2024-2-Squad04 📚 <!-- omit from toc -->
# 📚AGIO📚
<!-- ###### Aplicação de Gestão de Inventário Otimizada -->
![Lint Critical Status](https://github.com/unb-mds/2024-2-Agio/actions/workflows/lint-critical.yml/badge.svg)
![Lint Style Status](https://github.com/unb-mds/2024-2-Agio/actions/workflows/lint-style.yml/badge.svg)

<br>

## 2024-2-Squad04

## ***Sumário*** <!-- omit from toc -->
- [1. Descrição 💡](#1-descrição-)
- [2. Pré-requisitos 📋](#2-pré-requisitos-)
Expand Down

0 comments on commit c2d7f27

Please sign in to comment.