Skip to content

Commit

Permalink
fix(pnpm): use cache from setup-node
Browse files Browse the repository at this point in the history
  • Loading branch information
EdieLemoine committed Aug 11, 2022
1 parent 1442894 commit 8b08513
Showing 1 changed file with 3 additions and 16 deletions.
19 changes: 3 additions & 16 deletions pnpm-install/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,28 +22,15 @@ runs:
steps:
- uses: actions/checkout@v3

- uses: actions/setup-node@v3
with:
node-version: ${{ inputs.node-version }}

- uses: pnpm/action-setup@v2.2.2
with:
version: ${{ inputs.pnpm-version }}
run_install: false

- name: 'Get pnpm store directory'
id: pnpm-cache
shell: bash
run: |
echo "::set-output name=dir::$(pnpm store path)"
- name: 'Prepare pnpm cache'
uses: actions/cache@v3
- uses: actions/setup-node@v3
with:
path: ${{ steps.pnpm-cache.outputs.dir }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
node-version: ${{ inputs.node-version }}
cache: 'pnpm'

- name: 'Install pnpm dependencies'
shell: bash
Expand Down

0 comments on commit 8b08513

Please sign in to comment.