-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
terminal: normalize envs before merging #9631
Conversation
cc @alvsan09 |
My understanding is that the applications that use the variable may rely on the original casing, it's out of our control. |
The general wisdom is that environment variables should be uppercased. When it comes to |
8d75595
to
b0b8c54
Compare
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.
@paul-marechal is there a need to add tests to shell-process.spec.ts
to ensure the method works successfully under different conditions, and for different operating systems?
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.
just a couple of suggestions.
9a1d1ab
to
598c094
Compare
I renamed |
0d87984
to
c046bd2
Compare
b3a69dc
to
0e14c97
Compare
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.
It looks good to me,
Just a typo, see inline comment!
0e14c97
to
69b27d7
Compare
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.
Looks go to me !! 👍
69b27d7
to
0b648f5
Compare
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.
Looks reasonable to me. One minor comment and a question, but nothing to hold this up.
704a345
to
d3bf0e0
Compare
CI fails with HTTP error 503 service unavailable when downloading plugins... |
d3bf0e0
to
0b2f445
Compare
Environment variables are case insensitive on Windows so we'll align everything to use uppercase when on Windows. Refactor `mergeProcessEnv` function into its own injectable `EnvironmentUtils` class. This fixes the usage of raw exported functions which might be hard to override for clients.
0b2f445
to
93caeb3
Compare
Environment variables are case insensitive on Windows so we'll align
everything to use uppercase when on Windows.
How to test
Not really sure. My
PATH
environment variable on Windows is namedPath
inprocess.env
for some reason. This caused issues when running the@theia/terminal
test suite as at some point we expect to fetchPATH
from an object that should look likeprocess.env
but failed as the name wasPath
instead ofPATH
in that new js object.Review checklist
Reminder for reviewers