diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 22e9731..1119bdf 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -23,9 +23,29 @@ jobs: fetch-depth: 0 - name: Set up pnpm - uses: pnpm/action-setup@v2 + uses: pnpm/action-setup@v4 with: version: latest + run_install: false + + - name: Install Node.js + uses: actions/setup-node@v4 + with: + node-version: 20 + cache: 'pnpm' + + - name: Get pnpm store directory + shell: bash + run: | + echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + + - uses: actions/cache@v4 + name: Setup pnpm cache + with: + path: ${{ env.STORE_PATH }} + key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + restore-keys: | + ${{ runner.os }}-pnpm-store- - name: Deploy Storybook uses: bitovi/github-actions-storybook-to-github-pages@v1.0.2