desktop / dugite

Elegant bindings for working with Git in your Node applications
MIT License
460 stars 149 forks source link

Enable use of proxy when downloading Git binary #539

Open itsananderson opened 1 year ago

itsananderson commented 1 year ago

When this project switched away from requests, support for configuring a proxy via the HTTP_PROXY/HTTPS_PROXY environment variables was lost. This change restores proxy support by adding the global-agent package as a dependency and setting it up in the download script before attempting to download Git.

By default, global-agent only looks for environment variables prefixed by GLOBAL_AGENT_ (e.g. GLOBAL_AGENT_HTTP_PROXY). To maintain backward compatibility, the download script checks for the old HTTP_PROXY/HTTPS_PROXY variables, and copies them to the GLOBAL_AGENT_ equivalent if not already defined.

Fixes #498

custa commented 10 months ago

it work /lgtm

panther7 commented 1 month ago

Why is not still merged?

@tidy-dev