* [PR PATCH] xbps-src: keep http_proxy and other lowercase proxy variables
@ 2023-01-04 13:35 tornaria
2023-01-04 15:24 ` [PR PATCH] [Merged]: " sgn
0 siblings, 1 reply; 2+ messages in thread
From: tornaria @ 2023-01-04 13:35 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1674 bytes --]
There is a new pull request by tornaria against master on the void-packages repository
https://github.com/tornaria/void-packages http_proxy
https://github.com/void-linux/void-packages/pull/41435
xbps-src: keep http_proxy and other lowercase proxy variables
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
From `curl` manpage:
```
ENVIRONMENT
The environment variables can be specified in lower case or upper case.
The lower case version has precedence. http_proxy is an exception as it
is only available in lower case.
```
I have `http_proxy` and `https_proxy` set, and then `xbps-src update-check` would not use the proxy. With this commit, it works as expected.
<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- aarch64-musl
- armv7l
- armv6l-musl
-->
A patch file from https://github.com/void-linux/void-packages/pull/41435.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-http_proxy-41435.patch --]
[-- Type: text/x-diff, Size: 1657 bytes --]
From 238eee31e52c394e1d1aeaa155482eed3d103666 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Wed, 4 Jan 2023 10:25:10 -0300
Subject: [PATCH] xbps-src: keep http_proxy and other lowercase proxy variables
---
common/environment/setup/sourcepkg.sh | 2 ++
common/xbps-src/shutils/chroot.sh | 5 +++++
2 files changed, 7 insertions(+)
diff --git a/common/environment/setup/sourcepkg.sh b/common/environment/setup/sourcepkg.sh
index a7f98b57d6f7..4e3b4e98ba43 100644
--- a/common/environment/setup/sourcepkg.sh
+++ b/common/environment/setup/sourcepkg.sh
@@ -25,6 +25,8 @@ for var in $(awk 'BEGIN{for (i in ENVIRON) {print i}}' </dev/null); do
;;
FTP_PROXY | FTP_RETRIES)
;;
+ http_proxy | https_proxy | ftp_proxy | all_proxy | no_proxy)
+ ;;
*)
unset -v "$var"
;;
diff --git a/common/xbps-src/shutils/chroot.sh b/common/xbps-src/shutils/chroot.sh
index a7100d4ea56f..823705030b97 100644
--- a/common/xbps-src/shutils/chroot.sh
+++ b/common/xbps-src/shutils/chroot.sh
@@ -165,6 +165,11 @@ chroot_handler() {
else
env -i -- PATH="/usr/bin:$PATH" SHELL=/bin/sh \
HOME=/tmp IN_CHROOT=1 LC_COLLATE=C LANG=en_US.UTF-8 \
+ ${http_proxy:+http_proxy="${http_proxy}"} \
+ ${https_proxy:+https_proxy="${https_proxy}"} \
+ ${ftp_proxy:+ftp_proxy="${ftp_proxy}"} \
+ ${all_proxy:+all_proxy="${all_proxy}"} \
+ ${no_proxy:+no_proxy="${no_proxy}"} \
${HTTP_PROXY:+HTTP_PROXY="${HTTP_PROXY}"} \
${HTTPS_PROXY:+HTTPS_PROXY="${HTTPS_PROXY}"} \
${FTP_PROXY:+FTP_PROXY="${FTP_PROXY}"} \
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PR PATCH] [Merged]: xbps-src: keep http_proxy and other lowercase proxy variables
2023-01-04 13:35 [PR PATCH] xbps-src: keep http_proxy and other lowercase proxy variables tornaria
@ 2023-01-04 15:24 ` sgn
0 siblings, 0 replies; 2+ messages in thread
From: sgn @ 2023-01-04 15:24 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1518 bytes --]
There's a merged pull request on the void-packages repository
xbps-src: keep http_proxy and other lowercase proxy variables
https://github.com/void-linux/void-packages/pull/41435
Description:
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
From `curl` manpage:
```
ENVIRONMENT
The environment variables can be specified in lower case or upper case.
The lower case version has precedence. http_proxy is an exception as it
is only available in lower case.
```
I have `http_proxy` and `https_proxy` set, and then `xbps-src update-check` would not use the proxy. With this commit, it works as expected.
<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- aarch64-musl
- armv7l
- armv6l-musl
-->
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-01-04 15:24 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-04 13:35 [PR PATCH] xbps-src: keep http_proxy and other lowercase proxy variables tornaria
2023-01-04 15:24 ` [PR PATCH] [Merged]: " sgn
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).