Closed eirism closed 6 years ago
On Windows 7 the reading and writing of the config file fails if the script is run while the working directory is on another drive than the users home directory.
This is because on Window process.env.HOMEPATH evaluates to a path without the drive letter. process.env.USERPROFILE on the other hand evaluates to a path with the drive letter.
process.env.HOMEPATH
process.env.USERPROFILE
A fix could be to swap the order of those two environment variables when resolving configPath, as long as this doesn't break any other platform.
configPath
Thanks for reporting this! I've released a new version (1.0.10) which should resolve this issue, please let me know if you're still having trouble.
1.0.10
On Windows 7 the reading and writing of the config file fails if the script is run while the working directory is on another drive than the users home directory.
This is because on Window
process.env.HOMEPATH
evaluates to a path without the drive letter.process.env.USERPROFILE
on the other hand evaluates to a path with the drive letter.A fix could be to swap the order of those two environment variables when resolving
configPath
, as long as this doesn't break any other platform.