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
added proxy support for build #1965
added proxy support for build #1965
Conversation
@@ -351,7 +352,14 @@ gulp.task('package:createVSIX', () => | |||
); | |||
|
|||
gulp.task('l10n:bundle-download', async () => { | |||
const res = await got('https://github.com/microsoft/vscode-loc/archive/main.zip').buffer(); | |||
const opts = {}; | |||
const proxy = process.env.https_proxy || process.env.HTTPS_PROXY || null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
process.env
is already 'magically' case insensitive on Windows
const proxy = process.env.https_proxy || process.env.HTTPS_PROXY || null; | |
const proxy = process.env.HTTPS_PROXY || null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
process.env
is already 'magically' case insensitive on Windows
in my case it is running on linux as I build the package for use with nvim and the lsp
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The uppercase version is the standard one I've seen, and is what e.g. curl uses
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't really have a strong attachment to supporting upper and lowercase and I usually also prefer uppercase env vars. but I have seen multiple programs in linux that only use the lowercase variant. And in linux the lowercase variant also takes precedent over the uppercase one in curl
Like I said. Don't really have a strong opinion on that one. your choice
package.json
Outdated
@@ -67,6 +67,7 @@ | |||
"execa": "^5.1.1", | |||
"glob-stream": "^8.0.0", | |||
"got": "^11.8.6", | |||
"https-proxy-agent": "^7.0.4", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be in the devDependencies
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
agree. moved to devDependencies
@microsoft-github-policy-service agree |
not a mac user. Any idea what's the catch in that test stage? |
That's a flake on main I need to fix still |
As stated in #1955 running
npx gulp vsDebugServerBundle
behind a proxy will currently fail as got does not honor proxy env vars by default.This PR addresses that issue by using an https proxy agent in case env vars have been detected for an https proxy