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

Prevent mobile and lib templates from opening editors if in VS #12756

Merged
merged 1 commit into from
Jan 19, 2023

Conversation

jknaudt21
Copy link
Contributor

@jknaudt21 jknaudt21 commented Jan 18, 2023

With the Maui overview page in VS, it doesn't quite make sense to have the other documents open on project creation. The overview page only displays in the class library and application projects.
image

Description of Change

Added HostIdentifier != \"vs\" to the post action condition. That way the action isn't executed when VS is creating a new project.

Issues Fixed

Fixes #12755

With the Maui overview page in the editor, it doesn't quite make sense to have the other documents open on project creation.
@ghost ghost added the community ✨ Community Contribution label Jan 18, 2023
@ghost
Copy link

ghost commented Jan 18, 2023

Hey there @jknaudt21! Thank you so much for your PR! Someone from the team will get assigned to your PR shortly and we'll get it reviewed.

@dnfadmin
Copy link

dnfadmin commented Jan 18, 2023

CLA assistant check
All CLA requirements met.

@BretJohnson
Copy link
Member

We want the new behavior for VS Windows, but not VS Mac (which doesn't yet show overview UI and thus should still show xaml).
@jknaudt21 - Do you know if HostIdentifier = "vs" is NOT true for VSMac - if VSMac has a different HostIdentifier? If not, may need to add another check to differentiate VS Windows from VS Mac. Can you test the template update on VSMac, to ensure it does the right thing?

@mattleibow
Copy link
Member

Should this happen for blazor too?

@BretJohnson
Copy link
Member

Not Blazor, not today. Maybe in the future there will be a version of the overview ui for MAUI Blazor apps, but today that ui is just intended for Maui XAML.

@mattleibow
Copy link
Member

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 2 pipeline(s).

@jknaudt21
Copy link
Contributor Author

The post action should trigger on VSMac. According from a conversation I had with Phil Henning, the HostIdentifier for vsmac is "vsmac".

@mattleibow mattleibow merged commit 4f3a72a into dotnet:main Jan 19, 2023
@Redth
Copy link
Member

Redth commented Jan 25, 2023

/backport to net7.0

@github-actions
Copy link
Contributor

Started backporting to net7.0: https://github.com/dotnet/maui/actions/runs/4007701254

@Eilon Eilon added the area-templates Project templates, Item Templates for Blazor and MAUI label Jan 25, 2023
@PureWeen PureWeen added backport/suggested The PR author or issue review has suggested that the change should be backported. backport/approved After some discussion or review, this PR or change was approved to be backported. labels Mar 9, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Dec 13, 2023
@samhouts samhouts added the fixed-in-8.0.0-preview.1.7762 Look for this fix in 8.0.0-preview.1.7762! label Aug 2, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-controls-editor Editor area-templates Project templates, Item Templates for Blazor and MAUI backport/approved After some discussion or review, this PR or change was approved to be backported. backport/suggested The PR author or issue review has suggested that the change should be backported. community ✨ Community Contribution fixed-in-8.0.0-preview.1.7762 Look for this fix in 8.0.0-preview.1.7762!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

New Maui projects should only open the Overview Page in VS
8 participants