typescript-with-electron-react-kit icon indicating copy to clipboard operation
typescript-with-electron-react-kit copied to clipboard

Script "clean" fails on windows

Open skairunner opened this issue 6 years ago • 3 comments

The rm command line utility does not exist on Windows, so all scripts that require "clean" fail on Windows.

skairunner avatar Mar 19 '18 06:03 skairunner

Related, compile fails with the following error:

'NODE_ENV' is not recognized as an internal or external command,
operable program or batch file.

Another Windows batch difference, I imagine.

skairunner avatar Mar 19 '18 07:03 skairunner

For the first issue, I've seen people use yarn add --dev rimraf and yarn add --dev trash to get around that. If you're feeling up for a PR, that'd be sweet.

For the 2nd issue, I'm not sure how windows sets their environment variables. hmmm... I'll have to look into that one. Unless you know?

skellock avatar Mar 19 '18 11:03 skellock

SET NODE_ENV=[whatever], I believe. I'm not sure how you would change the script to figure out when it's on windows vs a POSIX-y system, tho.

skairunner avatar Mar 19 '18 17:03 skairunner