Skip to content

Commit 1b13fa8

Browse files
committed
fix: update deploy workflows (#1130)
1 parent 2cf82c1 commit 1b13fa8

4 files changed

Lines changed: 13 additions & 32 deletions

File tree

.github/workflows/deploy-storybook.yml

Lines changed: 3 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -27,24 +27,11 @@ jobs:
2727
- name: Checkout
2828
uses: actions/checkout@v4
2929

30-
- uses: pnpm/action-setup@v4
31-
name: Install pnpm
32-
with:
33-
version: 10
34-
run_install: false
35-
36-
- name: Install Node.js
37-
uses: actions/setup-node@v4
38-
with:
39-
node-version-file: 'package.json'
40-
cache: 'pnpm'
41-
cache-dependency-path: 'pnpm-lock.yaml'
42-
43-
- name: Install dependencies
44-
run: pnpm install
30+
- name: Install Mise
31+
uses: jdx/mise-action@v3
4532

4633
- name: Build storybook
47-
run: pnpm storybook:build
34+
run: mise run build-storybook
4835
env:
4936
VITE_GRAASP_H5P_INTEGRATION_URL: http://mock.value.com
5037
VITE_GRAASP_REDIRECTION_HOST: http://go.mock.com

.github/workflows/deploy.yml

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -39,20 +39,8 @@ jobs:
3939
with:
4040
ref: ${{ inputs.version || 'main' }}
4141

42-
- uses: pnpm/action-setup@v4
43-
name: Install pnpm
44-
with:
45-
version: 10
46-
run_install: false
47-
48-
- name: Install Node.js
49-
uses: actions/setup-node@v4
50-
with:
51-
node-version-file: 'package.json'
52-
cache: 'pnpm'
53-
54-
- name: Install dependencies
55-
run: pnpm install
42+
- name: Install Mise
43+
uses: jdx/mise-action@v3
5644

5745
- name: pnpm build
5846
# Set environment variables required to perform the build. These are only available to this step
@@ -69,7 +57,7 @@ jobs:
6957
VITE_RECAPTCHA: ${{ secrets.VITE_RECAPTCHA_SITE_KEY }}
7058
VITE_GRAASP_H5P_INTEGRATION_URL: ${{ vars.VITE_GRAASP_H5P_INTEGRATION_URL }}
7159
VITE_GRAASP_REDIRECTION_HOST: ${{ vars.VITE_GRAASP_REDIRECTION_HOST }}
72-
run: pnpm build
60+
run: mise run build
7361
shell: bash
7462

7563
- name: Deploy

mise.toml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,9 @@ depends = ['pnpm-install']
3333
description = 'Calls your build script in `package.json`'
3434
run = 'node --run build'
3535
depends = ['pnpm-install']
36+
37+
[tasks.build-storybook]
38+
description = "Build Storybook"
39+
run = 'pnpm storybook build'
40+
depends = ['pnpm-install']
41+

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@
112112
"cypress:open": "env-cmd -f ./.env.test cypress open --browser chrome",
113113
"cypress:run": "env-cmd -f ./.env.test cypress run --browser chrome",
114114
"test:unit": "vitest",
115-
"storybook": "storybook dev -p 6006",
115+
"sb": "storybook dev -p 6006",
116116
"storybook:build": "storybook build",
117117
"storybook:test": "vitest --project storybook",
118118
"client:generate": "openapi-ts"

0 commit comments

Comments
 (0)