chore(Target): add version props (#4705)

This commit is contained in:
Argo Zhang 2024-11-19 21:15:46 -08:00 committed by GitHub
parent dc640a7268
commit a88f48080d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 13 additions and 3 deletions

View File

@ -1,7 +1,8 @@
<Project>
<Import Project="Version.props"/>
<PropertyGroup>
<RunTargetFramework>net9.0</RunTargetFramework>
<TargetFramework>$(RunTargetFramework)</TargetFramework>
</PropertyGroup>

7
Version.props Normal file
View File

@ -0,0 +1,7 @@
<Project>
<PropertyGroup>
<RunTargetFramework>net9.0</RunTargetFramework>
</PropertyGroup>
</Project>

View File

@ -1,15 +1,17 @@
<Project>
<Import Project="..\..\Version.props" />
<ItemGroup>
<PackageReference Include="AspNetCore.SassCompiler" Version="1.79.5" Condition="'$(Configuration)'=='Debug' and '$(TargetFramework)' == '$(RunTargetFramework)'" />
</ItemGroup>
<Target Name="CopyCss" AfterTargets="Build" Condition="'$(TargetFramework)' == '$(RunTargetFramework)'">
<Message Text="Copy bootstrap assets ..." Importance="high"></Message>
<Copy SourceFiles="$(MSBuildThisFileDirectory)wwwroot/core/bootstrap/js/bootstrap.bundle.min.js" DestinationFiles="$(MSBuildThisFileDirectory)wwwroot/js/bootstrap.blazor.bundle.min.js" SkipUnchangedFiles="true" ></Copy>
<Copy SourceFiles="$(MSBuildThisFileDirectory)wwwroot/core/bootstrap/css/bootstrap.min.css" DestinationFiles="$(MSBuildThisFileDirectory)wwwroot/css/bootstrap.min.css" SkipUnchangedFiles="true" ></Copy>
<Copy SourceFiles="$(MSBuildThisFileDirectory)wwwroot/core/bootstrap/css/bootstrap.rtl.min.css" DestinationFiles="$(MSBuildThisFileDirectory)wwwroot/css/bootstrap.rtl.min.css" SkipUnchangedFiles="true" ></Copy>
<Message Text="Copy bootstrapblazor assets ..." Importance="high"></Message>
<Copy SourceFiles="$(MSBuildThisFileDirectory)wwwroot/lib/animate/animate.min.css" DestinationFiles="$(MSBuildThisFileDirectory)wwwroot/css/animate.min.css" SkipUnchangedFiles="true" ></Copy>
<Copy SourceFiles="$(MSBuildThisFileDirectory)wwwroot/lib/swal/sweetalert2.css" DestinationFiles="$(MSBuildThisFileDirectory)wwwroot/css/sweetalert2.css" SkipUnchangedFiles="true" ></Copy>