From: Sebastián Ramírez Date: Thu, 15 Aug 2024 00:34:46 +0000 (-0500) Subject: 👷 Add cache for pre-commit hooks X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=d86ba58c16746b8e3b84d4353d12078685df8c61;p=thirdparty%2Ffastapi%2Ffastapi.git 👷 Add cache for pre-commit hooks --- diff --git a/.github/workflows/autofix.yml b/.github/workflows/autofix.yml index 31a009c27d..7f0c773345 100644 --- a/.github/workflows/autofix.yml +++ b/.github/workflows/autofix.yml @@ -31,6 +31,11 @@ jobs: - name: Get changed files id: changed-files uses: tj-actions/changed-files@v44 + - uses: actions/cache@v4 + id: pre-commit-hooks-cache + with: + path: ~/.cache/pre-commit + key: ${{ runner.os }}-pre-commit-hooks-${{ hashFiles('.pre-commit-config.yml') }}-v01 - run: pre-commit run ${{ steps.changed-files.outputs.all_changed_files }} # Allow debugging with tmate - name: Setup tmate session