Skip to content

Commit

Permalink
Use YYYY.MM cache hash
Browse files Browse the repository at this point in the history
  • Loading branch information
kenodegard committed Aug 16, 2024
1 parent e124b04 commit 443592e
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions read-file/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,18 @@ outputs:
runs:
using: composite
steps:
- name: Hash + Timestamp
run: echo "HASH=Py3.12-$(date -u "+%Y%m")" >> $GITHUB_ENV
shell: bash

- uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
with:
path: ~/.cache/pip
# invalidate the cache anytime a workflow changes
key: ${{ hashFiles('.github/workflows/*') }}
key: read-file-${{ env.HASH }}

- uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
with:
python-version: '3.11'
python-version: '3.12'

- name: Install Dependencies
shell: bash
Expand Down

0 comments on commit 443592e

Please sign in to comment.