When I install node, I can't use it in new tab of opend terminal task. #18840

Open
opened 2026-01-31 06:25:59 +00:00 by claunia · 0 comments
Owner

Originally created by @char-46 on GitHub (Nov 6, 2022).

Windows Terminal version

1.16.2642.0

Windows build number

10.0.22621.755

Other Software

No response

Steps to reproduce

  • Open Winodws Terminal
  • Setup node
  • Open new tab on Windows Terminal
  • Type npm

Expected Behavior

When I install node on my PC, It changes PATH environment variable. I expceted it can update its environment automatically. So I open a new tab on a exist window. I expced it can use npm right away.

Actual Behavior

When I typed npm, the powershell tell me that:
npm: The term 'ver' is not recognized as a name of a cmdlet, function, script file, or executable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
I tried use Run command to open a new powershell task to update its environment, but it follows my config then merged to the Windows Terminal window which exists and doesn't update its environment(i.e. the old process wt.exe's environment). So that I still can't use the npm command on the new powershell tab.

why I have to kill all process which running on the old wt process then that I can just use the new environment. if I don't accept that I'll have to make my dessktop mess?

Originally created by @char-46 on GitHub (Nov 6, 2022). ### Windows Terminal version 1.16.2642.0 ### Windows build number 10.0.22621.755 ### Other Software _No response_ ### Steps to reproduce * Open Winodws Terminal * Setup node * Open new tab on Windows Terminal * Type npm ### Expected Behavior When I install node on my PC, It changes PATH environment variable. I expceted it can update its environment automatically. So I open a new tab on a exist window. I expced it can use `npm` right away. ### Actual Behavior When I typed `npm`, the powershell tell me that: `npm: The term 'ver' is not recognized as a name of a cmdlet, function, script file, or executable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.` I tried use Run command to open a new powershell task to update its environment, but it follows my config then merged to the Windows Terminal window which exists and doesn't update its environment(i.e. the old process wt.exe's environment). So that I still can't use the `npm` command on the new powershell tab. why I have to kill all process which running on the old wt process then that I can just use the new environment. if I don't accept that I'll have to make my dessktop mess?
claunia added the Issue-BugResolution-Duplicate labels 2026-01-31 06:25:59 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#18840