File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed
Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change 3333 defaults :
3434 run :
3535 shell : bash
36+ env :
37+ SF_CLI_VERSION : ${{ vars.SF_CLI_VERSION || 'latest' }}
3638 steps :
39+ - name : Compute cache key (sf CLI)
40+ id : cachekey
41+ run : |
42+ if [ $SF_CLI_VERSION = "latest" ]; then
43+ # Rotate weekly; change to +%Y-%m for monthly
44+ echo "suffix=$(date +%Y-%V)" >> "$GITHUB_OUTPUT"
45+ else
46+ echo "suffix=static" >> "$GITHUB_OUTPUT"
47+ fi
48+
49+ - name : Cache npm (sf CLI)
50+ uses : actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9
51+ with :
52+ path : ~/.npm
53+ key : npm-${{ runner.os }}-sf-cli-$SF_CLI_VERSION-${{ steps.cachekey.outputs.suffix }}
54+
3755 - name : Install SF CLI
3856 uses : navikt/sf-platform/.github/actions/installSfCli@eb5b379e3b162280de8f5b9566cb41c25f0832f5
3957 with :
You can’t perform that action at this time.
0 commit comments