提交 15fde616 编写于 作者: T Tom Meschter

Reference XliffTasks conditionally

Go back to only bringing in the `XliffTasks` package in projects with
shipping binaries. It turns out some non-shipping projects use a
different set of NuGet feeds that do not include `XliffTasks`, causing
the signed build to fail when we try to restore them.

This also requires we update the loc check to go through a target
conditioned on shipping projects, since the
`EnsureAllResourcesTranslated` target will no longer be available in all
projects.
上级 7aca8346
......@@ -38,15 +38,10 @@
</PropertyGroup>
<ItemGroup>
<PackageReference Include="XliffTasks" Version="$(XliffTasksVersion)" PrivateAssets="All" />
<PackageReference Include="XliffTasks" Version="$(XliffTasksVersion)" PrivateAssets="All" Condition="'$(NonShipping)' != 'true'" />
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="$(MicrosoftSourceLinkGitHubVersion)" PrivateAssets="All" />
</ItemGroup>
<PropertyGroup>
<!-- Disable localization for non-shipping projects -->
<EnableXlfLocalization Condition="'$(NonShipping)' == 'true'">false</EnableXlfLocalization>
</PropertyGroup>
<Choose>
<When Condition="'$(SignAssembly)' == 'true'">
<Choose>
......@@ -500,4 +495,13 @@
</PropertyGroup>
<Import Project="RepoToolset\SymStore.targets" />
<!--
Delegates to XliffTasks to validate that all localizable resources have been translated.
We can't use EnsureAllResoucesTranslated directly because the XliffTasks package is only pulled in by projects that
produce shipping binaries.
-->
<Target Name="CheckLocStatus"
DependsOnTargets="EnsureAllResourcesTranslated"
Condition="'$(NonShipping)' != 'true'" />
</Project>
......@@ -482,7 +482,7 @@ function Build-DeployToSymStore() {
}
function Build-CheckLocStatus() {
Run-MSBuild "Roslyn.sln" "/t:EnsureAllResourcesTranslated" -logFileName "RoslynCheckLocStatus"
Run-MSBuild "Roslyn.sln" "/t:CheckLocStatus" -logFileName "RoslynCheckLocStatus"
}
# These are tests that don't follow our standard restore, build, test pattern. They customize
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册