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

Splitting panes using keyboard shortcut does not persist CWD #12720

Closed
ashishvinayak opened this issue Mar 18, 2022 · 2 comments
Closed

Splitting panes using keyboard shortcut does not persist CWD #12720

ashishvinayak opened this issue Mar 18, 2022 · 2 comments
Labels
Issue-Bug It either shouldn't be doing this or needs an investigation. Issue-Question For questions or discussion Needs-Attention The core contributors need to come back around and look at this ASAP. 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 Resolution-Answered Related to questions that have been answered

Comments

@ashishvinayak
Copy link

Windows Terminal version

1.11.3471.0

Windows build number

10.0.19043.0

Other Software

Powershell 7.2.1
git-posh

Steps to reproduce

Tutorial mentions that the prompt can be updated to make Powershell emit an escape sequence before creating the new pane. I have added the script to my current profile.
Splitting panes with the mouse splits in CWD but not with the keyboard.

To reproduce:

  1. Update function prompt as provided in the line
  2. Split panes using the keyboard.

Same behavior is seen when starting new tabs with the keyboard.

Expected Behavior

Split pane in the current working directory.

Actual Behavior

Splitting pane in the startingDirectory of the profile

@ashishvinayak ashishvinayak added the Issue-Bug It either shouldn't be doing this or needs an investigation. label Mar 18, 2022
@ghost ghost added Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Mar 18, 2022
@zadjii-msft
Copy link
Member

What keyboard shortcut are you using, and which action is it performing? splitPane will only duplicate the path if the action is configured with "splitMode": "duplicate". Notably, the default split pane shortcuts don't include this:

{ "command": { "action": "splitPane", "split": "up" } },
{ "command": { "action": "splitPane", "split": "down" }, "keys": "alt+shift+-" },
{ "command": { "action": "splitPane", "split": "left" } },
{ "command": { "action": "splitPane", "split": "right" }, "keys": "alt+shift+plus" },

@zadjii-msft zadjii-msft added Issue-Question For questions or discussion Resolution-Answered Related to questions that have been answered Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something labels Mar 18, 2022
@ashishvinayak
Copy link
Author

Okay that worked. Once I add the ´splitMode` to my JSON I am able to duplicate the path as well. Thank you.

@ghost ghost added Needs-Attention The core contributors need to come back around and look at this ASAP. and removed Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something labels Mar 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue-Bug It either shouldn't be doing this or needs an investigation. Issue-Question For questions or discussion Needs-Attention The core contributors need to come back around and look at this ASAP. 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 Resolution-Answered Related to questions that have been answered
Projects
None yet
Development

No branches or pull requests

2 participants