Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: migrate to pnpm #211

Merged
merged 7 commits into from
Oct 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ name: CI checks

on:
push:
branches:
- main
spaenleh marked this conversation as resolved.
Show resolved Hide resolved
pull_request:
# required for merge groups to report checks
merge_group:
Expand All @@ -16,15 +18,17 @@ jobs:

- name: set up node
uses: actions/setup-node@v4
with:
node-version: 20

- name: Yarn Install and Cache
uses: graasp/graasp-deploy/.github/actions/yarn-install-and-cache@v1
- name: pnpm Install and Cache
uses: graasp/graasp-deploy/.github/actions/pnpm-install-and-cache@v1

- name: Check code linting
run: yarn check
run: pnpm check

- name: Build
run: yarn build
run: pnpm build
env:
VITE_PORT: ${{ vars.VITE_PORT }}
VITE_VERSION: ${{ vars.VITE_VERSION }}
Expand Down
9 changes: 4 additions & 5 deletions .github/workflows/cypress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ jobs:
- name: Setup Node
uses: actions/setup-node@v4

- name: Yarn Install and Cache
uses: graasp/graasp-deploy/.github/actions/yarn-install-and-cache@v1
- name: pnpm Install and Cache
uses: graasp/graasp-deploy/.github/actions/pnpm-install-and-cache@v1
with:
cypress: true

Expand All @@ -33,7 +33,7 @@ jobs:
run: tsc --noEmit

- name: Build App
run: NODE_OPTIONS=--max-old-space-size=8192 yarn build:test
run: NODE_OPTIONS=--max-old-space-size=8192 pnpm build:test
shell: bash
env:
VITE_PORT: ${{ vars.VITE_PORT }}
Expand All @@ -53,11 +53,10 @@ jobs:
with:
install: false
# we launch the app in preview mode to avoid issues with hmr websockets from vite polluting the mocks
start: yarn preview:test
start: pnpm preview:test
browser: chrome
quiet: true
config-file: cypress.config.ts
cache-key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }}
env:
VITE_PORT: ${{ vars.VITE_PORT }}
VITE_VERSION: ${{ vars.VITE_VERSION }}
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/deploy-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4

- name: Yarn install and Cache dependencies
uses: graasp/graasp-deploy/.github/actions/yarn-install-and-cache@v1
- name: pnpm install and Cache dependencies
uses: graasp/graasp-deploy/.github/actions/pnpm-install-and-cache@v1

- name: Yarn build
- name: pnpm build
# Set environment variables required to perform the build. These are only available to this step
env:
VITE_VERSION: ${{ github.sha }}
Expand All @@ -37,7 +37,7 @@ jobs:
VITE_SENTRY_DSN: ${{ secrets.VITE_SENTRY_DSN }}
# VITE_GA_MEASUREMENT_ID: ${{ secrets.VITE_GA_MEASUREMENT_ID }}
VITE_SHOW_NOTIFICATIONS: ${{ vars.VITE_SHOW_NOTIFICATIONS }}
run: yarn build
run: pnpm build
shell: bash

- name: Deploy
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/deploy-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@ jobs:
with:
ref: ${{ github.event.client_payload.tag }}

- name: Yarn install and Cache dependencies
uses: graasp/graasp-deploy/.github/actions/yarn-install-and-cache@v1
- name: pnpm install and Cache dependencies
uses: graasp/graasp-deploy/.github/actions/pnpm-install-and-cache@v1

- name: Yarn build
- name: pnpm build
# Set environment variables required to perform the build. These are only available to this step
env:
VITE_VERSION: ${{ github.event.client_payload.tag }}
Expand All @@ -40,7 +40,7 @@ jobs:
VITE_SENTRY_DSN: ${{ secrets.VITE_SENTRY_DSN }}
VITE_GA_MEASUREMENT_ID: ${{ secrets.VITE_GA_MEASUREMENT_ID }}
VITE_SHOW_NOTIFICATIONS: ${{ vars.VITE_SHOW_NOTIFICATIONS }}
run: yarn build
run: pnpm build
shell: bash

- name: Deploy
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/deploy-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@ jobs:
with:
ref: ${{ github.event.client_payload.tag }}

- name: Yarn install and Cache dependencies
uses: graasp/graasp-deploy/.github/actions/yarn-install-and-cache@v1
- name: pnpm install and Cache dependencies
uses: graasp/graasp-deploy/.github/actions/pnpm-install-and-cache@v1

- name: Yarn build
- name: pnpm build
# Set environment variables required to perform the build. These are only available to this step
env:
VITE_VERSION: ${{ github.event.client_payload.tag }}
Expand All @@ -39,7 +39,7 @@ jobs:
VITE_SENTRY_ENV: ${{ vars.VITE_SENTRY_ENV }}
VITE_SENTRY_DSN: ${{ secrets.VITE_SENTRY_DSN }}
VITE_SHOW_NOTIFICATIONS: ${{ vars.VITE_SHOW_NOTIFICATIONS }}
run: yarn build
run: pnpm build
shell: bash

- name: Deploy
Expand Down
3 changes: 3 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"files.trimTrailingWhitespace": true
spaenleh marked this conversation as resolved.
Show resolved Hide resolved
}
9 changes: 0 additions & 9 deletions .yarnrc.yml

This file was deleted.

Loading
Loading