Skip to content

Commit

Permalink
fix(build): Resolve bad shell invocation shell
Browse files Browse the repository at this point in the history
Before, during the building procedure, there was a problem with the invocation shell in the child process that used `child_process.spawn`. In Windows, this resulted in the process issuing an ENOENT error since the command was not recognized. However, with this modification, we resolved the issue and it now functions correctly in Windows by activating the `shell` option within the options argument (3rd argument) of the `spawn` function.

Note:
Tested in PowerShell and MSYS2 MinTTY. This change are exclusively to Windows users and developers.
  • Loading branch information
mitsuki31 committed May 16, 2024
1 parent 4f23e58 commit f5dc677
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions scripts/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ async function minify(files: Array<string>): Promise<void> {
const tsc: ChildProcess = spawn(tscCmd[0], tscCmd.slice(1), {
cwd: rootDir,
stdio: 'inherit',
shell: true,
windowsHide: true
});

Expand Down

0 comments on commit f5dc677

Please sign in to comment.