Commit a008269
committed
fix: run mklink through cmd so windows install works
npm install fails on Windows in postinstall with "mklink: command not
found". mklink is a cmd.exe builtin rather than an executable, so the sh
running this script cannot exec it, and every symlink the install needs is
made this way.
Routing it through cmd works. Verified on Windows 11 with git-bash: `mklink
/J link src` reports command not found, `cmd //c mklink //J link src`
reports "Junction created" and the junction resolves. Tested with the same
relative paths symlink() passes, from a directory it has cd'd into.
The doubled slashes are the usual MSYS escaping, and are safe here because
this branch only runs when the OS was detected as cygwin or mingw.1 parent 2b2f8b3 commit a008269
1 file changed
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
| 21 | + | |
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
| |||
0 commit comments