Fix/GitHub workflow (#638)

* fixed workflow

* fix(forge): hoist staged ACP node_modules to stay under Windows MAX_PATH

The Squirrel/nuget Windows maker failed with 'path too long': stageAcpAdapters
rebuilt the ACP dependency closure by always nesting each dep under its parent,
producing 5-level chains (codex-acp -> open -> wsl-utils -> is-wsl ->
is-inside-container -> is-docker) whose paths hit ~260 chars on the CI runner and
blew past Windows' MAX_PATH (nuget.exe ignores long-path settings).

Hoist every package to the top-level node_modules npm-style, nesting only on a
genuine version conflict. Deepest staged path drops 177 -> 114 chars (worst-case
CI absolute ~197, well under 260). Add verifyAcpStaging() which asserts every
dependency edge resolves, in the staged tree, to the same version as the source
pnpm tree, failing the build loudly instead of shipping a broken installer.
This commit is contained in:
Harshvardhan Vatsa 2026-06-23 23:25:19 +05:30 committed by GitHub
parent 812ed9222c
commit c0b38d46d3
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 181 additions and 45 deletions

View file

@ -163,12 +163,25 @@ jobs:
run: pnpm install --frozen-lockfile
working-directory: apps/x
- name: Build node-pty native binary for Linux
working-directory: apps/x
run: |
# node-pty ships prebuilt binaries only for darwin/win32; compile the
# linux-x64 binary so bundle.mjs can stage it into the package. Without
# this the Linux app crashes on launch (missing prebuilds/linux-x64/pty.node).
PTY="node_modules/.pnpm/node-pty@1.1.0/node_modules/node-pty"
cd "$PTY"
npx node-gyp rebuild
mkdir -p prebuilds/linux-x64
cp build/Release/pty.node prebuilds/linux-x64/
- name: Build electron app
env:
VITE_PUBLIC_POSTHOG_KEY: ${{ secrets.VITE_PUBLIC_POSTHOG_KEY }}
VITE_PUBLIC_POSTHOG_HOST: ${{ secrets.VITE_PUBLIC_POSTHOG_HOST }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: npx electron-forge publish --arch=x64,arm64 --platform=linux
ROWBOAT_SKIP_PACMAN: '1' # Arch Linux package is built locally only, never in CI
run: npx electron-forge publish --arch=x64 --platform=linux
working-directory: apps/x/apps/main
- name: Upload workflow artifacts