From e3cb02750f38c48dcaad8f457bc4a438ee761e7a Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com> Date: Tue, 26 Nov 2024 18:55:35 +0200 Subject: [PATCH] Use pre-commit-uv and fix zizmor --- .github/workflows/lint.yml | 11 ++++++++--- .github/workflows/release.yml | 12 ++++++++---- 2 files changed, 16 insertions(+), 7 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 477218a..e535eb6 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -2,6 +2,9 @@ name: Lint on: [push, pull_request, workflow_dispatch] +env: + FORCE_COLOR: 1 + permissions: contents: read @@ -10,8 +13,10 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + with: + persist-credentials: false + - uses: actions/setup-python@v5 with: python-version: "3.x" - - uses: pre-commit/action@v3.0.0 + - uses: tox-dev/action-pre-commit-uv@v1 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 9d57cc5..bad5302 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,10 +1,13 @@ +name: Create release + on: push: # Sequence of patterns matched against refs/tags tags: - '[0-9]+\.[0-9]+' -name: Create release +env: + FORCE_COLOR: 1 jobs: build: @@ -12,14 +15,15 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout code - uses: actions/checkout@v3 - + uses: actions/checkout@v4 + with: + persist-credentials: false - name: Get the version id: get_version if: startsWith(github.ref, 'refs/tags/') run: echo "VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT - name: Create release - uses: softprops/action-gh-release@v1 + uses: softprops/action-gh-release@v2 with: name: Release ${{ steps.get_version.outputs.VERSION }}