Skip to content

Commit

Permalink
Fixed PropertyGroup using wrong values because
Browse files Browse the repository at this point in the history
it's defined too early (Azure#4057)
  • Loading branch information
TomBonnerAtTFL committed Feb 6, 2019
1 parent 739a113 commit 22155f6
Showing 1 changed file with 14 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,20 @@
<_FunctionsExtensionsTasksDir Condition=" '$(_FunctionsExtensionsTasksDir)'=='' ">$(MSBuildThisFileDirectory)..\tools\$(_FunctionsExtensionsTaskFramework)</_FunctionsExtensionsTasksDir>
<_FunctionsExtensionsTaskAssemblyFullPath Condition=" '$(_FunctionsExtensionsTaskAssemblyFullPath)'=='' ">$(_FunctionsExtensionsTasksDir)\Microsoft.Azure.WebJobs.Script.ExtensionsMetadataGenerator.dll</_FunctionsExtensionsTaskAssemblyFullPath>
<IsPackable>false</IsPackable>
<_IsFunctionsSdkBuild Condition="$(_FunctionsTaskFramework) != ''">true</_IsFunctionsSdkBuild>
<_FunctionsExtensionsDir>$(TargetDir)</_FunctionsExtensionsDir>
<_FunctionsExtensionsDir Condition="$(_IsFunctionsSdkBuild) == 'true'">$(_FunctionsExtensionsDir)bin</_FunctionsExtensionsDir>
</PropertyGroup>

<UsingTask TaskName="GenerateFunctionsExtensionsMetadata"
AssemblyFile="$(_FunctionsExtensionsTaskAssemblyFullPath)"/>

<Target Name="_GenerateFunctionsExtensionsMetadataPostBuild"
AfterTargets="Build">


<PropertyGroup>
<_IsFunctionsSdkBuild Condition="$(_FunctionsTaskFramework) != ''">true</_IsFunctionsSdkBuild>
<_FunctionsExtensionsDir>$(TargetDir)</_FunctionsExtensionsDir>
<_FunctionsExtensionsDir Condition="$(_IsFunctionsSdkBuild) == 'true'">$(_FunctionsExtensionsDir)bin</_FunctionsExtensionsDir>
</PropertyGroup>

<GenerateFunctionsExtensionsMetadata
SourcePath="$(_FunctionsExtensionsDir)"
OutputPath="$(_FunctionsExtensionsDir)"/>
Expand All @@ -27,7 +30,7 @@
OverwriteReadOnlyFiles="true"
ContinueOnError="true"/>
</Target>

<Target Name="_GenerateFunctionsExtensionsMetadataPostPublish"
AfterTargets="Publish">
<GenerateFunctionsExtensionsMetadata
Expand All @@ -40,6 +43,12 @@
Condition="$(_IsFunctionsSdkBuild) != 'true'"
DependsOnTargets="RunResolvePublishAssemblies">

<PropertyGroup>
<_IsFunctionsSdkBuild Condition="$(_FunctionsTaskFramework) != ''">true</_IsFunctionsSdkBuild>
<_FunctionsExtensionsDir>$(TargetDir)</_FunctionsExtensionsDir>
<_FunctionsExtensionsDir Condition="$(_IsFunctionsSdkBuild) == 'true'">$(_FunctionsExtensionsDir)bin</_FunctionsExtensionsDir>
</PropertyGroup>

<!--
Copy publish assemblies that not already included in ReferenceCopyLocalPaths
via CopyLocalLockFileAssemblies=true. This will include RID-specific assets
Expand Down

0 comments on commit 22155f6

Please sign in to comment.