wt new-tab -d {path} does not work if path is the root directory of a drive in quotes #24017

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

Originally created by @driver1998 on GitHub (Jan 28, 2026).

Windows Terminal version

1.24.2682.0

Windows build number

10.0.26200.7623

Other Software

Custom Context Menu 5.7.0 (https://github.com/ikas-mc/ContextMenuForWindows11)

Steps to reproduce

This works: wt new-tab -d "C:\Program Files"

This also works: wt new-tab -d C:\

But this doesn't: wt new-tab -d "C:\"

This makes it a bit annoying in automation scenarios.

Like I would like to have a custom action in Explorer that opens up Terminal with a specific profile in the current directory, something like wt new-tab -d "{path}" won't work at the root directory, but will work in everywhere else.

Expected Behavior

wt new-tab -d "C:\" should work as well.

Actual Behavior

It errors with

[出现错误 2147942667 (0x8007010b) (启动“"C:\Program Files\PowerShell\7\pwsh.exe"”时)]
无法访问启动目录“C:\"”
Originally created by @driver1998 on GitHub (Jan 28, 2026). ### Windows Terminal version 1.24.2682.0 ### Windows build number 10.0.26200.7623 ### Other Software Custom Context Menu 5.7.0 (https://github.com/ikas-mc/ContextMenuForWindows11) ### Steps to reproduce This works: `wt new-tab -d "C:\Program Files"` This also works: `wt new-tab -d C:\` But this doesn't: `wt new-tab -d "C:\"` This makes it a bit annoying in automation scenarios. Like I would like to have a custom action in Explorer that opens up Terminal with a specific profile in the current directory, something like `wt new-tab -d "{path}"` won't work at the root directory, but will work in everywhere else. ### Expected Behavior `wt new-tab -d "C:\"` should work as well. ### Actual Behavior It errors with ``` [出现错误 2147942667 (0x8007010b) (启动“"C:\Program Files\PowerShell\7\pwsh.exe"”时)] 无法访问启动目录“C:\"” ```
claunia added the Needs-TriageIssue-Bug labels 2026-01-31 08:59:09 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#24017