Debug: Support presentation.hidden in platform-specific launch config sections#300237
Draft
Debug: Support presentation.hidden in platform-specific launch config sections#300237
presentation.hidden in platform-specific launch config sections#300237Conversation
…form-specific sections Co-authored-by: roblourens <323878+roblourens@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add support for hiding configs on specific platforms
Debug: Support Mar 9, 2026
presentation.hidden in platform-specific launch config sections
Contributor
There was a problem hiding this comment.
Pull request overview
Adds runtime support for scoping presentation.hidden to platform-specific (windows/osx/linux) debug launch overrides so hidden configs are filtered correctly per-OS.
Changes:
- Extend platform override typing to include
presentationand add anisDebugConfigtype guard. - Add
getEffectivePresentationForConfigto merge base and platform-specificpresentation. - Resolve effective presentation before filtering/sorting configuration lists.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| src/vs/workbench/contrib/debug/test/browser/debugUtils.test.ts | Adds unit coverage for platform presentation override merging. |
| src/vs/workbench/contrib/debug/common/debugUtils.ts | Implements platform-aware presentation resolution helper. |
| src/vs/workbench/contrib/debug/common/debug.ts | Updates types to allow presentation in platform overrides and adds isDebugConfig. |
| src/vs/workbench/contrib/debug/browser/debugConfigurationManager.ts | Applies effective presentation before visibility filtering/sorting. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Launch configurations already support
presentation.hiddento hide entries from the debug dropdown, but this setting could not be scoped to a specific OS. This adds support for specifyingpresentationinsidewindows,osx, andlinuxoverride sections.Example usage:
{ "name": "My Config", "type": "node", "request": "launch", "windows": { "presentation": { "hidden": true } } }Changes
debug.ts— Addedpresentation?: IConfigPresentationtoIEnvConfig(the type used for platform-specific override sections). MovedIConfigPresentationbeforeIEnvConfigto preserve correct declaration order. AddedisDebugConfigtype guard to distinguishIConfigfromICompound.debugUtils.ts— AddedgetEffectivePresentationForConfig(config: IConfig)which merges the basepresentationwith the current-platform override (e.g.,windows.presentationon Windows), so per-platform values override base values while non-specified fields are preserved.debugConfigurationManager.ts—getConfigurationNames()andgetAllConfigurations()now resolve the effective platform-aware presentation before filtering/sorting, so platform-hidden configs are excluded from the dropdown and command palette on the target OS.💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.