Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Customizing right-click context menu "open Windows terminal here" for Cygwin (and other) profile #14388

Closed
CC-Hsu opened this issue Nov 14, 2022 · 6 comments
Labels
Area-Settings Issues related to settings and customizability, for console or terminal Help Wanted We encourage anyone to jump in on these. Product-Terminal The new Windows Terminal. Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.

Comments

@CC-Hsu
Copy link

CC-Hsu commented Nov 14, 2022

Description of the new feature/enhancement

Hi, Team,

Microsoft Terminal supports customizing profile and Cygwin is one of supported configuration.

However, currently right-click context menu "open Windows terminal here" (my environment: Windows10) does not work great with Cygwin since Cygwin recoginzes Unix-like path expression.

In Cygwin, one can execute cygpath -u "Windows Full Directory Path Name" to map to the corresponding representation, and cd $(cygpath -u 'Windows Full Directory Path Name') to open Cygwin in the desired directory.

As far as I know, one can adjust from RegEdit, but it requires in-depth knowledge about RegEdit and search for right config to edit.

So it would be helpful if Microsoft Terminal Can support customizing right-click context menu command, supporting passing full Windows directory path as variable for customized command.

Besides, I find there are some similar feature requests about WSL environment #12961, I guess similar trick may also works for WSL, too.

Proposed technical implementation details (optional)

Adding a new profile key/value for customizing "right-click context menu" action (in the following setting page screenshot), and provide some shortcut that represents directory path for substitute.
image

Best Regards.

@CC-Hsu CC-Hsu added the Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. label Nov 14, 2022
@ghost ghost added Needs-Tag-Fix Doesn't match tag requirements Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting labels Nov 14, 2022
@lhecker
Copy link
Member

lhecker commented Nov 15, 2022

Solving this issue seems closely related to solving #1772, right?

@lhecker lhecker added Help Wanted We encourage anyone to jump in on these. Area-Settings Issues related to settings and customizability, for console or terminal Product-Terminal The new Windows Terminal. labels Nov 15, 2022
@ghost ghost removed the Needs-Tag-Fix Doesn't match tag requirements label Nov 15, 2022
@zadjii-msft
Copy link
Member

tbh I was gonna double check what bash --login -i does. That might always ignore the CWD it was started in. There might be some other flag to bash that might let it be a login shell, but also respect the CWD it was started in.

That was my first idea.

@CC-Hsu
Copy link
Author

CC-Hsu commented Nov 15, 2022

Hi,

I explore RegEdit (inspired by this old post) and find that Cygwin itself provides another script /usr/bin/xhere (in its core package Chere) to start a Cygwin bash shell in specified directory, accepting the same argument %V as vanilla Powershell.
image
image

And it also displays a way that WSL open in specified path, which works similarly as git bash by providing --cd option.
image

In the above screenshot, it seems that it does not necessary to start a bash shell with --login -i option? But I am not quite sure about it. 😅

Best Regards.

@zadjii-msft zadjii-msft removed the Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. label Nov 15, 2022
@zadjii-msft
Copy link
Member

Thanks for the suggestion! This is actually already being tracked by another issue on our repo - please refer to #6111 for more discussion.

/dup #6111

@microsoft-github-policy-service
Copy link
Contributor

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!

@microsoft-github-policy-service microsoft-github-policy-service bot added Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing. and removed Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting labels Mar 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Settings Issues related to settings and customizability, for console or terminal Help Wanted We encourage anyone to jump in on these. Product-Terminal The new Windows Terminal. Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.
Projects
None yet
Development

No branches or pull requests

3 participants