Skip to content

Commit

Permalink
Create main.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
AshwinSri23 authored Jan 8, 2025
1 parent 4d20995 commit 0192552
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Lint Flask Server

on:
push:
branches:
- main
pull_request:

jobs:
lint-python:
runs-on: ubuntu-latest

steps:
# Step 1: Check out the repository
- name: Checkout code
uses: actions/checkout@v3

# Step 2: Set up Python environment
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.9' # Adjust to match your Python version

# Step 3: Install flake8 (or another linter of your choice)
- name: Install flake8
run: |
python -m pip install --upgrade pip
pip install flake8
# Step 4: Run flake8 on the Flask server file
- name: Run flake8 on server.py
run: |
flake8 server/server.py --count --select=E9,F63,F7,F82 --show-source --statistics

0 comments on commit 0192552

Please sign in to comment.