Skip to content

Commit

Permalink
ci: update global python (#3)
Browse files Browse the repository at this point in the history
  • Loading branch information
LizardByte-bot authored Oct 16, 2023
1 parent eb4a71d commit 3a56361
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .flake8
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
[flake8]
filename =
*.py,
*.pys
max-line-length = 120
extend-exclude =
venv/
38 changes: 38 additions & 0 deletions .github/workflows/python-flake8.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
---
# This action is centrally managed in https://github.com/<organization>/.github/
# Don't make changes to this file in this repo as they will be overwritten with changes made to the same file in
# the above-mentioned repo.

# Lint python files with flake8.

name: flake8

on:
pull_request:
branches: [master, nightly]
types: [opened, synchronize, reopened]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
flake8:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v4 # https://github.com/actions/setup-python
with:
python-version: '3.10'

- name: Install dependencies
run: |
# pin flake8 before v6.0.0 due to removal of support for type comments (required for Python 2.7 type hints)
python -m pip install --upgrade pip setuptools "flake8<6"
- name: Test with flake8
run: |
python -m flake8 --verbose

0 comments on commit 3a56361

Please sign in to comment.