process.env.PWD is not supported on Windows
gijsroge opened this issue · 0 comments
gijsroge commented
This is the current output if you try to run buildozer on Windows.
yarn run v1.22.4
$ node ../buildozer/bin/buildozer build
[13:53:46] Working directory changed to ~\Code\buildozer
[13:53:47] Using gulpfile ~\Code\buildozer\gulpfile.js
[13:53:47] Starting 'build'...
[13:53:47] Starting 'setEnvironment'...
[13:53:47] Finished 'setEnvironment' after 765 μs
[13:53:47] Starting 'clean'...
[13:53:47] 'clean' errored after 975 μs
[13:53:47] TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received undefined
at validateString (internal/validators.js:117:11)
at Object.join (path.js:375:7)
at C:\Users\rogeg\Code\buildozer\lib\gulp\configs.js:35:26
at Array.map (<anonymous>)
at C:\Users\rogeg\Code\buildozer\lib\gulp\configs.js:34:33
at Array.forEach (<anonymous>)
at processConfig (C:\Users\rogeg\Code\buildozer\lib\gulp\configs.js:32:60)
at configs (C:\Users\rogeg\Code\buildozer\lib\gulp\configs.js:66:19)
at Object.<anonymous> (C:\Users\rogeg\Code\buildozer\lib\gulp\configs.js:90:18)
at Module._compile (internal/modules/cjs/loader.js:1133:30)
[13:53:47] 'build' errored after 4.81 ms
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
We should use process.env.INIT_CWD as this is set by NPM and Yarn regardless of the OS your are running.