Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into surai/slack-semantic-…
Browse files Browse the repository at this point in the history
…changes-notification
  • Loading branch information
sdirosa committed Nov 21, 2023
2 parents d07922c + a5e0e14 commit b65c6a1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/sweet-seahorses-complain.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@gitbook/cli': minor
---

Updates the CLI to check for Windows machines in order to install dependencies correctly
2 changes: 1 addition & 1 deletion packages/cli/src/init.ts
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ export async function extendPackageJson(dirPath: string, projectName: string): P
*/
export function installDependencies(dirPath: string): Promise<void> {
return new Promise((resolve, reject) => {
const install = spawn('npm', ['install'], {
const install = spawn(/^win/.test(process.platform) ? 'npm.cmd' : 'npm', ['install'], {
stdio: 'inherit',
cwd: dirPath,
});
Expand Down

0 comments on commit b65c6a1

Please sign in to comment.