yeoman / doctor

Detect potential issues with users system that could prevent Yeoman from working correctly
http://yeoman.io
BSD 2-Clause "Simplified" License
61 stars 17 forks source link

doctor doesn't support proxy when used globally #40

Closed tremblaysimon closed 5 years ago

tremblaysimon commented 5 years ago

When yeoman-doctor is installed globally (npm install -g yeoman-doctor), it doesn't use any proxy environment variables. That issue is related to https://github.com/yeoman/yo/issues/589.

Example of error:

○ → yodoctor

Yeoman Doctor
Running sanity checks on your system

✔ Global configuration file is valid
✔ NODE_PATH matches the npm root
✔ Node.js version
✔ No .bowerrc file in home directory
✔ No .yo-rc.json file in home directory
✔ npm version
{ RequestError: connect ECONNREFUSED 104.16.27.35:443
    at ClientRequest.req.once.err (/home/simon/.nvm/versions/node/v8.12.0/lib/node_modules/yeoman-doctor/node_modules/got/index.js:73:21)
SBoudrias commented 5 years ago

Ah yeah, yo is the package loading the proxy configuration.

Most likely as doctor run in a post-install script, the proxy isn't loaded.

Would you like to send a PR to also install the tunnel when doctor run?