generated from nl-design-system/example
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove the dependency on actions/cache by using the built-in cache configuration of actions/setup-node
- Loading branch information
Showing
1 changed file
with
39 additions
and
100 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,31 +12,18 @@ jobs: | |
|
||
steps: | ||
- name: Checkout branch | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4.1.1 | ||
|
||
- name: Set up Node.js version | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version-file: ".nvmrc" | ||
|
||
- uses: pnpm/[email protected] | ||
name: Install pnpm | ||
id: pnpm-install | ||
- name: Install pnpm package manager | ||
uses: pnpm/[email protected] | ||
with: | ||
version: 8 | ||
run_install: false | ||
|
||
- name: Get pnpm store directory | ||
id: pnpm-cache | ||
run: | | ||
echo "::set-output name=pnpm_cache_dir::$(pnpm store path)" | ||
- uses: actions/cache@v4 | ||
name: Setup pnpm cache | ||
- name: Set up Node.js version | ||
uses: actions/[email protected] | ||
with: | ||
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} | ||
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: | | ||
${{ runner.os }}-pnpm-store- | ||
node-version-file: .nvmrc | ||
cache: pnpm | ||
|
||
- name: Install dependencies | ||
run: | | ||
|
@@ -49,31 +36,18 @@ jobs: | |
|
||
steps: | ||
- name: Checkout branch | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4.1.1 | ||
|
||
- name: Set up Node.js version | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version-file: ".nvmrc" | ||
|
||
- uses: pnpm/[email protected] | ||
name: Install pnpm | ||
id: pnpm-install | ||
- name: Install pnpm package manager | ||
uses: pnpm/[email protected] | ||
with: | ||
version: 8 | ||
run_install: false | ||
|
||
- name: Get pnpm store directory | ||
id: pnpm-cache | ||
run: | | ||
echo "::set-output name=pnpm_cache_dir::$(pnpm store path)" | ||
- uses: actions/cache@v4 | ||
name: Setup pnpm cache | ||
- name: Set up Node.js version | ||
uses: actions/[email protected] | ||
with: | ||
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} | ||
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: | | ||
${{ runner.os }}-pnpm-store- | ||
node-version-file: .nvmrc | ||
cache: pnpm | ||
|
||
- name: Install dependencies | ||
run: | | ||
|
@@ -89,31 +63,18 @@ jobs: | |
|
||
steps: | ||
- name: Checkout branch | ||
uses: actions/checkout@v3 | ||
|
||
- name: Set up Node.js version | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version-file: ".nvmrc" | ||
uses: actions/[email protected] | ||
|
||
- uses: pnpm/[email protected] | ||
name: Install pnpm | ||
id: pnpm-install | ||
- name: Install pnpm package manager | ||
uses: pnpm/[email protected] | ||
with: | ||
version: 8 | ||
run_install: false | ||
|
||
- name: Get pnpm store directory | ||
id: pnpm-cache | ||
run: | | ||
echo "::set-output name=pnpm_cache_dir::$(pnpm store path)" | ||
- uses: actions/cache@v4 | ||
name: Setup pnpm cache | ||
- name: Set up Node.js version | ||
uses: actions/[email protected] | ||
with: | ||
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} | ||
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: | | ||
${{ runner.os }}-pnpm-store- | ||
node-version-file: .nvmrc | ||
cache: pnpm | ||
|
||
- name: Install dependencies | ||
run: | | ||
|
@@ -126,7 +87,7 @@ jobs: | |
pnpm run --if-present build | ||
- name: "Retain build artifact: storybook" | ||
uses: actions/upload-artifact@v4 | ||
uses: actions/upload-artifact@v4.3.1 | ||
with: | ||
name: storybook | ||
path: packages/storybook/dist/ | ||
|
@@ -138,31 +99,18 @@ jobs: | |
|
||
steps: | ||
- name: Checkout branch | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4.1.1 | ||
|
||
- name: Set up Node.js version | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version-file: ".nvmrc" | ||
|
||
- uses: pnpm/[email protected] | ||
name: Install pnpm | ||
id: pnpm-install | ||
- name: Install pnpm package manager | ||
uses: pnpm/[email protected] | ||
with: | ||
version: 8 | ||
run_install: false | ||
|
||
- name: Get pnpm store directory | ||
id: pnpm-cache | ||
run: | | ||
echo "::set-output name=pnpm_cache_dir::$(pnpm store path)" | ||
- uses: actions/cache@v4 | ||
name: Setup pnpm cache | ||
- name: Set up Node.js version | ||
uses: actions/[email protected] | ||
with: | ||
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} | ||
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: | | ||
${{ runner.os }}-pnpm-store- | ||
node-version-file: .nvmrc | ||
cache: pnpm | ||
|
||
- name: Install dependencies | ||
run: | | ||
|
@@ -179,10 +127,10 @@ jobs: | |
|
||
steps: | ||
- name: Checkout release branch | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4.1.1 | ||
|
||
- name: "Restore build artifact: Storybook" | ||
uses: actions/download-artifact@v4 | ||
uses: actions/download-artifact@v4.1.4 | ||
with: | ||
name: storybook | ||
path: packages/storybook/dist/ | ||
|
@@ -201,35 +149,26 @@ jobs: | |
|
||
steps: | ||
- name: Checkout release branch | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4.1.1 | ||
with: | ||
token: ${{ secrets.GH_TOKEN }} | ||
|
||
- name: Set up Node.js version | ||
uses: actions/setup-node@v3 | ||
- name: Install pnpm | ||
uses: pnpm/action-setup@v3.0.0 | ||
with: | ||
node-version-file: ".nvmrc" | ||
version: 8 | ||
|
||
- uses: pnpm/[email protected] | ||
name: Install pnpm | ||
id: pnpm-install | ||
- name: Set up Node.js version | ||
uses: actions/[email protected] | ||
with: | ||
version: 8 | ||
run_install: false | ||
node-version-file: .nvmrc | ||
cache: pnpm | ||
|
||
- name: Get pnpm store directory | ||
id: pnpm-cache | ||
run: | | ||
echo "::set-output name=pnpm_cache_dir::$(pnpm store path)" | ||
- uses: actions/cache@v4 | ||
name: Setup pnpm cache | ||
with: | ||
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} | ||
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: | | ||
${{ runner.os }}-pnpm-store- | ||
- name: "Continuous Deployment: install" | ||
run: | | ||
pnpm install --frozen-lockfile | ||
|