Skip to content

Commit c526302

Browse files
committed
clean
1 parent 17ee69c commit c526302

1 file changed

Lines changed: 8 additions & 5 deletions

File tree

templates/.github/workflows/ci.yaml

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ jobs:
2121
with:
2222
python-version: "3.10"
2323

24+
- name: Set shfmt version environment variable
25+
run: echo "SHFMT_VERSION=v3.7.0" >> $GITHUB_ENV
26+
2427
- name: Cache pip dependencies
2528
uses: actions/cache@v3
2629
with:
@@ -33,18 +36,18 @@ jobs:
3336
uses: actions/cache@v3
3437
with:
3538
path: /usr/local/bin/shfmt
36-
# key: ${{ runner.os }}-shfmt-${{ env.SHFMT_VERSION }}
37-
key: ${{ runner.os }}-shfmt-
39+
key: ${{ runner.os }}-shfmt-${{ env.SHFMT_VERSION }}
3840
restore-keys: |
41+
${{ runner.os }}-shfmt-${{ env.SHFMT_VERSION }}
3942
${{ runner.os }}-shfmt-
4043
4144
- name: Cache Pre-Commit environments
4245
uses: actions/cache@v3
4346
with:
4447
path: ~/.cache/pre-commit
45-
# key: ${{ runner.os }}-pc-${{ hashFiles('.pre-commit-config.yaml') }}
46-
key: ${{ runner.os }}-pc-
48+
key: ${{ runner.os }}-pc-${{ hashFiles('.pre-commit-config.yaml') }}
4749
restore-keys: |
50+
${{ runner.os }}-pc-${{ hashFiles('.pre-commit-config.yaml') }}
4851
${{ runner.os }}-pc-
4952
5053
- name: Install dependencies
@@ -54,7 +57,7 @@ jobs:
5457
5558
- name: Install shfmt
5659
run: |
57-
SHFMT_VERSION="v3.7.0"
60+
SHFMT_VERSION=${{ env.SHFMT_VERSION }}
5861
SHFMT_BIN="shfmt_${SHFMT_VERSION}_linux_amd64"
5962
if [[ ! -f /usr/local/bin/shfmt ]]; then
6063
wget -O shfmt "https://github.com/mvdan/sh/releases/download/${SHFMT_VERSION}/${SHFMT_BIN}"

0 commit comments

Comments
 (0)