Skip to content

Commit 898bdcf

Browse files
committed
Use built-in cache option in python setup action
1 parent 80b9918 commit 898bdcf

3 files changed

Lines changed: 3 additions & 30 deletions

File tree

.github/workflows/documentation.yml

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -29,16 +29,7 @@ jobs:
2929
uses: actions/setup-python@v3
3030
with:
3131
python-version: "3.9"
32-
33-
- name: Cache project dependencies (pip)
34-
uses: actions/cache@v2
35-
with:
36-
path: ~/.cache/pip # This path is specific to Ubuntu
37-
# Look to see if there is a cache hit for the corresponding requirements file
38-
key: ${{ runner.os }}-pip-${{ hashFiles('requirements/*.txt') }}
39-
restore-keys: |
40-
${{ runner.os }}-pip-
41-
${{ runner.os }}-
32+
cache: "pip"
4233

4334
- name: Install dependencies
4435
run: |

.github/workflows/lint-and-tests.yml

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -31,16 +31,7 @@ jobs:
3131
uses: actions/setup-python@v3
3232
with:
3333
python-version: ${{ matrix.python-version }}
34-
35-
- name: Cache project dependencies (pip)
36-
uses: actions/cache@v2
37-
with:
38-
path: ~/.cache/pip # This path is specific to Ubuntu
39-
# Look to see if there is a cache hit for the corresponding requirements file
40-
key: ${{ runner.os }}-pip-${{ hashFiles('requirements/*.txt') }}
41-
restore-keys: |
42-
${{ runner.os }}-pip-
43-
${{ runner.os }}-
34+
cache: "pip"
4435

4536
- name: Install dependencies
4637
run: |

.github/workflows/release.yml

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -18,16 +18,7 @@ jobs:
1818
uses: actions/setup-python@v3
1919
with:
2020
python-version: "3.x"
21-
22-
- name: Cache pip
23-
uses: actions/cache@v2
24-
with:
25-
path: ~/.cache/pip # This path is specific to Ubuntu
26-
# Look to see if there is a cache hit for the corresponding requirements file
27-
key: ${{ runner.os }}-pip-${{ hashFiles('requirements/*') }}
28-
restore-keys: |
29-
${{ runner.os }}-pip-
30-
${{ runner.os }}-
21+
cache: "pip"
3122

3223
- name: Install dependencies
3324
run: |

0 commit comments

Comments
 (0)