Skip to content

Merge pull request #545 from Svenito/only-modified-files #959

Merge pull request #545 from Svenito/only-modified-files

Merge pull request #545 from Svenito/only-modified-files #959

Workflow file for this run

---
name: pyupgrade
on: push # yamllint disable-line rule:truthy
jobs:
pyupgrade:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- run: pip install pyupgrade
- name: Ensure modern Python style using pyupgrade
# This script is written in a Linux / macos / windows portable way
run: |
python -c "
import sys
from pyupgrade._main import main
from glob import glob
files = glob('**/*.py', recursive=True)
sys.exit(main(files + ['--py38-plus']))
" || ( git diff ; false )