1. Costura.Fody 引用后,未能正常合并资源文件。用着用着就不行了
解决方案:在csproj所在的文件目录,找到FodyWeavers.xml,添加<Costura/>
1 <Weavers xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="FodyWeavers.xsd"> 2 <Costura /> 3 </Weavers>
2. 编译时有Fody相关的警告
MSBUILD : warning FodyPackageReference: Fody: The package reference for Costura.Fody is missing the 'compile' part in the IncludeAssets setting; it's recommended to completely remove IncludeAssets
解决方案:打开csproj,对Fody的Nuget引用修改IncludeAssets属性,添加compile
1 <PackageReference Include="Costura.Fody"> 2 <Version>5.7.0</Version> 3 <IncludeAssets>runtime;compile;build; native; contentfiles; analyzers; buildtransitive</IncludeAssets> 4 <PrivateAssets>all</PrivateAssets> 5 </PackageReference>
标签:Costura,IncludeAssets,Fody,csproj,解决方案,compile,使用 From: https://www.cnblogs.com/kybs0/p/17243890.html