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

Generate MSIX when publishing #6262

Merged
merged 1 commit into from
Apr 22, 2022
Merged

Generate MSIX when publishing #6262

merged 1 commit into from
Apr 22, 2022

Conversation

mattleibow
Copy link
Member

@mattleibow mattleibow commented Apr 20, 2022

Description of Change

Produce a MSIX when publishing a MSIX app. This does not attempt to produce a MSIX when publishing an unpackaged app.

I did not condition this on the Configuration (Debug/Release) because I still want to produce a debug app. If you do dotnet publish, then you are obviously wanting to publish.

This new PublishAppxPackage value is not an instruction, but rather a value that something else looks at:

<GenerateMsixAfterTarget Condition="
    '$(GenerateMsixAfterTarget)'=='' and
    '$(PublishAppxPackage)'=='true'">Publish</GenerateMsixAfterTarget>
  <Target Name="GenerateMsixPackage"
          Condition="'$(_GenerateMsixPackage)'=='true' "
          AfterTargets="$(GenerateMsixAfterTarget)"
          DependsOnTargets="$(GenerateMsixPackageDependsOn)" />

Issues Fixed

Fixes #5884

@mattleibow mattleibow added this to the 6.0.300-rc.2 milestone Apr 20, 2022
@mattleibow mattleibow self-assigned this Apr 20, 2022
@mattleibow mattleibow requested a review from Redth April 20, 2022 05:08
@mattleibow mattleibow added area-single-project Splash Screen, Multi-Targeting, MauiFont, MauiImage, MauiAsset, Resizetizer platform/windows 🪟 area-publishing Issues with the app packaging/publishing process (ipk/apk/msix/trimming) labels Apr 20, 2022
@@ -8,6 +8,7 @@
<WinUISDKReferences Condition=" '$(WinUISDKReferences)' == '' and '$(EnableMsixTooling)' == 'true' and ('$(OutputType)' == 'Exe' or '$(OutputType)' == 'WinExe') ">false</WinUISDKReferences>
<GenerateLibraryLayout Condition=" '$(GenerateLibraryLayout)' == '' and '$(EnableMsixTooling)' == 'true' and '$(OutputType)' != 'Exe' and '$(OutputType)' != 'WinExe' ">true</GenerateLibraryLayout>
<WindowsAppSdkBootstrapInitialize Condition=" '$(WindowsAppSdkBootstrapInitialize)' == '' and '$(EnableMsixTooling)' == 'true' and '$(OutputType)' != 'Exe' and '$(OutputType)' != 'WinExe' ">false</WindowsAppSdkBootstrapInitialize>
<PublishAppXPackage Condition=" '$(PublishAppXPackage)' == '' and '$(EnableMsixTooling)' == 'true' and '$(WindowsPackageType)' == 'MSIX' ">true</PublishAppXPackage>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The condition to only generate the MSIX in Release will come later?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is the question. Do you want that? Because I can publish a debug console app. And a debug Android app. So my logic is that publish != configuration.

@mattleibow mattleibow removed the area-single-project Splash Screen, Multi-Targeting, MauiFont, MauiImage, MauiAsset, Resizetizer label Apr 20, 2022
@Redth Redth modified the milestones: 6.0.300-rc.2, 6.0.300-rc.3 Apr 20, 2022
@mattleibow mattleibow changed the base branch from main to release/6.0.3xx-rc2 April 20, 2022 14:45
@mattleibow mattleibow modified the milestones: 6.0.300-rc.3, 6.0.300-rc.2 Apr 20, 2022
@Redth Redth changed the base branch from release/6.0.3xx-rc2 to main April 21, 2022 14:31
@mattleibow mattleibow modified the milestones: 6.0.300-rc.2, 6.0.300-rc.3 Apr 21, 2022
@mattleibow mattleibow merged commit 946686c into main Apr 22, 2022
@mattleibow mattleibow deleted the dev/pub-win branch April 22, 2022 19:58
@github-actions github-actions bot locked and limited conversation to collaborators Dec 23, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-publishing Issues with the app packaging/publishing process (ipk/apk/msix/trimming) platform/windows 🪟
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Publishing a Windows app doesn't produce an msix
3 participants