Skip to content

Commit 2d15608

Browse files
authored
Github Action updates (#246)
* Replace deprecated set-output commands * Add check-latest true * Reset cache version
1 parent e83aeb9 commit 2d15608

File tree

1 file changed

+12
-7
lines changed

1 file changed

+12
-7
lines changed

.github/workflows/ci.yaml

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88
pull_request: ~
99

1010
env:
11-
CACHE_VERSION: 4
11+
CACHE_VERSION: 1
1212
DEFAULT_PYTHON: 3.8
1313
LIB_FOLDER: python_typing_update
1414
PRE_COMMIT_CACHE: ~/.cache/pre-commit
@@ -29,12 +29,13 @@ jobs:
2929
uses: actions/[email protected]
3030
with:
3131
python-version: ${{ env.DEFAULT_PYTHON }}
32+
check-latest: true
3233
- name: Generate partial Python venv restore key
3334
id: generate-python-key
3435
run: >-
35-
echo "::set-output name=key::base-venv-${{ env.CACHE_VERSION }}-${{
36+
echo "key=base-venv-${{ env.CACHE_VERSION }}-${{
3637
hashFiles('requirements.txt', 'requirements_test.txt',
37-
'requirements_test_pre_commit.txt') }}"
38+
'requirements_test_pre_commit.txt') }}" >> $GITHUB_OUTPUT
3839
- name: Restore Python virtual environment
3940
id: cache-venv
4041
uses: actions/[email protected]
@@ -54,8 +55,8 @@ jobs:
5455
- name: Generate pre-commit restore key
5556
id: generate-pre-commit-key
5657
run: >-
57-
echo "::set-output name=key::pre-commit-${{ env.CACHE_VERSION }}-${{
58-
hashFiles('.pre-commit-config.yaml') }}"
58+
echo "key=pre-commit-${{ env.CACHE_VERSION }}-${{
59+
hashFiles('.pre-commit-config.yaml') }}" >> $GITHUB_OUTPUT
5960
- name: Restore pre-commit environment
6061
id: cache-precommit
6162
uses: actions/[email protected]
@@ -81,6 +82,7 @@ jobs:
8182
uses: actions/[email protected]
8283
with:
8384
python-version: ${{ env.DEFAULT_PYTHON }}
85+
check-latest: true
8486
- name: Restore Python virtual environment
8587
id: cache-venv
8688
uses: actions/[email protected]
@@ -121,6 +123,7 @@ jobs:
121123
uses: actions/[email protected]
122124
with:
123125
python-version: ${{ env.DEFAULT_PYTHON }}
126+
check-latest: true
124127
- name: Restore Python virtual environment
125128
id: cache-venv
126129
uses: actions/[email protected]
@@ -150,6 +153,7 @@ jobs:
150153
uses: actions/[email protected]
151154
with:
152155
python-version: ${{ env.DEFAULT_PYTHON }}
156+
check-latest: true
153157
- name: Restore Python virtual environment
154158
id: cache-venv
155159
uses: actions/[email protected]
@@ -184,12 +188,13 @@ jobs:
184188
uses: actions/[email protected]
185189
with:
186190
python-version: ${{ matrix.python-version }}
191+
check-latest: true
187192
- name: Generate partial Python venv restore key
188193
id: generate-python-key
189194
run: >-
190-
echo "::set-output name=key::venv-${{ env.CACHE_VERSION }}-${{
195+
echo "key=venv-${{ env.CACHE_VERSION }}-${{
191196
hashFiles('requirements.txt', 'requirements_test.txt',
192-
'requirements_test_pre_commit.txt') }}"
197+
'requirements_test_pre_commit.txt') }}" >> $GITHUB_OUTPUT
193198
- name: Restore Python virtual environment
194199
id: cache-venv
195200
uses: actions/[email protected]

0 commit comments

Comments
 (0)