mirror of
https://github.com/cloudflare/vinext.git
synced 2026-05-09 00:09:23 +02:00
[PR #742] fix: add shell: true on Windows for execFileSync calls #810
Labels
No labels
enhancement
enhancement
good first issue
help wanted
nextjs-tracking
nextjs-tracking
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/vinext#810
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/cloudflare/vinext/pull/742
Author: @evil1morty
Created: 4/1/2026
Status: 🔄 Open
Base:
main← Head:fix/windows-execfilesync-enoent📝 Commits (2)
5220036fix: addshell: trueon Windows for execFileSync callsae574e6style: break long execFileSync lines to fit printWidth: 100📊 Changes
2 files changed (+30 additions, -5 deletions)
View changed files
📝
packages/vinext/src/cli.ts(+20 -4)📝
packages/vinext/src/deploy.ts(+10 -1)📄 Description
Summary
vinext deploy,vinext build, andvinext lintfail on Windows withspawnSync ENOENTbecauseexecFileSynccannot execute.bin/wrangler(a shell script) or package manager commands likenpm/npx(.cmdwrappers) without enabling the shell.Fix
Add
shell: process.platform === "win32"to allexecFileSyncoptions indeploy.tsandcli.ts. This only enables the shell on Windows where it's required, preserving the no-shell-injection guarantee on other platforms.Affected call sites:
runWranglerDeploy()indeploy.ts— wrangler binaryinstallDeps()indeploy.ts— package managerdeploy()— package managerbuildApp()incli.ts— package managerlint()incli.ts— npx eslint/oxlintTest plan
npx wrangler deployworks as workaround on Windows 11vinext deployon Windows with this patchvinext buildon Windows (react upgrade path)vinext linton Windowsfalse)Environment: Windows 11, Node 22, wrangler 4.79.0
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.