DMarby / humblebundle-ebook-downloader

An easy way to download ebooks from your humblebundle account
The Unlicense
230 stars 27 forks source link

[BUG] Reading/writing of config file on Windows 7 #21

Closed eirism closed 6 years ago

eirism commented 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.

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.

DMarby commented 6 years ago

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.