From 4ed50015bff642b92984b23899779acb47a24f9f Mon Sep 17 00:00:00 2001 From: Mark Beacom <7315957+mbeacom@users.noreply.github.com> Date: Wed, 6 Mar 2024 23:42:45 -0500 Subject: [PATCH] feat: Adjust GH Action pins to use SHAs (#122) --- .github/actions/deps/action.yml | 6 +++--- .github/workflows/pre-commit.yaml | 6 +++--- .github/workflows/publish.yaml | 4 ++-- .github/workflows/scorecard.yml | 2 +- .github/workflows/validate.yaml | 8 ++++---- 5 files changed, 13 insertions(+), 13 deletions(-) diff --git a/.github/actions/deps/action.yml b/.github/actions/deps/action.yml index 4f6c375..cfafb1d 100644 --- a/.github/actions/deps/action.yml +++ b/.github/actions/deps/action.yml @@ -10,13 +10,13 @@ runs: using: "composite" steps: - name: Setup Python - uses: actions/setup-python@v5 + uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # v5.0.0 with: python-version: '${{ inputs.python-version }}' - name: Cache Poetry id: cache-poetry - uses: actions/cache@v4 + uses: actions/cache@ab5e6d0c87105b4c9c2047343972218f562e4319 # v4.0.1 with: path: ${{github.workspace}}/.poetry key: poetry-self-${{ hashFiles('.github/workflows/*.yml') }} @@ -43,7 +43,7 @@ runs: - name: Cache Dependencies id: cache-deps - uses: actions/cache@v4 + uses: actions/cache@ab5e6d0c87105b4c9c2047343972218f562e4319 # v4.0.1 with: path: ${{github.workspace}}/.venv key: poetry-deps-${{ hashFiles('**/poetry.lock') }} diff --git a/.github/workflows/pre-commit.yaml b/.github/workflows/pre-commit.yaml index 7c56884..856d931 100644 --- a/.github/workflows/pre-commit.yaml +++ b/.github/workflows/pre-commit.yaml @@ -14,17 +14,17 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout Source - uses: actions/checkout@v4 + uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 - name: Setup Dependencies uses: './.github/actions/deps' with: python-version: '3.11' - name: Install MDL run: echo $'source \'https://rubygems.org\'\ngem \'mdl\', \'~> 0.12.0\'' > Gemfile - - uses: ruby/setup-ruby@v1 + - uses: ruby/setup-ruby@d4526a55538b775af234ba4af27118ed6f8f6677 # v1.172.0 with: ruby-version: '3.2' # Not needed with a .ruby-version file bundler-cache: true # runs 'bundle install' and caches installed gems automatically - name: Install Pre-commit dependencies run: poetry run poe install - - uses: pre-commit/action@v3.0.0 + - uses: pre-commit/action@2c7b3805fd2a0fd8c1884dcaebf91fc102a13ecd # v3.0.1 diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index 547e35a..b398b5e 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -15,7 +15,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout Source - uses: actions/checkout@v4 + uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 with: fetch-depth: 0 @@ -46,7 +46,7 @@ jobs: POETRY_PYPI_TOKEN_PYPI: ${{ secrets.POETRY_PYPI_TOKEN_PYPI }} - name: Release - uses: softprops/action-gh-release@v1 + uses: softprops/action-gh-release@de2c0eb89ae2a093876385947365aca7b0e5f844 # v1 with: discussion_category_name: announcements generate_release_notes: true diff --git a/.github/workflows/scorecard.yml b/.github/workflows/scorecard.yml index 2ffa378..4744eb1 100644 --- a/.github/workflows/scorecard.yml +++ b/.github/workflows/scorecard.yml @@ -32,7 +32,7 @@ jobs: steps: - name: "Checkout code" - uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # v3.1.0 + uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 with: persist-credentials: false diff --git a/.github/workflows/validate.yaml b/.github/workflows/validate.yaml index a34f078..34ab8d1 100644 --- a/.github/workflows/validate.yaml +++ b/.github/workflows/validate.yaml @@ -14,7 +14,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout Source - uses: actions/checkout@v4 + uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 - name: Setup Dependencies uses: './.github/actions/deps' with: @@ -37,7 +37,7 @@ jobs: runs-on: ${{ matrix.os }} steps: - name: Checkout Source - uses: actions/checkout@v4 + uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 - name: Setup Dependencies uses: './.github/actions/deps' with: @@ -48,7 +48,7 @@ jobs: run: poetry run poe test - name: Codecov - uses: codecov/codecov-action@v4 + uses: codecov/codecov-action@54bcd8715eee62d40e33596ef5e8f0f48dbbccab # v4.1.0 with: token: ${{ secrets.CODECOV_TOKEN }} @@ -57,7 +57,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout Source - uses: actions/checkout@v4 + uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 - name: Setup Dependencies uses: './.github/actions/deps' with: