WT does not open in the current folder when typing 'wt' in the File Explorer address bar #11155

Closed
opened 2026-01-31 02:40:07 +00:00 by claunia · 8 comments
Owner

Originally created by @claudiofreda on GitHub (Oct 24, 2020).

A very common shortcut to open a powershell or cmd window in the current File Explorer folder is to type 'cmd' or 'powershell' into the address bar. This passes the current folder as an argument to the shell, which opens alread cd'd into that folder.

This does not work with windows terminal, and typing 'wt' into the address bar results into opening 'wt' with the user home folder as current directory.

Surprisingly, this even works for WSL prompts.

I argue this is a desirable feature and behaviour and should be introduced to Windows Terminal.

Originally created by @claudiofreda on GitHub (Oct 24, 2020). A very common shortcut to open a powershell or cmd window in the current File Explorer folder is to type 'cmd' or 'powershell' into the address bar. This passes the current folder as an argument to the shell, which opens alread cd'd into that folder. This does not work with windows terminal, and typing 'wt' into the address bar results into opening 'wt' with the user home folder as current directory. Surprisingly, this even works for WSL prompts. I argue this is a desirable feature and behaviour and should be introduced to Windows Terminal.
claunia added the Issue-QuestionNeeds-Tag-FixResolution-Answered labels 2026-01-31 02:40:07 +00:00
Author
Owner

@obsgolem commented on GitHub (Oct 26, 2020):

This feature does exist, it is just not enabled by default. To enable it, add

"startingDirectory" : ".",

to your default profile.

@obsgolem commented on GitHub (Oct 26, 2020): This feature does exist, it is just not enabled by default. To enable it, add ``` "startingDirectory" : ".", ``` to your default profile.
Author
Owner

@DHowett commented on GitHub (Oct 26, 2020):

Or, you can run wt -d .. This has been discussed in a bunch of places on our repo, and none of the solutions we can offer are quite beloved. 😄

@DHowett commented on GitHub (Oct 26, 2020): Or, you can run `wt -d .`. This has been discussed in a bunch of places on our repo, and none of the solutions we can offer are quite beloved. :smile:
Author
Owner

@Lycantant commented on GitHub (Nov 6, 2020):

This feature does exist, it is just not enabled by default. To enable it, add

"startingDirectory" : ".",

to your default profile.

Or, you can run wt -d .. This has been discussed in a bunch of places on our repo, and none of the solutions we can offer are quite beloved. 😄

thanks, it work 😁

@Lycantant commented on GitHub (Nov 6, 2020): > > > This feature does exist, it is just not enabled by default. To enable it, add > > ``` > "startingDirectory" : ".", > ``` > > to your default profile. > > > Or, you can run `wt -d .`. This has been discussed in a bunch of places on our repo, and none of the solutions we can offer are quite beloved. 😄 thanks, it work 😁
Author
Owner

@ahmed-el-awad commented on GitHub (Apr 8, 2024):

This feature does exist, it is just not enabled by default. To enable it, add

"startingDirectory" : ".",

to your default profile.

For anyone reading this in the future, in settings.json you should add it here.

"profiles": {
    "defaults": {
      "startingDirectory": ".",
      ...
      }
  }

Not at the top of settings.json (like I assumed).
I got this solution from https://superuser.com/a/1528644/1837537.

@ahmed-el-awad commented on GitHub (Apr 8, 2024): > This feature does exist, it is just not enabled by default. To enable it, add > > ``` > "startingDirectory" : ".", > ``` > > to your default profile. For anyone reading this in the future, in `settings.json` you should add it here. ``` "profiles": { "defaults": { "startingDirectory": ".", ... } } ``` Not at the top of `settings.json` (like I assumed). I got this solution from https://superuser.com/a/1528644/1837537.
Author
Owner

@claudiofreda commented on GitHub (May 6, 2024):

I guess the question that naturally comes to mind is: why isn't this default?

@claudiofreda commented on GitHub (May 6, 2024): I guess the question that naturally comes to mind is: why isn't this default?
Author
Owner

@zadjii-msft commented on GitHub (May 6, 2024):

@claudiofreda There's commentary in #3547, #878, and the very many linked threads as to why this is the way it is.

@zadjii-msft commented on GitHub (May 6, 2024): @claudiofreda There's commentary in #3547, #878, and the very many linked threads as to why this is the way it is.
Author
Owner

@thedarkfalcon commented on GitHub (Nov 12, 2024):

@zadjii-msft you posted links to threads where everyone hates the behaviour. Opening in a users home directory is to prevent it from opening in system32. But always opening in users home directory is worse behaviour in my opinion than opening in the current directory. CMD opens in system32 by default, but also opens in whatever directory you launch it from, this is far preferable in my opinion.

@thedarkfalcon commented on GitHub (Nov 12, 2024): @zadjii-msft you posted links to threads where everyone hates the behaviour. Opening in a users home directory is to prevent it from opening in system32. But always opening in users home directory is worse behaviour in my opinion than opening in the current directory. CMD opens in system32 by default, but also opens in whatever directory you launch it from, this is far preferable in my opinion.
Author
Owner

@avail commented on GitHub (Apr 24, 2025):

this only started happening with 1.23.
https://github.com/user-attachments/assets/18eea4e9-dd59-4486-827e-62353607da4a

@avail commented on GitHub (Apr 24, 2025): this only started happening with 1.23. https://github.com/user-attachments/assets/18eea4e9-dd59-4486-827e-62353607da4a
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#11155