Fixing modinfo.json for SRML
This commit is contained in:
parent
7327368999
commit
f38d6a4fed
3 changed files with 11 additions and 51 deletions
|
@ -496,10 +496,6 @@
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Content Include="Console\Console Commands.txt" />
|
<Content Include="Console\Console Commands.txt" />
|
||||||
<Content Include="modinfo.tt">
|
|
||||||
<Generator>TextTemplatingFileGenerator</Generator>
|
|
||||||
<LastGenOutput>modinfo.json</LastGenOutput>
|
|
||||||
</Content>
|
|
||||||
<Content Include="Properties\AssemblyInfo.tt">
|
<Content Include="Properties\AssemblyInfo.tt">
|
||||||
<Generator>TextTemplatingFileGenerator</Generator>
|
<Generator>TextTemplatingFileGenerator</Generator>
|
||||||
<LastGenOutput>AssemblyInfo.cs</LastGenOutput>
|
<LastGenOutput>AssemblyInfo.cs</LastGenOutput>
|
||||||
|
@ -514,14 +510,11 @@
|
||||||
</Reference>
|
</Reference>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<EmbeddedResource Include="modinfo.json">
|
|
||||||
<AutoGen>True</AutoGen>
|
|
||||||
<DesignTime>True</DesignTime>
|
|
||||||
<DependentUpon>modinfo.tt</DependentUpon>
|
|
||||||
</EmbeddedResource>
|
|
||||||
<EmbeddedResource Include="srmultiplayer.dat" />
|
<EmbeddedResource Include="srmultiplayer.dat" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup />
|
<ItemGroup>
|
||||||
|
<EmbeddedResource Include="modinfo.json" />
|
||||||
|
</ItemGroup>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<PostBuildEvent>
|
<PostBuildEvent>
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
{
|
{
|
||||||
"id": "srmp",
|
"id": "srmp",
|
||||||
"name": "Slime Rancher Multiplayer",
|
"name": "Slime Rancher Multiplayer",
|
||||||
"version": "0.0.1510",
|
"version": "0.0.1510",
|
||||||
"author": "SatyPardus",
|
"author": "SatyPardus",
|
||||||
"dependencies": [
|
"dependencies": [
|
||||||
|
|
||||||
]
|
]
|
||||||
}
|
}
|
|
@ -1,33 +0,0 @@
|
||||||
<#@ template debug="true" hostspecific="true" language="C#" #>
|
|
||||||
<#@ output extension=".json" #>
|
|
||||||
<#@ import namespace="System.IO" #>
|
|
||||||
<#@ import namespace="System.Text.RegularExpressions" #>
|
|
||||||
<#
|
|
||||||
string output = File.ReadAllText("F:/GitHub/srmp-reloaded/SRMP/Properties/AssemblyInfo.cs");
|
|
||||||
Regex pattern = new Regex("AssemblyVersion\\(\"(?<major>\\d+)\\.(?<minor>\\d+)\\.(?<revision>\\d+)\\.(?<build>\\d+)\"\\)");
|
|
||||||
MatchCollection matches = pattern.Matches(output);
|
|
||||||
if( matches.Count == 1 )
|
|
||||||
{
|
|
||||||
major = Convert.ToInt32(matches[0].Groups["major"].Value);
|
|
||||||
minor = Convert.ToInt32(matches[0].Groups["minor"].Value);
|
|
||||||
build = Convert.ToInt32(matches[0].Groups["build"].Value);
|
|
||||||
revision = Convert.ToInt32(matches[0].Groups["revision"].Value);
|
|
||||||
}
|
|
||||||
#>
|
|
||||||
|
|
||||||
{
|
|
||||||
"id": "srmp",
|
|
||||||
"name": "Slime Rancher Multiplayer",
|
|
||||||
"version": "0.0.<#= this.build #>",
|
|
||||||
"author": "SatyPardus",
|
|
||||||
"dependencies": [
|
|
||||||
|
|
||||||
]
|
|
||||||
}
|
|
||||||
|
|
||||||
<#+
|
|
||||||
int major = 0;
|
|
||||||
int minor = 0;
|
|
||||||
int revision = 0;
|
|
||||||
int build = 0;
|
|
||||||
#>
|
|
Loading…
Add table
Reference in a new issue