Skip to content

Commit

Permalink
fix: Adjust GenerateUnoSplash targets to have proper inputs for bette…
Browse files Browse the repository at this point in the history
…r incrementality
  • Loading branch information
Youssef1313 committed Jun 10, 2024
1 parent c498458 commit 3e3e54f
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 7 deletions.
5 changes: 4 additions & 1 deletion src/.nuspec/Uno.Resizetizer.android.targets
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
Name="GenerateUnoSplashAndroid"
BeforeTargets="ProcessUnoSplashScreens"
Condition=" '@(UnoSplashScreen)' != '' "
Inputs="@(UnoSplashScreen)"
Outputs="$(_UnoSplashStampFile)">

<CallTarget Targets="GenerateUnoSplashScreens" />
Expand All @@ -12,6 +13,8 @@
IntermediateOutputPath="$(_UnoIntermediateSplashScreen)"
UnoSplashScreen="@(UnoSplashScreen)"
/>

<CallTarget Targets="PostGenerateUnoSplashScreens" />
</Target>

<!-- ProcessUnoSplashScreens must run at design time to avoid interactions with the `.R` generation on Android -->
Expand Down Expand Up @@ -46,4 +49,4 @@
</LibraryResourceDirectories>
</ItemGroup>
</Target>
</Project>
</Project>
6 changes: 4 additions & 2 deletions src/.nuspec/Uno.Resizetizer.apple.targets
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Name="GenerateUnoSplashApple"
BeforeTargets="ProcessUnoSplashScreens"
Condition="'$(DesignTimeBuild)' != 'True' And '@(UnoSplashScreen)' != ''"
Outputs="$(_UnoSplashStampFile)">
Outputs="$(_UnoSplashStampFile)"> <!-- TODO: Specify Inputs on this target -->

<CallTarget Targets="GenerateUnoSplashScreens" />

Expand All @@ -27,6 +27,8 @@
IntermediateOutputPath="$(_UnoIntermediateSplashScreen)"
PlistName="UnoInfo.plist"
Storyboard="$(_UnoIntermediateSplashScreenFile)"/>

<CallTarget Targets="PostGenerateUnoSplashScreens" />
</Target>

<Target Name="ProcessUnoSplashScreens"
Expand Down Expand Up @@ -84,4 +86,4 @@
SessionId="$(BuildSessionId)"
Files="@(_UnoImagesToCopyToBuildServer)"/>
</Target>
</Project>
</Project>
8 changes: 7 additions & 1 deletion src/.nuspec/Uno.Resizetizer.targets
Original file line number Diff line number Diff line change
Expand Up @@ -449,7 +449,7 @@
</GetUnoAssetPath_v0>
</Target>

<!-- This target is meant to be called by platform specific splash screen targets -->
<!-- This target is meant to be called by platform specific splash screen targets at its beginning -->
<Target Name="GenerateUnoSplashScreens"
Condition="'@(UnoSplashScreen)' != ''">

Expand All @@ -459,6 +459,12 @@
</ItemGroup>

<MakeDir Directories="$(IntermediateOutputPath)"/>
</Target>

<!-- This target is meant to be called by platform specific splash screen targets at its end -->
<Target Name="PostGenerateUnoSplashScreens"
Condition="'@(UnoSplashScreen)' != ''">

<!-- Stamp file for Outputs -->
<Touch Files="$(_UnoSplashStampFile)" AlwaysCreate="True"/>
<ItemGroup>
Expand Down
11 changes: 10 additions & 1 deletion src/.nuspec/Uno.Resizetizer.wasm.targets
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,13 @@
Name="GenerateUnoSplashWasm"
BeforeTargets="ProcessUnoSplashScreens"
Condition="'$(DesignTimeBuild)' != 'true' AND $(OutputType) == 'Exe'"
Inputs="@(EmbeddedResource);@(UnoSplashScreen)"
Outputs="$(_UnoSplashStampFile)">

<CallTarget Targets="GenerateUnoSplashScreens" />

<MakeDir Directories="$(IntermediateOutputPath)"/>

<!--Wasm-->
<GenerateWasmSplashAssets_v0
IntermediateOutputPath="$(_UnoIntermediateSplashScreen)"
Expand Down Expand Up @@ -37,6 +40,12 @@
<EmbeddedResource Include="$(_UnoIntermediateAppManifestWasm)"
Link="$(UserAppManifest)"/>
</ItemGroup>

<!-- Stamp file for Outputs -->
<Touch Files="$(_UnoSplashStampFile)" AlwaysCreate="True"/>
<ItemGroup>
<FileWrites Include="$(_UnoSplashStampFile)"/>
</ItemGroup>
</Target>

<Target Name="ProcessUnoSplashScreens"/>
Expand Down Expand Up @@ -74,4 +83,4 @@
Link="$(WasmPWAManifestFile)"/>
</ItemGroup>
</Target>
</Project>
</Project>
7 changes: 5 additions & 2 deletions src/.nuspec/Uno.Resizetizer.windows.skia.targets
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,11 @@
Name="GenerateUnoSplashWindowsSkia"
BeforeTargets="ProcessUnoSplashScreens"
Condition="'$(DesignTimeBuild)' != 'True' And '@(UnoSplashScreen)' != ''"
Inputs="@(UnoSplashScreen)"
Outputs="$(_UnoSplashStampFile)">

<CallTarget Targets="GenerateUnoSplashScreens" />

<!-- UWP / WinUI -->
<ItemGroup
Condition="'$(_UnoResizetizerIsWindowsAppSdk)' == 'True'">
Expand All @@ -38,6 +39,8 @@
IntermediateOutputPath="$(_UnoIntermediateSplashScreen)"
UnoSplashScreen="@(UnoWindowsSplash)"
/>

<CallTarget Targets="PostGenerateUnoSplashScreens" />
</Target>

<Target Name="ProcessUnoSplashScreens"
Expand Down Expand Up @@ -121,4 +124,4 @@
<FileWrites Include="$(_UnoManifestStampFile)"/>
</ItemGroup>
</Target>
</Project>
</Project>

0 comments on commit 3e3e54f

Please sign in to comment.