Skip to content

GitHub bot that checks PEP 8 compliance for Python files in pull requests.

License

Notifications You must be signed in to change notification settings

metahris/pep8-checker-bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pep8 Checker Bot

pep8-checker-bot is a GitHub bot that checks PEP 8 compliance for Python files in pull requests.

1. Add the Bot to your dependencies

git+https://github.com/metahris/pep8-bot-checker.git

2. Set Up GitHub Actions

Example of a Workflow file .github/workflows/pep8-check.yml:

name: PEP8 Check

on:
  pull_request:
    paths:
      - '**/*.py'  # Trigger the action only for Python files

jobs:
  check-pep8:
    runs-on: ubuntu-latest

    steps:
      - name: Checkout the repository
        uses: actions/checkout@v2

      - name: Set up Python
        uses: actions/setup-python@v2
        with:
          python-version: '3.8'  # Specify the Python version needed

      - name: Install dependencies
        run: |
          pip install -r requirements.txt

      - name: Run PEP8 Bot
        run: |
          export GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}  # GitHub automatically provides this token
          export GITHUB_REPO=${{ github.repository }}
          export PR_NUMBER=${{ github.event.pull_request.number }}
          python -m pep8_checker_bot.checker  # Runs the checker script

About

GitHub bot that checks PEP 8 compliance for Python files in pull requests.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages