Change:
Type: <bBug</bIn the "Source Control Repositories" view, if you have several repos selected, and then right click on one of them and choose "Open in Integrated Terminal", it will open the terminal in the directory for the first selected repo regardless of which repo you right clicked on. However if you right click on a repo under "Source Control" then it will open the terminal correctly. VS Code version: Code 1.90.2 (, 2024-06-18T22:33:48.698Z) OS version: Linux x64 6.6.15-2rodete2-amd64 Modes: Remote OS version: Linux x64 6.6.15-2rodete2-amd64 <details<summarySystem Info</summary </details<details<summaryExtensions (22)</summaryExtensionVersion ------ jupyter-keymap1.1.2 remote-containers0.375.1 remote-ssh0.112.0 remote-ssh-edit0.86.0 vscode-remote-extensionpack0.25.0 remote-explorer0.4.3 remote-server1.5.2 rewrap1.16.3 githistory0.6.20 gitlens15.1.0 go0.41.4 debugpy2024.6.0 isort2023.10.1 pylint2023.10.1 python2024.10.0 jupyter2024.5.0 jupyter-keymap1.1.2 jupyter-renderers1.0.18 vscode-jupyter-cell-tags0.1.9 vscode-jupyter-slideshow0.1.6 preview-vscode2.3.7 code-spell-checker3.0.1 </details<details<summaryA/B Experiments</summary</details<!-- generated by issue reporter --
Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.91.0. Please try upgrading to the latest version and checking whether this issue remains. Happy Coding!
Is that option being contributed by an extension? Please use the command to investigate.
The menu option is there even with no extensions loaded by "Start Extension Bisect"
<!-- UNABLETOLOCATECOMMITMESSAGE repo --Issue marked as unreleased but unable to locate closing commit in repo history. If this was closed in a separate repo you can add the label directly, or comment .
<!-- UNABLETOLOCATECOMMITMESSAGE --Issue marked as unreleased but unable to locate closing commit in issue timeline. You can manually reference a commit by commenting , or directly add the label if you know this has already been releaased

Discussion:
import { MANAGE_TRUST_COMMAND_ID, WorkspaceTrustContext } from 'vs/workbench/contrib/workspace/common/workspace'; import { IQuickDiffService } from 'vs/workbench/contrib/scm/common/quickDiff'; import { QuickDiffService } from 'vs/workbench/contrib/scm/common/quickDiffService'; <del> import { getActiveElement } from 'vs/base/browser/dom'; </del> <ins> import { getActiveElement, isActiveElement } from 'vs/base/browser/dom'; </ins> import { SCMWorkingSetController } from 'vs/workbench/contrib/scm/browser/workingSet'; import { IViewsService } from 'vs/workbench/services/views/common/viewsService'; <ins> import { IListService, WorkbenchList } from 'vs/platform/list/browser/listService'; import { isSCMRepository } from 'vs/workbench/contrib/scm/browser/util'; </ins> ModesRegistry.registerLanguage({ id: 'scminput',

primary: KeyMod.Alt | KeyCode.UpArrow }); <del> CommandsRegistry.registerCommand('scm.openInIntegratedTerminal', async (accessor, provider: ISCMProvider) => { if (!provider || !provider.rootUri) { </del> <ins> CommandsRegistry.registerCommand('scm.openInIntegratedTerminal', async (accessor, ...providers: ISCMProvider[]) => { if (!providers || providers.length === 0) { </ins> return; } const commandService = accessor.get(ICommandService); <ins> const listService = accessor.get(IListService); let provider = providers.length === 1 ? providers[0] : undefined; if (!provider) { const list = listService.lastFocusedList; const element = list?.getHTMLElement(); if (list instanceof WorkbenchList && element && isActiveElement(element)) { const [index] = list.getFocus(); const focusedElement = list.element(index); // Source Control Repositories if (isSCMRepository(focusedElement)) { provider = focusedElement.provider; } } } if (!provider?.rootUri) { return; } </ins> await commandService.executeCommand('openInIntegratedTerminal', provider.rootUri); });