diff --git a/.github/workflows/pr_pre-commit.yml b/.github/workflows/pr_pre-commit.yml index 48a965b..bda5bd5 100644 --- a/.github/workflows/pr_pre-commit.yml +++ b/.github/workflows/pr_pre-commit.yml @@ -4,17 +4,22 @@ name: pre-commit on: pull_request: +permissions: {} + jobs: pre-commit: runs-on: ubuntu-latest + permissions: + contents: read strategy: matrix: python-version: ["3.11", "3.12", "3.13"] steps: - - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 with: fetch-depth: 0 + persist-credentials: false - name: Run pre-commit (Python ${{ matrix.python-version }}) - uses: stackabletech/actions/run-pre-commit@5901c3b1455488820c4be367531e07c3c3e82538 # v0.4.0 + uses: stackabletech/actions/run-pre-commit@e8aed001d347bcf693e41b61f4098b0cb94b4ab6 # v0.18.0 with: python-version: ${{ matrix.python-version }} diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 73c3a86..be80a69 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -6,14 +6,20 @@ on: tags: - '*' +permissions: {} + jobs: build: name: Package wheel runs-on: ubuntu-latest + permissions: + contents: read steps: - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 + with: + persist-credentials: false - name: Set up Python - uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5 + uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0 with: python-version: "3.13.0" - name: Install publish dependencies @@ -24,7 +30,7 @@ jobs: rm -rf dist/ python -m build --sdist --wheel . - name: Store wheel - uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 with: name: beku-stackabletech-package path: dist/ @@ -40,9 +46,9 @@ jobs: id-token: write # IMPORTANT: this permission is mandatory for trusted publishing steps: - name: Download wheel - uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8 + uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1 with: name: beku-stackabletech-package path: dist/ - name: Publish distribution 📦 to PyPI - uses: pypa/gh-action-pypi-publish@15c56dba361d8335944d31a2ecd17d700fc7bcbc # v1.12.2 + uses: pypa/gh-action-pypi-publish@dc37677b2e1c63e2034f94d8a5b11f265b73ba33 # v1.14.2 diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index ad74b2e..4fcaefe 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -3,16 +3,22 @@ name: Test on: [push] +permissions: {} + jobs: build: runs-on: ubuntu-latest + permissions: + contents: read strategy: matrix: python-version: ["3.11", "3.12", "3.13"] steps: - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 + with: + persist-credentials: false - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5 + uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0 with: python-version: ${{ matrix.python-version }} - name: Install test dependencies diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 5938cc5..56238be 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -4,7 +4,7 @@ default_language_version: repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: 2c9f875913ee60ca25ce70243dc24d5b6415598c # 4.6.0 + rev: 3e8a8703264a2f4a69428a0aa4dcb512790b2c8c # v6.0.0 hooks: - id: trailing-whitespace - id: end-of-file-fixer @@ -15,23 +15,23 @@ repos: - id: check-symlinks - repo: https://github.com/adrienverge/yamllint - rev: 81e9f98ffd059efe8aa9c1b1a42e5cce61b640c6 # 1.35.1 + rev: cba56bcde1fdd01c1deb3f945e69764c291a6530 # v1.38.0 hooks: - id: yamllint - repo: https://github.com/igorshubovych/markdownlint-cli - rev: f295829140d25717bc79368d3f966fc1f67a824f # 0.41.0 + rev: 5b5dddc4fb0f83c3ea1fc5616fa63e115dce83e0 # v0.49.1 hooks: - id: markdownlint - repo: https://github.com/koalaman/shellcheck-precommit - rev: 2491238703a5d3415bb2b7ff11388bf775372f29 # 0.10.0 + rev: 99470f5e12208ff0fb17ab81c3c494f7620a1d8d # v0.11.0 hooks: - id: shellcheck args: ["--severity=info"] - repo: https://github.com/rhysd/actionlint - rev: 62dc61a45fc95efe8c800af7a557ab0b9165d63b # 1.7.1 + rev: 914e7df21a07ef503a81201c76d2b11c789d3fca # v1.7.12 hooks: - id: actionlint