Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: respect git's http.proxy setting #586

Closed
wants to merge 3 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
14 gradlew
@@ -104,12 +104,14 @@ fi

if [ -z "${HTTPS_PROXY}" -a -z "${https_proxy}" -a -z "${HTTP_PROXY}" -a -z "${http_proxy}" ]; then
# No HTTP(S) proxy configured via environment, check if configured via Git
GIT_HTTP_PROXY="$(git config http.proxy)"
if [ ! -z "${GIT_HTTP_PROXY}" ]; then
export HTTPS_PROXY="${GIT_HTTP_PROXY}"
export https_proxy="${GIT_HTTP_PROXY}"
export HTTP_PROXY="${GIT_HTTP_PROXY}"
export http_proxy="${GIT_HTTP_PROXY}"
if exists git; then
GIT_HTTP_PROXY="$(git config http.proxy)"
if [ ! -z "${GIT_HTTP_PROXY}" ]; then
export HTTPS_PROXY="${GIT_HTTP_PROXY}"
export https_proxy="${GIT_HTTP_PROXY}"
export HTTP_PROXY="${GIT_HTTP_PROXY}"
export http_proxy="${GIT_HTTP_PROXY}"
fi
fi
fi