wt shortcut not opening in the requested context from Address bar when Starting directory option is customized #15948

Closed
opened 2026-01-31 04:53:09 +00:00 by claunia · 3 comments
Owner

Originally created by @egvijayanand on GitHub (Nov 22, 2021).

Windows Terminal version

1.11.2921.0

Windows build number

10.0.22000.348

Other Software

No response

Steps to reproduce

  • Customize the Starting directory for the Command Prompt tab in Windows Terminal Settings
  • Open any folder (apart from Starting directory) in the File Explorer and type wt in the address bar to launch the Terminal
  • Fails to persist the launch context and instead opens with the Starting directory

Expected Behavior

During the launch, the Terminal should retain the launch context for specific scenarios like Address bar launch and Context menu launch

Actual Behavior

Always opens with the Starting directory customization, this is fine for direct launch whereas when launched from the address bar or from the context menu of a folder, then it is expected to retain the launch context.

Originally created by @egvijayanand on GitHub (Nov 22, 2021). ### Windows Terminal version 1.11.2921.0 ### Windows build number 10.0.22000.348 ### Other Software _No response_ ### Steps to reproduce * Customize the `Starting directory` for the `Command Prompt` tab in Windows Terminal `Settings` * Open any folder (apart from Starting directory) in the File Explorer and type `wt` in the address bar to launch the Terminal * Fails to persist the launch context and instead opens with the Starting directory ### Expected Behavior During the launch, the Terminal should retain the launch context for specific scenarios like Address bar launch and Context menu launch ### Actual Behavior Always opens with the `Starting directory` customization, this is fine for direct launch whereas when launched from the address bar or from the context menu of a folder, then it is expected to retain the launch context.
claunia added the Resolution-Duplicate label 2026-01-31 04:53:09 +00:00
Author
Owner

@zadjii-msft commented on GitHub (Nov 22, 2021):

This question's been answered a huge number of times before. Please search before filing new issues.

/dup #878

Specifically, there are more details as to "why" here: https://github.com/microsoft/terminal/issues/878#issuecomment-579508860

@zadjii-msft commented on GitHub (Nov 22, 2021): This question's been answered a huge number of times before. Please [search before filing new issues. ](https://github.com/microsoft/terminal/issues?q=is%3Aissue+%22explorer+address+bar%22) /dup #878 Specifically, there are more details as to "why" here: https://github.com/microsoft/terminal/issues/878#issuecomment-579508860
Author
Owner

@ghost commented on GitHub (Nov 22, 2021):

Hi! We've identified this issue as a duplicate of another one that already exists on this Issue Tracker. This specific instance is being closed in favor of tracking the concern over on the referenced thread. Thanks for your report!

@ghost commented on GitHub (Nov 22, 2021): Hi! We've identified this issue as a duplicate of another one that already exists on this Issue Tracker. This specific instance is being closed in favor of tracking the concern over on the referenced thread. Thanks for your report!
Author
Owner

@egvijayanand commented on GitHub (Dec 1, 2021):

Hope the original issue #878 gets an official resolution at the earliest.

For time being, found a workaround by creating a batch file in the profile folder (so that it is available whenever I log in) with the below command in it to invoke the Windows Terminal with the right starting directory.

Name the batch file, like wtd.bat, as per your convenience as that will become the command to execute on the address bar, wtd in this case.

wt.exe --startingDirectory "%cd%"
@egvijayanand commented on GitHub (Dec 1, 2021): Hope the original issue #878 gets an official resolution at the earliest. For time being, found a workaround by creating a batch file in the profile folder (so that it is available whenever I log in) with the below command in it to invoke the `Windows Terminal` with the right starting directory. Name the batch file, like wtd.bat, as per your convenience as that will become the command to execute on the address bar, `wtd` in this case. ``` wt.exe --startingDirectory "%cd%" ```
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#15948