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

Opening a New Pane with "-" or "+" Opens the First Profile, Regardless of Current Profile #7657

Closed
Wes-Kuegler opened this issue Sep 17, 2020 · 11 comments · Fixed by #16951
Closed
Assignees
Labels
Area-Settings Issues related to settings and customizability, for console or terminal Help Wanted We encourage anyone to jump in on these. In-PR This issue has a related PR Issue-Task It's a feature request, but it doesn't really need a major design. Needs-Tag-Fix Doesn't match tag requirements Product-Terminal The new Windows Terminal.

Comments

@Wes-Kuegler
Copy link

Description

When opening a new split pane with alt+shift+d, the new pane will be of the same terminal profile as the pane from which it was spawned. However, when specifying a vertical or horizontal split pane with alt+shift+plus or alt+shift+minus, the new pane is always of the first terminal profile listed under "profiles" in "settings.json."
This is undesirable for two reasons:

  1. It can result in terminal tabs of mixed profiles. In my use case, it results in a terminal tab running the Powershell profile, with a split pane running the Ubuntu WSL profile. It's possible that this is intended behavior, but I found it confusing.
  2. There is currently no way (that I know of) to open a new split pane and specify a vertical or horizontal split for any profile except for the first one. Attempting to specify a vertical or horizontal split for any profile other than the first always results in a split pane running the first profile.

Expected Behavior

I would expect that behavior (in terms of which profile is used for the pane) would at least be consistent between alt+shift+d and alt+shift+minus/plus. Optimally, I would expect that all three shortcuts would always spawn a new split pane of the same profile that was active when the shortcut was entered.

@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 Sep 17, 2020
@Wes-Kuegler
Copy link
Author

Wes-Kuegler commented Sep 17, 2020

Windows Terminal Issue

Attached is an image of a terminal tab running Powershell (my # 2 profile) in the left (original) pane. alt+shift+d was used to open the pane in the top right, which is (correctly) running Powershell. alt+shift+minus was used from the top right pane to open the bottom right pane, which is (incorrectly) running WSL Ubuntu, my # 1 profile. Note the different theme, as well as the tab title changing to that of my Ubuntu WSL profile.

@DHowett
Copy link
Member

DHowett commented Sep 18, 2020

So, we've heard this issue time and time again and we've always closed it and said "you can set these bindings up yourself; just add "split": "duplicate" to your version of the split pane bindings". I'm no longer convinced that our default behavior should be so... weird.

If a bunch of users are asking for it, and telling us that Terminal's done something unexpected, we should probably do the "expected" thing.

@cinnamon-msft, @zadjii-msft: I propose that we make the split pane bindings duplicate by default.

@DHowett DHowett added Area-Settings Issues related to settings and customizability, for console or terminal Issue-Question For questions or discussion Issue-Task It's a feature request, but it doesn't really need a major design. Product-Terminal The new Windows Terminal. and removed Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting labels Sep 18, 2020
@ghost ghost removed the Needs-Tag-Fix Doesn't match tag requirements label Sep 18, 2020
@DHowett DHowett added this to the Terminal v1.x milestone Sep 18, 2020
@cinnamon-msft
Copy link
Contributor

I'm down for this. 👍

@rosti-il
Copy link

I faced this problem too and almost started to write a new bug report.
I see two ways of fixing it:

  1. Add "splitMode": "duplicate" into the default bindings of alt+shift+plus and alt+shift+minus, as already mentioned above. But users who are good with current key bindings of split pane may not like this change.
  2. Add following two new bindings by default:
    { "command": { "action": "splitPane", "split": "horizontal", "splitMode": "duplicate"}, "keys": "alt+shift+numpad_minus" },
    { "command": { "action": "splitPane", "split": "vertical", "splitMode": "duplicate"}, "keys": "alt+shift+numpad_plus" }
    
    With those new bindings, when you split, for example, a pane of an SSH profile you may choose between opening a new SSH session into the same remote machine or the default profile that's usually a local CMD or Powershell. Also it doesn't change an existing behavior and users that are good with the current default bindings of split pane will not complain.

@DHowett

So, we've heard this issue time and time again and we've always closed it and said "you can set these bindings up yourself; just add "split": "duplicate" to your version of the split pane bindings".

Please don't close without fixing.

@Don-Vito
Copy link
Contributor

Don-Vito commented Feb 7, 2021

If Kayla agreed, any reason we do not enable it by default?

@zadjii-msft zadjii-msft modified the milestones: Terminal v2.0, Backlog Jan 4, 2022
@amine-aboufirass
Copy link

I'm also of the opinion that this behavior should occur by default. Seems counterintuitive that splitting panes results in a new profile.

@leet0rz
Copy link

leet0rz commented Jun 15, 2022

Yeah, this should be default and is still an issue, it is still not duplicate of original shell you've opened by default when opening new split it opens the "first profile" and not the one you are working with.

@dovholuknf
Copy link

I'd just like to be able to split a pane and choose the profile even if i had to do it with my mouse. I still figure out how to do that. I've just resorted to using bash for everything and then immediately running cmd.exe or pwsh.exe as i need to but that's a bummer...

I'd really appreciate a key to add to let me pick whatever profile i want... like when i do "shift-alt-minus" the default profile is used, cool but if I do "shift-ctrl-alt-minus" then i get to pick what profile to use

@zadjii-msft zadjii-msft added the Needs-Discussion Something that requires a team discussion before we can proceed label Sep 18, 2023
@zadjii-msft zadjii-msft removed Issue-Question For questions or discussion Needs-Discussion Something that requires a team discussion before we can proceed labels Oct 2, 2023
@zadjii-msft zadjii-msft modified the milestones: Backlog, Terminal v1.20 Oct 2, 2023
@zadjii-msft
Copy link
Member

Looping back on this after years: team consensus is that this is a good idea and we're gonna do this for 1.20. As well as include the old JSON in the patch notes, for users who want to go back. Thanks for the patience folks ☺️

@zadjii-msft zadjii-msft added the Help Wanted We encourage anyone to jump in on these. label Oct 2, 2023
@Wes-Kuegler
Copy link
Author

Looping back on this after years: team consensus is that this is a good idea and we're gonna do this for 1.20. As well as include the old JSON in the patch notes, for users who want to go back. Thanks for the patience folks ☺️

The system works!

@zadjii-msft zadjii-msft self-assigned this Feb 8, 2024
@microsoft-github-policy-service microsoft-github-policy-service bot added the In-PR This issue has a related PR label Mar 27, 2024
github-merge-queue bot pushed a commit that referenced this issue Apr 5, 2024
… profile (#16951)

As we discussed in length over at #7657. 

This changes the default <kbd>alt+shift+-</kbd> and
<kbd>alt+shift+plus</kbd> keybindings to split panes by duplicating the
pane by default.

Closes #7657
@microsoft-github-policy-service microsoft-github-policy-service bot added the Needs-Tag-Fix Doesn't match tag requirements label Apr 5, 2024
@b-hayes
Copy link

b-hayes commented May 21, 2024

I see no reason to be willfully ignorant of the users' context by default. I would have filed a bug for this behaviour too if I didn't see this.

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. In-PR This issue has a related PR Issue-Task It's a feature request, but it doesn't really need a major design. Needs-Tag-Fix Doesn't match tag requirements Product-Terminal The new Windows Terminal.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

10 participants