Build Core SDK tasks to separate folder for consumption during main build

This commit is contained in:
Daniel Plaisted 2018-10-22 20:04:13 -07:00
parent 914f465b30
commit 2e76a1e5fd
2 changed files with 19 additions and 0 deletions

View file

@ -5,5 +5,7 @@
<CopyBuildOutputToPublishDirectory>false</CopyBuildOutputToPublishDirectory>
</PropertyGroup>
<Import Project="targets\BuildCoreSdkTasks.targets" />
</Project>

View file

@ -0,0 +1,17 @@
<Project>
<PropertyGroup>
<CoreSdkTaskDll>$(ArtifactsDir)tasks\bin\core-sdk-tasks\$(Configuration)\$(CoreSdkTargetFramework)\core-sdk-tasks.dll</CoreSdkTaskDll>
<CoreSdkTaskProject>$(RepoRoot)src\core-sdk-tasks\core-sdk-tasks.csproj</CoreSdkTaskProject>
</PropertyGroup>
<Target Name="BuildCoreSdkTasks" BeforeTargets="_CheckForInvalidConfigurationAndPlatform">
<!-- Use a different ArtifactsDir for this invocation so that the tasks project can be part of the solution
(for easy editing), but we don't hit problems with the tasks DLL being locked when we try to build the solution. -->
<MSBuild Projects="$(CoreSdkTaskProject)"
Properties="ArtifactsDir=$(ArtifactsDir)tasks\;Phase=Restore"
Targets="Restore"/>
<MSBuild Projects="$(CoreSdkTaskProject)"
Properties="ArtifactsDir=$(ArtifactsDir)tasks\"/>
</Target>
</Project>