From 558dcd568b4904f92f00e8d734da4e1b72d11ca9 Mon Sep 17 00:00:00 2001 From: Robin Malfait Date: Fri, 9 Aug 2024 19:57:16 +0200 Subject: [PATCH] Fix v4 release workflow (#14167) This PR fixes the release workflow - We added a postbuild step so that any arguments/flags passed to the `pnpm run build` command are forwarded to the underlying command. - We made sure that we run any `pnpm` specific flags before the actual command - Cleaned up the CI workflow a bit --- .github/workflows/ci.yml | 2 +- .github/workflows/release.yml | 8 ++------ package.json | 3 ++- 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 81ab377b3eb8..294ab8af3783 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -62,7 +62,7 @@ jobs: - name: Lint run: pnpm run lint - # Only lint on linux to avoind \r\n line ending errors + # Only lint on linux to avoid \r\n line ending errors if: matrix.runner == 'ubuntu-latest' - name: Test diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 2cefce68e635..bc3f2ae21b82 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -114,10 +114,6 @@ jobs: with: node-version: ${{ env.NODE_VERSION }} - - name: Setup cross compile toolchain - if: ${{ matrix.setup }} - run: ${{ matrix.setup }} - - name: Install Rust (Stable) if: ${{ matrix.download }} run: | @@ -130,7 +126,7 @@ jobs: run: pnpm install --ignore-scripts --filter=!./playgrounds/* - name: Build release - run: pnpm run build --filter ${{ env.OXIDE_LOCATION }} + run: pnpm run --filter ${{ env.OXIDE_LOCATION }} build env: RUST_TARGET: ${{ matrix.target }} JEMALLOC_SYS_WITH_LG_PAGE: ${{ matrix.page-size }} @@ -195,7 +191,7 @@ jobs: key: ${{ runner.os }}-${{ matrix.target }}-oxide-${{ hashFiles('./crates/**/*') }} - name: Install dependencies - run: pnpm install --ignore-scripts --filter=!./playgrounds/* + run: pnpm --filter=!./playgrounds/* install --ignore-scripts - name: Build Tailwind CSS run: pnpm run build diff --git a/package.json b/package.json index 5ff40218c5fe..6098451432d9 100644 --- a/package.json +++ b/package.json @@ -34,7 +34,8 @@ "scripts": { "format": "prettier --write .", "lint": "prettier --check . && turbo lint", - "build": "turbo build --filter=!./playgrounds/* && node ./scripts/pack-packages.mjs", + "build": "turbo build --filter=!./playgrounds/*", + "postbuild": "node ./scripts/pack-packages.mjs", "dev": "turbo dev --filter=!./playgrounds/*", "test": "cargo test && vitest run", "test:integrations": "vitest --root=./integrations --no-file-parallelism",