Change:
<!-- Do Not Delete This! bugreporttemplate --<!-- Please read our Rules of Conduct: --<!-- Read our guide about submitting issues: --<!-- Search existing issues to avoid creating duplicates. --<!-- Test using the latest Insiders build to see if your issue has already been fixed: --<!-- Instead of creating your report here, use 'Report Issue' from the 'Help' menu in VS Code to pre-fill useful information. --<!-- Launch with to check. --Does this issue occur when all extensions are disabled?: Yes <!-- If you answered No above, use 'Help: Start Extension Bisect' from Command Palette to try to identify the cause. --<!-- Issues caused by an extension need to be reported directly to the extension publisher. The 'Help Report Issue' dialog can assist with this. --- VS Code Version: OS Version: macOS 11.4 vscode with , run <img width="640" src="https://user-" /I'm using zsh with the popular prompt, which will start a child process. See more at: It seems vscode already ignores some processes. Would it be a better way to provide a custom setting to ignore processes?
Looks like we just need to add to handle this which makes sense, iterm has a setting so it makes sense to have a setting here.
Code pointers: Tweaking the ignored process names Adding a setting
Could you assign this to me and guide/help me make my first open source contribution
we don't assign issues but you can work on it. You'd need to: Add zsh to Create a new setting and move the default list to it. Follow how existing settings by looking here
Hi I want to work on it no one else is working on it. I was looking at file where we have to add a new setting but Can you please elaborate on what would be the for that setting and what are you referring to by the default list (Is it the default key of each setting or something else) ? Sorry, If the questions are too trivial. As it is my first time contributing in vscode and I'm also quite new to opensource.
is probably working on this already, but you could try back in a few days if it's not tackled yet? For the setting name let's go with , better suggestions are welcome though.
Ok i will look into it, thank you for the opportunity Daniel, can i contact you if i have further questions? Regards, Sandeep Rajakrishnan
Hi how can I contact you, let me know you mail
Hey , please review the pull request Link to PR : Thanks a lot for your support
Hey , is there a need to add a dropdown (enum) for the newly created configurable/setting ? Link to PR :
Is this only applicable to iterm/macos?
Can you tell me how to inject configuration information into ptyService srcvsplatformterminalnode
PtyHostService -iPtyHostService::input -ipc - -TerminalProcess -TerminalProcess::input -TerminalProcess::startWrite-TerminalProcess::doWrite-ChildProcessMonitor::handleInput -ChildProcessMonitor::refreshActive-ChildProcessMonitor::processContainsChildren it's so so so so so so complicated!
I think I need a temporary storage service to ensure that ignored process names are passed to these classes, providing some hints
I think I need a temporary storage service to ensure that ignored process names are passed to these classes, providing some hints
so we need access to IConfigurationService which exists on the shared process (with a subset of config D:GitHubmicrosoftvscodesrcvsplatformterminalcommon), and on the renderer/window for the rest (D:GitHubmicrosoftvscodesrcvsworkbenchcontribterminalcommon). The new setting could be to which means it's available for use in ptyHostService (shared process), similar to how it's used in getProfiles:
can I refer to this code?
This is adding a new setting so it should get called out in the release notes
To verify: Create a terminal editor Create a subprocess that is not included in and ensure it makes the editor dirty Create a subprocess that is included in and ensure it does not make the editor dirty Edit and ensure it works as expected
During verification of this I keep getting this error: ! It comes up when I create a terminal in the editor area.
Attaching console log.
That exception is fixed in main today
Adding a note that still causes the indicator to display even when it is part of the list, whereas other shells like are fine. I wonder what is doing differently. Marking as verified because I think it's just that's off.
you could check the process explorer for what's under the terminal's proc
It was . Adding that entry to the list fixed the issue.

Discussion:
services.set(IUserDataSyncResourceEnablementService, new SyncDescriptor(UserDataSyncResourceEnablementService)); services.set(IUserDataSyncService, new SyncDescriptor(UserDataSyncService)); <del> // Terminal services.set( ILocalPtyService, this._register( new PtyHostService({ graceTime: LocalReconnectConstants.GraceTime, shortGraceTime: LocalReconnectConstants.ShortGraceTime, scrollback: configurationService.getValue<number>(TerminalSettingId.PersistentSessionScrollback) ?? 100 }, configurationService, environmentService, logService, telemetryService ) ) </del> <ins> const ptyHostService = new PtyHostService({ graceTime: LocalReconnectConstants.GraceTime, shortGraceTime: LocalReconnectConstants.ShortGraceTime, scrollback: configurationService.getValue<number>(TerminalSettingId.PersistentSessionScrollback) ?? 100 }, configurationService, environmentService, logService, telemetryService </ins> ); <ins> await ptyHostService.initialize(); // Terminal services.set(ILocalPtyService, this._register(ptyHostService)); </ins> // Extension Host services.set(IExtensionHostStarter, this._register(new ExtensionHostStarter(logService)));

PersistentSessionScrollback = 'terminal.integrated.persistentSessionScrollback', InheritEnv = 'terminal.integrated.inheritEnv', ShowLinkHover = 'terminal.integrated.showLinkHover', <ins> IgnoreProcessNames = 'terminal.integrated.ignoreProcessNames', </ins> } export enum WindowsShellType {

reviveTerminalProcesses(state: string): Promise<void>; refreshProperty(id: number, property: ProcessPropertyType): Promise<any>; updateProperty(id: number, property: ProcessPropertyType, value: any): Promise<void>; <ins> setIgnoreProcessNames(names: string[]): Promise<void>; </ins> } export interface IRequestResolveVariablesEvent {

description: localize('terminal.integrated.showLinkHover', "Whether to show hovers for links in the terminal output."), type: 'boolean', default: true <ins> }, [TerminalSettingId.IgnoreProcessNames]: { description: localize('terminal.integrated.confirmIgnoreProcesses', "Configurable to provide a custom setting to ignore processes"), type: 'array', items: { type: 'string', uniqueItems: true }, default: [ // Popular prompt programs, these should not count as child processes 'starship', 'oh-my-posh', // Git bash may runs a subprocess of itself (binbash.exe -> usrbinbash.exe) 'bash', 'zsh', ] </ins> } } };

ActiveDebounceDuration = 1000, } <del> const ignoreProcessNames = [ // Popular prompt programs, these should not count as child processes 'starship', 'oh-my-posh', // Git bash may runs a subprocess of itself (binbash.exe -> usrbinbash.exe) 'bash', ]; </del> <ins> export const ignoreProcessNames: string[] = []; </ins> /** * Monitors a process for child processes, checking at differing times depending on input and output

import { LogLevelChannelClient } from 'vs/platform/log/common/logIpc'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { RequestStore } from 'vs/platform/terminal/common/requestStore'; <del> import { HeartbeatConstants, IHeartbeatService, IProcessDataEvent, IPtyService, IReconnectConstants, IRequestResolveVariablesEvent, IShellLaunchConfig, ITerminalDimensionsOverride, ITerminalLaunchError, ITerminalProfile, ITerminalsLayoutInfo, TerminalIcon, TerminalIpcChannels, IProcessProperty, TerminalShellType, TitleEventSource, ProcessPropertyType, ProcessCapability, IProcessPropertyMap } from 'vs/platform/terminal/common/terminal'; </del> <ins> import { HeartbeatConstants, IHeartbeatService, IProcessDataEvent, IPtyService, IReconnectConstants, IRequestResolveVariablesEvent, IShellLaunchConfig, ITerminalDimensionsOverride, ITerminalLaunchError, ITerminalProfile, ITerminalsLayoutInfo, TerminalIcon, TerminalIpcChannels, IProcessProperty, TerminalShellType, TitleEventSource, ProcessPropertyType, ProcessCapability, IProcessPropertyMap, TerminalSettingId } from 'vs/platform/terminal/common/terminal'; </ins> import { registerTerminalPlatformConfiguration } from 'vs/platform/terminal/common/terminalPlatformConfiguration'; import { IGetTerminalLayoutInfoArgs, IProcessDetails, IPtyHostProcessReplayEvent, ISetTerminalLayoutInfoArgs } from 'vs/platform/terminal/common/terminalProcess'; import { detectAvailableProfiles } from 'vs/platform/terminal/node/terminalProfiles';

this._resolveVariablesRequestStore.onCreateRequest(this._onPtyHostRequestResolveVariables.fire, this._onPtyHostRequestResolveVariables); [this._client, this._proxy] = this._startPtyHost(); <ins> this._register(this._configurationService.onDidChangeConfiguration(async e => { if (e.affectsConfiguration(TerminalSettingId.IgnoreProcessNames)) { await this.setIgnoreProcessNames(this.ignoreProcessNames); } })); } async initialize(): Promise<void> { await this.setIgnoreProcessNames(this.ignoreProcessNames); } private get ignoreProcessNames(): string[] { return this._configurationService.getValue<string[]>(TerminalSettingId.IgnoreProcessNames); } setIgnoreProcessNames(names: string[]): Promise<void> { return this._proxy.setIgnoreProcessNames(names); </ins> } private async _resolveShellEnv(): Promise<typeof process.env> {

import { getWindowsBuildNumber } from 'vs/platform/terminal/node/terminalEnvironment'; import { TerminalProcess } from 'vs/platform/terminal/node/terminalProcess'; import { localize } from 'vs/nls'; <ins> import { ignoreProcessNames } from 'vs/platform/terminal/node/childProcessMonitor'; </ins> type WorkspaceId = string;

this._detachInstanceRequestStore = this._register(new RequestStore(undefined, this._logService)); this._detachInstanceRequestStore.onCreateRequest(this._onDidRequestDetach.fire, this._onDidRequestDetach); } <ins> setIgnoreProcessNames(names: string[]): Promise<void> { return new Promise((_resolve, _reject) => { ignoreProcessNames.length = 0; ignoreProcessNames.push(...names); }); } </ins> onPtyHostExit?: Event<number> | undefined; onPtyHostStart?: Event<void> | undefined; onPtyHostUnresponsive?: Event<void> | undefined;

defaultLocation: TerminalLocationString; customGlyphs: boolean; persistentSessionReviveProcess: 'onExit' | 'onExitAndWindowClose' | 'never'; <ins> ignoreProcessNames: string[]; </ins> } export const DEFAULT_LOCAL_ECHO_EXCLUDE: ReadonlyArray<string> = ['vim', 'vi', 'nano', 'tmux'];