Identify WindowsTerminal process ID #7865

Open
opened 2026-01-31 01:14:32 +00:00 by claunia · 0 comments
Owner

Originally created by @jdhitsolutions on GitHub (May 1, 2020).

Description of the new feature/enhancement

I'd like a way to identify the process ID associated with a Windows Terminal session. In PowerShell, I can see the session and profile ID variables. And it is easy enough to run Get-Process and find the Windows Terminal process. But what if there are 2 instances running? How can I tell which ID goes with which?

Proposed technical implementation details (optional)

PowerShell has a built-in variable $pid that helps me identify the current PowerShell process. It would be nice to either create a variable like $wtpid. Or add another environment variable that identifies the process ID of this Windows Terminal instance.

Originally created by @jdhitsolutions on GitHub (May 1, 2020). # Description of the new feature/enhancement I'd like a way to identify the process ID associated with a Windows Terminal session. In PowerShell, I can see the session and profile ID variables. And it is easy enough to run Get-Process and find the Windows Terminal process. But what if there are 2 instances running? How can I tell which ID goes with which? # Proposed technical implementation details (optional) PowerShell has a built-in variable `$pid` that helps me identify the current PowerShell process. It would be nice to either create a variable like `$wtpid`. Or add another environment variable that identifies the process ID of *this* Windows Terminal instance.
claunia added the Issue-FeatureNeeds-Tag-FixResolution-Won't-Fix labels 2026-01-31 01:14:32 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#7865