microsoft / terminal

The new Windows Terminal and the original Windows console host, all in the same place!
MIT License
94.74k stars 8.2k forks source link

Windows Terminal doesn't start from folder right-click menu #14369

Open gyorokpeter opened 1 year ago

gyorokpeter commented 1 year ago

Windows Terminal version

1.15.2875.0

Windows build number

10.0.22621.819

Other Software

N/A

Steps to reproduce

After installing Windows Terminal, right click in any folder in Windows Explorer and choose "Open in Terminal".

Expected Behavior

Terminal should start up.

Actual Behavior

Nothing happens. However Terminal works if started by other means, such as by running it from the start menu, so the problem must be in the context menu launch method.

zadjii-msft commented 1 year ago

We might need a feedback hub trace on this, so we can get the context menu folks to take a look. I don't recall off the top of my head what the area path for the shell context menu is. The bot will tell you to file this under the "Terminal" path, but you should look for a context menu path instead. (alas, feedback hub is busted on my machine ATM, so I can't figure that out for you).

/feedback

ghost commented 1 year ago

Hi there!

Can you please send us feedback with the Feedback Hub with this issue? Make sure to click the "Start recording" button, then reproduce the issue before submitting the feedback. Once it's submitted, paste the link here so we can more easily find your crash information on the back end?

Thanks!

image

image

image

gyorokpeter commented 1 year ago

https://aka.ms/AAippyc

carlos-zamora commented 1 year ago

Hmm. Could you try doing this?

  1. Open Windows Terminal
  2. Open the drop down menu
  3. shift+click a profile

Does a terminal launch in a new window? This may help us diagnose what specifically is failing.

gyorokpeter commented 1 year ago

That opens a folder in Windows Explorer with the name %LOCALAPPDATA%\Microsoft\WindowsApps\Microsoft.WindowsTerminalPreview_8wekyb3d8bbwe\wt.exe . It's a folder but it's named like an executable file.

carlos-zamora commented 1 year ago

Awesome. Could you run this command: fsutil reparsepoint query %LOCALAPPDATA%\Microsoft\WindowsApps\Microsoft.WindowsTerminalPreview_8wekyb3d8bbwe\wt.exe

It looks like your app execution alias might be broken (as you've probably guessed).

gyorokpeter commented 1 year ago

It says "Error: The file or directory is not a reparse point" (in Hungarian).

zadjii-msft commented 1 year ago

Well that's entirely unexpected! I honestly have no idea how that would happen. You might want to back up your settings.json file file (and possibly state.json in that folder too), delete the bad "wt.exe" folder, and reinstall the Terminal. I have no idea how that would get created as a folder instead of as the app execution alias / reparse point...

gyorokpeter commented 1 year ago

I managed to recreate the symlinks. Now the shift-click method works in a terminal window, but the right-click menu in a folder still doesn't.

carlos-zamora commented 1 year ago

Sorry for the delay, finally coming back to this. It looks like #14637 has presented a potential solution. We would just need some time to implement a similar thing for the shell extension.