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

Launching any cli app(such as powershell, wsl) sets the tab's icon as the default profile's icon #10669

Closed
rounk-ctrl opened this issue Jul 15, 2021 · 3 comments · Fixed by #11022
Labels
Area-DefApp Area-Settings Issues related to settings and customizability, for console or terminal Issue-Task It's a feature request, but it doesn't really need a major design. Product-Terminal The new Windows Terminal. Resolution-Fix-Committed Fix is checked in, but it might be 3-4 weeks until a release.
Milestone

Comments

@rounk-ctrl
Copy link

rounk-ctrl commented Jul 15, 2021

Windows Terminal version (or Windows build number)

10.0.22000.65, 1.10.1933.0

Other Software

No response

Steps to reproduce

Set default terminal application as windows terminal preview.
Use search to open powershell(or wsl)
See tab icon as the default profile's icon

Expected Behavior

See the tab's icon as the app's icon.

Actual Behavior

The tab's icon is the default profile's icon.

@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 Jul 15, 2021
@rounk-ctrl rounk-ctrl changed the title launching any cli app(such as powershell, wsl) sets the tab's icon as cmd's icon Launching any cli app(such as powershell, wsl) sets the tab's icon as cmd's icon Jul 15, 2021
@rounk-ctrl rounk-ctrl changed the title Launching any cli app(such as powershell, wsl) sets the tab's icon as cmd's icon Launching any cli app(such as powershell, wsl) sets the tab's icon as the default profile's icon Jul 15, 2021
@zadjii-msft
Copy link
Member

You know, I could have sworn we had an issue tracking this, but looking at https://github.com/microsoft/terminal/issues?q=is%3Aopen+is%3Aissue+label%3AArea-DefApp, looks like we don't.

I believe the plan of record is to use the settings in profiles.defaults for connections spawned via the defterm connection.

@zadjii-msft zadjii-msft added Area-DefApp Area-Settings Issues related to settings and customizability, for console or terminal Issue-Task It's a feature request, but it doesn't really need a major design. Product-Terminal The new Windows Terminal. labels Jul 15, 2021
@ghost ghost removed the Needs-Tag-Fix Doesn't match tag requirements label Jul 15, 2021
@zadjii-msft zadjii-msft added this to the Terminal v2.0 milestone Jul 15, 2021
@zadjii-msft
Copy link
Member

Maintainer note: When we get around to doing this, we should simultaneously do #6776, with a similar style fix.

@DHowett DHowett removed the Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting label Jul 22, 2021
DHowett added a commit that referenced this issue Aug 23, 2021
Right now, we store GUIDs in panes and most of the functions for interacting
with profiles on the settings model take GUIDs and look up profiles.

This pull request changes how we store and look up profiles to prefer profile
objects. Panes store strong references to their originating profiles, which
simplifies settings lookup for CloseOnExit and the bell settings. In fact,
deleting a pane's profile no longer causes it to forget which CloseOnExit
setting applies to it. Duplicating a pane that is hosting a deleted profile
(#5047) now duplicates the profile, even though it is otherwise unreachable.

This makes the world more consistent and allows us to _eventually_ support panes
hosting profiles that do not have GUIDs that can be looked up in the profile
list. This is a gateway to #6776 and #10669, and consolidating the profile
lookup logic will help with #10952.

PR #10588 introduced TerminalSettings::CreateWithProfile and made
...CreateWithProfileByID a thin wrapper over top it, which looked up the profile
by GUID before proceeding. It has also been removed, as its last caller is gone.

Closes #5047
@ghost ghost added the In-PR This issue has a related PR label Aug 24, 2021
@ghost ghost closed this as completed in #11022 Aug 25, 2021
ghost pushed a commit that referenced this issue Aug 25, 2021
This pull request introduces our first use of the "base" profile as an
actual profile. Incoming commandlines from `wt foo` *and* default
terminal handoffs will be hosted in the base profile.

**THIS IS A BREAKING CHANGE** for user behavior.

The original behavior where commandlines were hosted in the "default"
profile (in most cases, Windows PowerShell) led to user confusion: "why
does cmd use my powershell icon?" and "why does the title say
PowerShell?". Making this change unifies the user experience so that we
can land commandline detection in #10952.

Users who want the original behavior can get it back for commandline
invocation by specifying a profile using the `-p` argument, as in `wt -p
PowerShell -- cmd`.

As a temporary stopgap, users who attempt to duplicate the base profile
will get their specified default profile until we land #5047.

This feature is hidden behind the same feature flag that controls the
visibility of base/"Defaults" in the settings UI.

Fixes #10669
Related to #6776
@ghost ghost added Resolution-Fix-Committed Fix is checked in, but it might be 3-4 weeks until a release. and removed In-PR This issue has a related PR labels Aug 25, 2021
@ghost
Copy link

ghost commented Aug 31, 2021

🎉This issue was addressed in #11022, which has now been successfully released as Windows Terminal Preview v1.11.2421.0.:tada:

Handy links:

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-DefApp Area-Settings Issues related to settings and customizability, for console or terminal Issue-Task It's a feature request, but it doesn't really need a major design. Product-Terminal The new Windows Terminal. Resolution-Fix-Committed Fix is checked in, but it might be 3-4 weeks until a release.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants