diff --git a/.github/workflows/python.yml b/.github/workflows/python.yml index 3007b77..c5fc677 100644 --- a/.github/workflows/python.yml +++ b/.github/workflows/python.yml @@ -8,20 +8,6 @@ defaults: shell: bash -l {0} jobs: - Lint: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - name: Set up Python - uses: actions/setup-python@v4 - with: - python-version: 3.11 - - name: Lint with Ruff - run: | - pip install ruff - ruff --output-format=github --target-version=py39 . - continue-on-error: true - Build: runs-on: ubuntu-latest steps: @@ -41,7 +27,7 @@ jobs: run: | python -m build pip install dist/*.whl - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: path: ./dist/* @@ -52,19 +38,19 @@ jobs: python-version: ["3.9", "3.10", "3.11"] os: [ubuntu-latest, windows-latest, macos-latest] exclude: - - os: windows-latest - python-version: "3.10" - - os: windows-latest - python-version: "3.11" - - os: macos-latest - python-version: "3.10" - - os: macos-latest - python-version: "3.11" + - os: windows-latest + python-version: "3.10" + - os: windows-latest + python-version: "3.11" + - os: macos-latest + python-version: "3.10" + - os: macos-latest + python-version: "3.11" runs-on: ${{ matrix.os }} # runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: name: artifact path: dist @@ -98,7 +84,7 @@ jobs: permissions: id-token: write steps: - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: name: artifact path: dist diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 70b9c85..342412d 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,21 +1,16 @@ -repos: +ci: + autoupdate_schedule: quarterly -# Automatic source code formatting -- repo: https://github.com/psf/black - rev: 23.9.1 +repos: +- repo: https://github.com/astral-sh/ruff-pre-commit + rev: v0.9.2 hooks: - - id: black - args: [--safe, --quiet] + - id: ruff + args: [--fix, --exit-non-zero-on-fix, --show-fixes] + - id: ruff-format -# Syntax check and some basic - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.4.0 + rev: v5.0.0 hooks: - id: check-ast -- repo: https://github.com/charliermarsh/ruff-pre-commit - rev: v0.0.291 - hooks: - - id: ruff - args: ["--fix", "--show-fixes"] -