-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDirectory.Build.targets
106 lines (90 loc) · 4.77 KB
/
Directory.Build.targets
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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" TreatAsLocalProperty="OutDir"
xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<!-- <Target Name="ClearGameFolderCopyLocal" AfterTargets="ResolveAssemblyReferences">
<ItemGroup>
<ReferenceCopyLocalPaths Remove="$(GameFolder)\*"/>
</ItemGroup>
</Target> -->
<Target Name="ILRepack" AfterTargets="Build">
<ItemGroup>
<!-- <InputAssemblies Include="$(TargetDir)\$(ProjectName).dll"/> -->
<!-- <InputAssemblies Include="$(TargetDir)\*.dll"
Exclude="**\0Harmony.dll"/> -->
</ItemGroup>
<ILRepack
TargetPlatformVersion="v4"
TargetKind="SameAsPrimaryAssembly"
Wildcards="true"
LibraryPath="$(LibFolder)"
InputAssemblies="@(InputAssemblies)"
OutputFile="$(OutputPath)\$(AssemblyName).dll"
LogFile="$(OutputPath)\ilrepack_log.txt"
Verbose="9"
/>
</Target>
<UsingTask TaskName="ModInfo" AssemblyFile="packages\ONI-ModInfo\ONI-ModInfo-Task.dll" />
<Target Name="CopyArtifactsToInstallFolder" AfterTargets="ILRepack" Condition=" '$(AssemblyName)' != 'Commons' ">
<PropertyGroup Condition="'$(Configuration)' == 'VanillaRelease'">
<!-- <InstallFolder>..\Release\$(ProjectName)\archived_versions\vanilla</InstallFolder> -->
<InstallFolder>..\Release\$(ProjectName)</InstallFolder>
<UseArchivedVersions>true</UseArchivedVersions>
<SupportedContent>VANILLA_ID</SupportedContent>
<LastWorkingBuild>466292</LastWorkingBuild>
<APIVersion>0</APIVersion>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)' == 'SpacedOutRelease'">
<InstallFolder>..\Release\$(ProjectName)</InstallFolder>
<UseArchivedVersions>false</UseArchivedVersions>
<SupportedContent>EXPANSION1_ID</SupportedContent>
<LastWorkingBuild>467401</LastWorkingBuild>
<APIVersion>2</APIVersion>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)' == 'VanillaDebug'">
<!-- <InstallFolder>$(ModFolder)\$(ProjectName)\archived_versions\vanilla</InstallFolder> -->
<InstallFolder>$(UserProfile)\Documents\Klei\OxygenNotIncluded\mods\dev\$(ProjectName)</InstallFolder>
<UseArchivedVersions>true</UseArchivedVersions>
<SupportedContent>VANILLA_ID</SupportedContent>
<LastWorkingBuild>466292</LastWorkingBuild>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)' == 'SpacedOutDebug'">
<InstallFolder>$(UserProfile)\Documents\Klei\OxygenNotIncluded\mods\dev\$(ProjectName)</InstallFolder>
<UseArchivedVersions>false</UseArchivedVersions>
<SupportedContent>EXPANSION1_ID</SupportedContent>
<LastWorkingBuild>467401</LastWorkingBuild>
<APIVersion>2</APIVersion>
</PropertyGroup>
<PropertyGroup>
<TempPublishFolder>$(ProjectDir)\publish</TempPublishFolder>
</PropertyGroup>
<ItemGroup>
<!--
<AnimFiles Include="$(ProjectDir)\anim\**\*.*" />
<WorldGenFiles Include="$(ProjectDir)\worldgen\**\*.*" />
<YamlFiles Include="$(ProjectDir)\*.yaml" />
-->
<YamlFiles Include="$(ProjectDir)\*.yaml"/>
<PoFiles Include="$(ProjectDir)\**\*.po"/>
<PreviewPNG Include="$(ProjectDir)\preview.png"/>
</ItemGroup>
<!--
<Copy SourceFiles="@(PoFiles)" DestinationFiles="@(PoFiles->'$(TempPublishFolder)\strings\%(RecursiveDir)%(Filename)%(Extension)')"/>
-->
<Copy SourceFiles="@(YamlFiles)" DestinationFiles="@(YamlFiles->'$(TempPublishFolder)\%(Filename)%(Extension)')"/>
<Copy SourceFiles="@(PoFiles)" DestinationFiles="@(PoFiles->'$(TempPublishFolder)\strings\%(Filename)%(Extension)')"/>
<Copy SourceFiles="@(PreviewPNG)" DestinationFiles="@(PreviewPNG->'$(TempPublishFolder)\%(Filename)%(Extension)')"/>
<Copy SourceFiles="$(TargetPath)" DestinationFiles="$(TempPublishFolder)\$(TargetFileName)"/>
<ModInfo InputFilePath="$(TempPublishFolder)"
OutputFilePath="$(InstallFolder)"
UseArchivedVersions="$(UseArchivedVersions)"
SupportedContent="$(SupportedContent)"
LastWorkingBuild="$(LastWorkingBuild)"
APIVersion="$(APIVersion)"
/>
<RemoveDir Directories="$(TempPublishFolder)"/>
<ItemGroup>
<DirtyFiles Include="$(InstallFolder)\**\.DS_Store"/>
</ItemGroup>
<Delete Files="@(DirtyFiles)"/>
</Target>
</Project>