工具箱相关
Du kannst nicht mehr als 25 Themen auswählen Themen müssen mit entweder einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

Fody.targets 4.2KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. <Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  2. <PropertyGroup>
  3. <ProjectWeaverXml>$(ProjectDir)FodyWeavers.xml</ProjectWeaverXml>
  4. <FodyPath Condition="$(FodyPath) == '' Or $(FodyPath) == '*Undefined*'">$(MSBuildThisFileDirectory)..\</FodyPath>
  5. <FodyAssemblyDirectory Condition="'$(MSBuildRuntimeType)' == 'Core'">$(FodyPath)netstandardtask</FodyAssemblyDirectory>
  6. <FodyAssemblyDirectory Condition="'$(MSBuildRuntimeType)' != 'Core'">$(FodyPath)netclassictask</FodyAssemblyDirectory>
  7. <FodyAssembly Condition="'$(FodyAssembly)' == ''">$(FodyAssemblyDirectory)\Fody.dll</FodyAssembly>
  8. <DefaultItemExcludes>$(DefaultItemExcludes);FodyWeavers.xsd</DefaultItemExcludes>
  9. <FodyGenerateXsd Condition="'$(FodyGenerateXsd)' == ''">true</FodyGenerateXsd>
  10. </PropertyGroup>
  11. <ItemGroup Condition="Exists('$(ProjectWeaverXml)')">
  12. <UpToDateCheckInput Include="$(ProjectWeaverXml)" />
  13. <CustomAdditionalCompileInputs Include="$(ProjectWeaverXml)" />
  14. </ItemGroup>
  15. <!-- Support for NCrunch -->
  16. <ItemGroup Condition="'$(NCrunch)' == '1'">
  17. <None Include="$(FodyAssemblyDirectory)\*.*" />
  18. <None Include="@(WeaverFiles)" />
  19. </ItemGroup>
  20. <UsingTask TaskName="Fody.WeavingTask" AssemblyFile="$(FodyAssembly)" />
  21. <UsingTask TaskName="Fody.UpdateReferenceCopyLocalTask" AssemblyFile="$(FodyAssembly)" />
  22. <UsingTask TaskName="Fody.VerifyTask" AssemblyFile="$(FodyAssembly)" />
  23. <Target
  24. Name="FodyTarget"
  25. AfterTargets="AfterCompile"
  26. Condition="Exists('@(IntermediateAssembly)') And $(DesignTimeBuild) != true And $(DisableFody) != true"
  27. DependsOnTargets="$(FodyDependsOnTargets)"
  28. Inputs="@(IntermediateAssembly);$(ProjectWeaverXml)"
  29. Outputs="$(IntermediateOutputPath)$(MSBuildProjectFile).Fody.CopyLocal.cache">
  30. <Fody.WeavingTask
  31. AssemblyFile="@(IntermediateAssembly)"
  32. IntermediateDirectory="$(ProjectDir)$(IntermediateOutputPath)"
  33. KeyOriginatorFile="$(KeyOriginatorFile)"
  34. AssemblyOriginatorKeyFile="$(AssemblyOriginatorKeyFile)"
  35. ProjectDirectory="$(MSBuildProjectDirectory)"
  36. ProjectFile="$(MSBuildProjectFullPath)"
  37. SolutionDirectory="$(SolutionDir)"
  38. References="@(ReferencePath)"
  39. SignAssembly="$(SignAssembly)"
  40. ReferenceCopyLocalFiles="@(ReferenceCopyLocalPaths)"
  41. DefineConstants="$(DefineConstants)"
  42. DebugType="$(DebugType)"
  43. DocumentationFile="@(DocFileItem->'%(FullPath)')"
  44. WeaverFiles="@(WeaverFiles)"
  45. NCrunchOriginalSolutionDirectory="$(NCrunchOriginalSolutionDir)"
  46. IntermediateCopyLocalFilesCache="$(IntermediateOutputPath)$(MSBuildProjectFile).Fody.CopyLocal.cache"
  47. GenerateXsd="$(FodyGenerateXsd)"
  48. >
  49. <Output
  50. TaskParameter="ExecutedWeavers"
  51. PropertyName="FodyExecutedWeavers" />
  52. </Fody.WeavingTask>
  53. <ItemGroup>
  54. <FileWrites Include="$(IntermediateOutputPath)$(MSBuildProjectFile).Fody.CopyLocal.cache" />
  55. </ItemGroup>
  56. </Target>
  57. <Target
  58. Name="FodyUpdateCopyLocalFilesTarget"
  59. AfterTargets="FodyTarget"
  60. >
  61. <Fody.UpdateReferenceCopyLocalTask
  62. ReferenceCopyLocalFiles="@(ReferenceCopyLocalPaths)"
  63. IntermediateCopyLocalFilesCache="$(IntermediateOutputPath)$(MSBuildProjectFile).Fody.CopyLocal.cache"
  64. >
  65. <Output
  66. TaskParameter="UpdatedReferenceCopyLocalFiles"
  67. ItemName="FodyUpdatedReferenceCopyLocalPaths" />
  68. </Fody.UpdateReferenceCopyLocalTask>
  69. <ItemGroup>
  70. <ReferenceCopyLocalPaths Remove="@(ReferenceCopyLocalPaths)" />
  71. <ReferenceCopyLocalPaths Include="@(FodyUpdatedReferenceCopyLocalPaths)" />
  72. </ItemGroup>
  73. </Target>
  74. <Target
  75. Name="FodyVerifyTarget"
  76. AfterTargets="AfterBuild"
  77. Condition="'$(NCrunch)' != '1' And $(FodyExecutedWeavers) != '' And $(DisableFody) != true"
  78. DependsOnTargets="$(FodyVerifyDependsOnTargets)">
  79. <Fody.VerifyTask
  80. ProjectDirectory="$(MSBuildProjectDirectory)"
  81. TargetPath="$(TargetPath)"
  82. SolutionDirectory="$(SolutionDir)"
  83. DefineConstants="$(DefineConstants)"
  84. NCrunchOriginalSolutionDirectory="$(NCrunchOriginalSolutionDir)"
  85. />
  86. </Target>
  87. </Project>