Skip to content

Commit

Permalink
First attempt to add depdendency cache
Browse files Browse the repository at this point in the history
  • Loading branch information
shaunagm committed Jul 31, 2023
1 parent fd922b1 commit 876e08b
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
12 changes: 12 additions & 0 deletions .github/workflows/test-linux-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@ jobs:
matrix:
python-version: ['3.8', '3.9', '3.10']
os: [ubuntu-latest, windows-latest]
include:
- os: ubuntu-latest
path: ~/.cache/pip
- os: windows-latest
path: ~\AppData\Local\pip\Cache
runs-on: ${{ matrix.os }}

steps:
Expand All @@ -25,6 +30,13 @@ jobs:
with:
python-version: ${{ matrix.python-version }}

- uses: actions/cache@v3
with:
path: ${{ matrix.path }}
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Install dependencies
run: python -m pip install -r requirements.txt

Expand Down
7 changes: 7 additions & 0 deletions .github/workflows/tests-mac.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,13 @@ jobs:
with:
python-version: 3.8

- uses: actions/cache@v3
with:
path: ~/Library/Caches/pip
key: mac-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
mac-pip-
- name: Install dependencies
run: python -m pip install -r requirements.txt

Expand Down

0 comments on commit 876e08b

Please sign in to comment.