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

Enable Ready To Run option for ClickOnce publish #6244

Merged
merged 1 commit into from Mar 13, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
21 changes: 21 additions & 0 deletions src/Tasks/Microsoft.Common.CurrentVersion.targets
Expand Up @@ -4234,6 +4234,27 @@ Copyright (C) Microsoft Corporation. All rights reserved.
Condition="'$(_DeploymentSignClickOnceManifests)'=='true' and '$(_DeploymentLauncherBased)' == 'true' and '$(PublishSingleFile)' == 'true'"
/>

<!--
If ReadyToRun is enabled in loose files scenario, we need to remove entries of the IL images that have gone through R2R
compiler and replace them with the entries for their R2R images. The R2R application image also needs to be signed if necessary.
-->

<ItemGroup Condition="'$(PublishReadyToRun)' == 'true' and '$(PublishSingleFile)' != 'true'">
<_ManifestManagedReferences Remove="@(_ReadyToRunCompileList)" />
<_ClickOnceFiles Remove="@(_ReadyToRunCompileList)" />
<_ClickOnceFiles Include="@(_ReadyToRunFilesToPublish)" />
<_ClickOnceTargetFile Include="@(_ReadyToRunFilesToPublish)" Condition="'%(Filename)%(Extension)' == '$(TargetFileName)'" />
</ItemGroup>

<!-- Sign application image created by R2R -->
<SignFile
CertificateThumbprint="$(_DeploymentResolvedManifestCertificateThumbprint)"
TimestampUrl="$(ManifestTimestampUrl)"
SigningTarget="@(_ClickOnceTargetFile)"
TargetFrameworkVersion="$(TargetFrameworkVersion)"
TargetFrameworkIdentifier="$(TargetFrameworkIdentifier)"
Condition="'$(_DeploymentSignClickOnceManifests)' == 'true' and '$(PublishReadyToRun)' == 'true' and '$(PublishSingleFile)' != 'true'" />

<!-- Copy the application executable from Obj folder to app.publish folder.
This is being done to avoid Windows Forms designer memory issues that can arise while operating directly on files located in Obj directory. -->
<Copy
Expand Down