New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: Make postinstall script work on Windows #364
base: main
Are you sure you want to change the base?
Conversation
Thanks for trying it out, did you run |
Split each `cd` call into one per directory so that we don't have any directory separators, because separators are different on Windows than Mac/Linux. Also, Windows' cd doesn't support `cd -` as going back to the last directory. Now that we navigate one dir at a time, we can just use `cd ..` instead.
622650e
to
e362e25
Compare
Ah... I think |
Thanks again. Seems like making it work on Windows is going to be more work than I anticipated. 😅 Until then, you could try using the Docker build. Setting up Docker on Windows might not be straightforward depending on your system though. (Link) |
Oh whoops, I forgot our instructions for that assume Linux. I don't actually use Docker so I can't help you unfortunately. |
Hey @AtkinsSJ not sure if it's related, but to get my postinstall scripts to work on windows for BrowserBox I needed to do this: "postinstall": "node exec.js \"./scripts/postinstall.sh\"", Seems tricky at first, and looked like overkill to me when I first thought of it but worked really well and no more windows problems. The issue is due to paths, and others have tripped over this with npm basically saying they will never fix this because people shouldn't be using windows or sth - that issue thread was a real doozy but I can't find it now haha 🤣 |
Split each
cd
call into one per directory so that we don't have any directory separators, because separators are different on Windows than Mac/Linux.This is intended to fix the issue in #362 but I'm waiting for confirmation on that.