[PR #14999] [MERGED] Reload environment variables by default; add setting to disable #30343

Open
opened 2026-01-31 09:40:13 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/14999
Author: @ianjoneill
Created: 3/16/2023
Status: Merged
Merged: 3/17/2023
Merged by: @DHowett

Base: mainHead: f-reload-environment-variables-v2


📝 Commits (10+)

  • 7bc0e9e Add a setting to reload environment variables
  • cdcd73d Fix typo
  • 12c71ef Make the diff smaller
  • 7a9c922 experimental -> compatibility
  • 010b7b1 Format
  • 0b52fb6 Merge branch 'main' into f-reload-environment-variables-v2
  • dba5220 Move the work down into ConptyConnection
  • e37bf5e Fix AuditMode failures
  • db7be93 Fix clang-tidy warnings
  • 31676b4 Reduce memory allocations in til::env

📊 Changes

8 files changed (+161 additions, -132 deletions)

View changed files

📝 .github/actions/spelling/allow/apis.txt (+1 -1)
📝 doc/cascadia/profiles.schema.json (+5 -0)
📝 src/cascadia/TerminalApp/TerminalPage.cpp (+2 -0)
📝 src/cascadia/TerminalConnection/ConptyConnection.cpp (+17 -1)
📝 src/cascadia/TerminalConnection/ConptyConnection.h (+1 -0)
📝 src/cascadia/TerminalSettingsModel/GlobalAppSettings.idl (+1 -0)
📝 src/cascadia/TerminalSettingsModel/MTSMSettings.h (+1 -0)
📝 src/inc/til/env.h (+133 -130)

📄 Description

Summary of the Pull Request

Adds a global setting compatibility.reloadEnvironmentVariables with a default value of true. When set, during connection creation a new environment block will be generated to ensure it has the latest environment variables.

Validation Steps Performed

Manually tested - see video in the first second comment.

PR Checklist


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/microsoft/terminal/pull/14999 **Author:** [@ianjoneill](https://github.com/ianjoneill) **Created:** 3/16/2023 **Status:** ✅ Merged **Merged:** 3/17/2023 **Merged by:** [@DHowett](https://github.com/DHowett) **Base:** `main` ← **Head:** `f-reload-environment-variables-v2` --- ### 📝 Commits (10+) - [`7bc0e9e`](https://github.com/microsoft/terminal/commit/7bc0e9ebb068d1914dde045aa555d04a9dd9a96b) Add a setting to reload environment variables - [`cdcd73d`](https://github.com/microsoft/terminal/commit/cdcd73d70817a6370e1cc07025099088aa45b222) Fix typo - [`12c71ef`](https://github.com/microsoft/terminal/commit/12c71ef40622973b7c79f7a3f9384042050a15d7) Make the diff smaller - [`7a9c922`](https://github.com/microsoft/terminal/commit/7a9c92248d62c144caf7270ba245c8ea4efaf1e7) experimental -> compatibility - [`010b7b1`](https://github.com/microsoft/terminal/commit/010b7b1a185de78d91e0c0b04fa0361813c6fcc9) Format - [`0b52fb6`](https://github.com/microsoft/terminal/commit/0b52fb66295c34dd63fdbab2b072406a342436ca) Merge branch 'main' into f-reload-environment-variables-v2 - [`dba5220`](https://github.com/microsoft/terminal/commit/dba5220e0051dee529fb9f4cb180a451acce10e2) Move the work down into ConptyConnection - [`e37bf5e`](https://github.com/microsoft/terminal/commit/e37bf5e66594cae7006cb01391936de097b9af1a) Fix AuditMode failures - [`db7be93`](https://github.com/microsoft/terminal/commit/db7be9396fb13b9445bdd65628ee45f4f78c3e10) Fix clang-tidy warnings - [`31676b4`](https://github.com/microsoft/terminal/commit/31676b4ade74307c1753288ccc1be2476ab6d8ed) Reduce memory allocations in til::env ### 📊 Changes **8 files changed** (+161 additions, -132 deletions) <details> <summary>View changed files</summary> 📝 `.github/actions/spelling/allow/apis.txt` (+1 -1) 📝 `doc/cascadia/profiles.schema.json` (+5 -0) 📝 `src/cascadia/TerminalApp/TerminalPage.cpp` (+2 -0) 📝 `src/cascadia/TerminalConnection/ConptyConnection.cpp` (+17 -1) 📝 `src/cascadia/TerminalConnection/ConptyConnection.h` (+1 -0) 📝 `src/cascadia/TerminalSettingsModel/GlobalAppSettings.idl` (+1 -0) 📝 `src/cascadia/TerminalSettingsModel/MTSMSettings.h` (+1 -0) 📝 `src/inc/til/env.h` (+133 -130) </details> ### 📄 Description ## Summary of the Pull Request Adds a global setting `compatibility.reloadEnvironmentVariables` with a default value of `true`. When set, during connection creation a new environment block will be generated to ensure it has the latest environment variables. ## Validation Steps Performed Manually tested - see video in the ~~first~~ second comment. ## PR Checklist - [x] Closes #1125 - [ ] Tests added/passed - [ ] Documentation updated - If checked, please file a pull request on [our docs repo](https://github.com/MicrosoftDocs/terminal) and link it here: #xxx - [x] Schema updated (if necessary) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-31 09:40:13 +00:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#30343