diff --git a/.github/workflows/pre-ci.yml b/.github/workflows/pre-ci.yml index bf8b91f306..07a8a21e5f 100644 --- a/.github/workflows/pre-ci.yml +++ b/.github/workflows/pre-ci.yml @@ -18,9 +18,13 @@ jobs: uses: actions/setup-python@v5 with: python-version: "3.8" + cache: "pip" - name: Install pre-commit - run: pip install pre-commit==3.2.2 - + run: python -m pip install -r pre-commit-requirements.txt + - uses: actions/cache@v4 + with: + path: ~/.cache/pre-commit/ + key: pre-commit-3|${{ env.pythonLocation }}|${{ hashFiles('.pre-commit-config.yaml') }} - name: Run pre-commit run: SKIP=trufflehog pre-commit run --all-files --verbose diff --git a/pre-commit-requirements.txt b/pre-commit-requirements.txt new file mode 100644 index 0000000000..5cac84d3cd --- /dev/null +++ b/pre-commit-requirements.txt @@ -0,0 +1 @@ +pre-commit==3.2.2 \ No newline at end of file