From 89e653edd52fe2efb325d3f35342f4bac53495a9 Mon Sep 17 00:00:00 2001 From: lukasIO Date: Tue, 14 Nov 2023 17:25:38 +0200 Subject: [PATCH] simplify workflows --- .github/workflows/publish-template-sdk.yaml | 19 ++----------------- .github/workflows/test-template.yaml | 19 ++----------------- 2 files changed, 4 insertions(+), 34 deletions(-) diff --git a/.github/workflows/publish-template-sdk.yaml b/.github/workflows/publish-template-sdk.yaml index d4ddfbc5..7b8a8fdc 100644 --- a/.github/workflows/publish-template-sdk.yaml +++ b/.github/workflows/publish-template-sdk.yaml @@ -33,23 +33,8 @@ jobs: uses: actions/setup-node@v4 with: node-version: 18 - - name: Get pnpm store directory - shell: bash - run: | - echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV - - uses: actions/cache@v3 - name: Setup pnpm cache - timeout-minutes: 5 - continue-on-error: true - with: - path: | - ${{ env.STORE_PATH }} - ~/go/pkg/mod - ~/go/bin - ~/.cache - key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} - restore-keys: | - ${{ runner.os }}-pnpm-store- + cache: "pnpm" + cache-dependency-path: ./template-sdk/pnpm-lock.json - name: Install Dependencies run: pnpm install diff --git a/.github/workflows/test-template.yaml b/.github/workflows/test-template.yaml index bf565a8b..c7622bbd 100644 --- a/.github/workflows/test-template.yaml +++ b/.github/workflows/test-template.yaml @@ -38,23 +38,8 @@ jobs: uses: actions/setup-node@v4 with: node-version: 18 - - name: Get pnpm store directory - shell: bash - run: | - echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV + cache: "pnpm" + cache-dependency-path: ./template-default/pnpm-lock.json - - uses: actions/cache@v3 - name: Setup pnpm cache - timeout-minutes: 5 - continue-on-error: true - with: - path: | - ${{ env.STORE_PATH }} - ~/go/pkg/mod - ~/go/bin - ~/.cache - key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} - restore-keys: | - ${{ runner.os }}-pnpm-store- - run: pnpm install - run: pnpm build