TeamAAS.csproj 3.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. <Project Sdk="Microsoft.NET.Sdk">
  2. <PropertyGroup>
  3. <OutputType>WinExe</OutputType>
  4. <ApplicationIcon>TeamAAS25.ico</ApplicationIcon>
  5. <TargetFramework>net48</TargetFramework>
  6. <UseWPF>true</UseWPF>
  7. <UseWindowsForms>true</UseWindowsForms>
  8. <RuntimeIdentifier>win-x64</RuntimeIdentifier>
  9. <PublishSingleFile>true</PublishSingleFile>
  10. <AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
  11. <OutputPath>..\ExE</OutputPath>
  12. <BaseOutputPath>$(OutputPath)</BaseOutputPath>
  13. <ApplicationManifest>app.manifest</ApplicationManifest>
  14. <SatelliteResourceLanguages>zh-CN</SatelliteResourceLanguages>
  15. <ProduceReferenceAssembly>True</ProduceReferenceAssembly>
  16. <Platforms>x64</Platforms>
  17. <PlatformTarget>x64</PlatformTarget>
  18. <AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
  19. <GenerateBindingRedirectsOutputType>true</GenerateBindingRedirectsOutputType>
  20. </PropertyGroup>
  21. <ItemGroup>
  22. <PackageReference Include="HandyControl" Version="3.5.1" />
  23. <PackageReference Include="MessagePack" Version="3.1.8" />
  24. <PackageReference Include="OpenCvSharp4" Version="4.13.0.20260627" />
  25. <PackageReference Include="OpenCvSharp4.runtime.win" Version="4.13.0.20260627" />
  26. <PackageReference Include="Prism.DryIoc" Version="8.1.97" />
  27. <PackageReference Include="PropertyGridLib" Version="1.2.0" />
  28. <PackageReference Include="System.Text.Json" Version="10.0.0" />
  29. </ItemGroup>
  30. <PropertyGroup>
  31. <VisionProRoot Condition="Exists('C:\Program Files\Cognex\VisionPro')">C:\Program Files\Cognex\VisionPro</VisionProRoot>
  32. <VisionProRoot Condition="'$(VisionProRoot)' == '' AND EXISTS('C:\Program Files (x86)\Cognex\VisionPro')">C:\Program Files (x86)\Cognex\VisionPro</VisionProRoot>
  33. <ReferencePath>$(VisionProRoot)\ReferencedAssemblies;$(VisionProRoot)\CogPlus;$(ReferencePath)</ReferencePath>
  34. </PropertyGroup>
  35. <ItemGroup>
  36. <ProjectReference Include="..\TeamAAS.Core\TeamAAS.Core\TeamAAS.Core.csproj" />
  37. <!-- 鐩磋繛寮曠敤锛氫繚璇?XAML 涓?assembly=TeamAAS.Global 鐨勬棩蹇楁帶浠惰兘琚В鏋?-->
  38. <ProjectReference Include="..\TeamAAS.Base\TeamAAS.Global\TeamAAS.Global.csproj" />
  39. <ProjectReference Include="..\TeamAAS.Base\TeamAAS.Database\TeamAAS.Database.csproj" />
  40. </ItemGroup>
  41. <!-- PostBuild锛氭妸鏍圭洰褰曟墍鏈?DLL/PDB/XML/Plugins/native 搴撶Щ鍒?Runtime 瀛愮洰褰曪紝
  42. 鏍圭洰褰曞彧淇濈暀 EXE + 閰嶇疆绫绘枃浠跺す锛圕onfig/Logs/Products/Recipe/zh-CN锛夈€?
  43. 鍚姩鏃?App.OnStartup 閫氳繃 AssemblyResolve + SetDllDirectory 鍦?Runtime 涓嬪姞杞姐€?-->
  44. <Target Name="OrganizeOutputDir" AfterTargets="Build">
  45. <PropertyGroup>
  46. <_AbsOutDir>$([System.IO.Path]::GetFullPath($([System.IO.Path]::Combine('$(MSBuildProjectDirectory)','$(OutDir)'))).TrimEnd('\'))</_AbsOutDir>
  47. </PropertyGroup>
  48. <Exec Command="powershell -NoProfile -ExecutionPolicy Bypass -File &quot;$(MSBuildProjectDirectory)\PostBuild.ps1&quot; -OutDir &quot;$(_AbsOutDir)&quot;" Condition="'$(DesignTimeBuild)' != 'true' And '$(BuildingProject)' == 'true'" />
  49. </Target>
  50. <!-- Debug 鏋勫缓鍓嶏細鎵弿婧愮爜閲岀殑 Translate 璋冪敤鐐癸紝鎶婃柊鍘熸枃鍚堝苟杩?Localization\zh-CN.json锛?
  51. 闃叉鐣岄潰鏂板鏂囨湰婕忛厤缈昏瘧銆傚悎骞剁瓥鐣ュ彧澧炰笉鍒狅紱鍏朵粬璇█鍖呯己澶辫瘝鏉″彧鎵撳嵃鎶ュ憡銆?
  52. 宸ュ叿婧愮爜鍦?Tools\LocalizationExtractor锛屽彂甯?CI 鏋勫缓涓嶆墽琛屻€?-->
  53. <Target Name="ExtractLocalization" BeforeTargets="Build" Condition="'$(Configuration)' == 'Debug' And '$(DesignTimeBuild)' != 'true' And '$(BuildingProject)' == 'true'">
  54. <Exec Command="dotnet run --project &quot;$(MSBuildThisFileDirectory)..\Tools\LocalizationExtractor\LocalizationExtractor.csproj&quot; -c Release -v q --no-launch-profile -- &quot;$(MSBuildThisFileDirectory)..&quot;" IgnoreExitCode="true" />
  55. </Target>
  56. </Project>