-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathLanfeustBridge.csproj
62 lines (62 loc) · 3.65 KB
/
LanfeustBridge.csproj
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
<Project ToolsVersion="15.0" Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<UserSecretsId>21351da5-d940-46d8-ad66-351ae03a3ec4</UserSecretsId>
<TypeScriptCompileBlocked>true</TypeScriptCompileBlocked>
<IsPackable>false</IsPackable>
<SpaRoot>ClientApp\</SpaRoot>
<DefaultItemExcludes>$(DefaultItemExcludes);$(SpaRoot)node_modules\**</DefaultItemExcludes>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
<!-- We want to check documentation, not *require* it : ignore the corresponding warnings -->
<NoWarn>1701;1702;1591</NoWarn>
<!-- The vstest part of xunit automatically generates an entrypoint, conflicting with our own -->
<GenerateProgramFile>false</GenerateProgramFile>
<Nullable>enable</Nullable>
<AnalysisMode>AllEnabledByDefault</AnalysisMode>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="LiteDB" Version="5.0.11"/>
<PackageReference Include="Microsoft.AspNetCore.Authentication.Google" Version="6.0.1"/>
<PackageReference Include="Microsoft.AspNetCore.Identity.UI" Version="6.0.1"/>
<PackageReference Include="Microsoft.AspNetCore.SpaServices.Extensions" Version="6.0.1"/>
<PackageReference Include="Microsoft.TestPlatform.TestHost" Version="17.0.0"/>
<PackageReference Include="SendGrid" Version="9.25.1"/>
<PackageReference Include="Serilog.AspNetCore" Version="4.1.0"/>
<PackageReference Include="Serilog.Sinks.Console" Version="4.0.1"/>
<PackageReference Include="Serilog.Sinks.File" Version="5.0.0"/>
<PackageReference Include="xunit" Version="2.4.1"/>
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.3"/>
</ItemGroup>
<ItemGroup>
<!-- Don't publish the SPA source files, but do show them in the project files list -->
<Content Remove="$(SpaRoot)**"/>
<None Include="$(SpaRoot)**" Exclude="$(SpaRoot)node_modules\**"/>
</ItemGroup>
<ItemGroup>
<Service Include="{82a7f48d-3b50-4b1e-b82e-3ada8210c358}"/>
</ItemGroup>
<Target Name="DebugEnsureNodeEnv" BeforeTargets="Build" Condition=" '$(Configuration)' == 'Debug' And !Exists('$(SpaRoot)node_modules') And $(SkipRunWebpack) != 'true' ">
<!-- Ensure Node.js is installed -->
<Exec Command="node --version" ContinueOnError="true">
<Output TaskParameter="ExitCode" PropertyName="ErrorCode"/>
</Exec>
<Error Condition="'$(ErrorCode)' != '0'" Text="Node.js is required to build and run this project. To continue, please install Node.js from https://nodejs.org/, and then restart your command prompt or IDE."/>
<Message Importance="high" Text="Restoring dependencies using 'npm'. This may take several minutes..."/>
<Exec WorkingDirectory="$(SpaRoot)" Command="npm install"/>
</Target>
<Target Name="PublishRunWebpack" AfterTargets="ComputeFilesToPublish" Condition=" $(SkipRunWebpack) != 'true' ">
<!-- As part of publishing, ensure the JS resources are freshly built in production mode -->
<Exec WorkingDirectory="$(SpaRoot)" Command="npm install"/>
<Exec WorkingDirectory="$(SpaRoot)" Command="npm run build -- --configuration production"/>
<Exec WorkingDirectory="$(SpaRoot)" Command="npm run build:ssr:prod" Condition=" '$(BuildServerSideRenderer)' == 'true' "/>
<!-- Include the newly-built files in the publish output -->
<ItemGroup>
<DistFiles Include="$(SpaRoot)dist\**; $(SpaRoot)dist-server\**"/>
<DistFiles Include="$(SpaRoot)node_modules\**" Condition="'$(BuildServerSideRenderer)' == 'true'"/>
<ResolvedFileToPublish Include="@(DistFiles->'%(FullPath)')" Exclude="@(ResolvedFileToPublish)">
<RelativePath>%(DistFiles.Identity)</RelativePath>
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
</ResolvedFileToPublish>
</ItemGroup>
</Target>
</Project>