Skip to content

Commit a2bfb4f

Browse files
committed
Uniformize version numbers and assembly attributes, add missing file descriptions
1 parent a095ecc commit a2bfb4f

24 files changed

+91
-194
lines changed

BepInEx.Debug.sln

+13
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,20 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MirrorInternalLogs", "src\M
2323
EndProject
2424
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CtorShotgun", "src\CtorShotgun\CtorShotgun.csproj", "{B168EEDB-82B6-445B-AD19-96214B0D6537}"
2525
EndProject
26+
Project("{D954291E-2A0B-460D-934E-DC6B0785DB48}") = "Common", "src\Common\Common.shproj", "{DC4E3630-F21D-479F-9071-9FF62BCC7BB7}"
27+
EndProject
2628
Global
29+
GlobalSection(SharedMSBuildProjectFiles) = preSolution
30+
src\Common\Common.projitems*{241492bb-4f96-4286-b787-04b68bd44ddb}*SharedItemsImports = 4
31+
src\Common\Common.projitems*{29571930-f2e9-45dc-bb65-5b60c2b16850}*SharedItemsImports = 4
32+
src\Common\Common.projitems*{6081c5ae-ab5a-456b-a29f-3eef9ad9eedf}*SharedItemsImports = 4
33+
src\Common\Common.projitems*{679f65cb-10e1-4858-84d5-78d7a993facd}*SharedItemsImports = 4
34+
src\Common\Common.projitems*{967c527c-1a7e-4c83-9427-e92a6092f59e}*SharedItemsImports = 4
35+
src\Common\Common.projitems*{a909ba1c-4c18-49cf-a4e8-60584b7f2200}*SharedItemsImports = 4
36+
src\Common\Common.projitems*{b168eedb-82b6-445b-ad19-96214b0d6537}*SharedItemsImports = 4
37+
src\Common\Common.projitems*{dc4e3630-f21d-479f-9071-9ff62bcc7bb7}*SharedItemsImports = 13
38+
src\Common\Common.projitems*{e643a810-00a8-4b6f-83fc-b8631257eb43}*SharedItemsImports = 4
39+
EndGlobalSection
2740
GlobalSection(SolutionConfigurationPlatforms) = preSolution
2841
Debug|Any CPU = Debug|Any CPU
2942
Debug|x64 = Debug|x64

src/Common/AssemblyInfo.cs

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
using System.Reflection;
2+
using System.Runtime.InteropServices;
3+
using Common;
4+
5+
[assembly: AssemblyConfiguration("")]
6+
[assembly: AssemblyCompany("https://github.com/BepInEx/BepInEx.Debug")]
7+
[assembly: AssemblyCopyright("Copyright © 2020")]
8+
[assembly: AssemblyTrademark("")]
9+
[assembly: AssemblyCulture("")]
10+
11+
[assembly: ComVisible(false)]
12+
13+
[assembly: AssemblyVersion(Metadata.Version)]

src/Common/Common.projitems

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+
<PropertyGroup>
4+
<MSBuildAllProjects Condition="'$(MSBuildVersion)' == '' Or '$(MSBuildVersion)' &lt; '16.0'">$(MSBuildAllProjects);$(MSBuildThisFileFullPath)</MSBuildAllProjects>
5+
<HasSharedItems>true</HasSharedItems>
6+
<SharedGUID>dc4e3630-f21d-479f-9071-9ff62bcc7bb7</SharedGUID>
7+
</PropertyGroup>
8+
<PropertyGroup Label="Configuration">
9+
<Import_RootNamespace>Common</Import_RootNamespace>
10+
</PropertyGroup>
11+
<ItemGroup>
12+
<Compile Include="$(MSBuildThisFileDirectory)AssemblyInfo.cs" />
13+
<Compile Include="$(MSBuildThisFileDirectory)Metadata.cs" />
14+
</ItemGroup>
15+
</Project>

src/Common/Common.shproj

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+
<PropertyGroup Label="Globals">
4+
<ProjectGuid>dc4e3630-f21d-479f-9071-9ff62bcc7bb7</ProjectGuid>
5+
<MinimumVisualStudioVersion>14.0</MinimumVisualStudioVersion>
6+
</PropertyGroup>
7+
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
8+
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\CodeSharing\Microsoft.CodeSharing.Common.Default.props" />
9+
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\CodeSharing\Microsoft.CodeSharing.Common.props" />
10+
<PropertyGroup />
11+
<Import Project="Common.projitems" Label="Shared" />
12+
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\CodeSharing\Microsoft.CodeSharing.CSharp.targets" />
13+
</Project>

src/Common/Metadata.cs

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
using System;
2+
using System.Collections.Generic;
3+
using System.Text;
4+
5+
namespace Common
6+
{
7+
internal static class Metadata
8+
{
9+
public const string Version = "7.0";
10+
}
11+
}

src/ConstructorProfiler/ConstructorProfiler.cs

+5-1
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,16 @@
77
using System.Diagnostics;
88
using HarmonyLib;
99
using System.IO;
10+
using Common;
1011

1112
namespace ConstructorProfiler
1213
{
13-
[BepInPlugin("keelhauled.constructorprofiler", "Constructor Profiler", "1.0.0")]
14+
[BepInPlugin(GUID, "Constructor Profiler", Version)]
1415
public class ConstructorProfiler : BaseUnityPlugin
1516
{
17+
public const string GUID = "keelhauled.constructorprofiler";
18+
public const string Version = Metadata.Version;
19+
1620
private static string[] AssFilter = new[] { "Assembly-CSharp", "UnityEngine" };
1721
private static Dictionary<string, StackData> CallCounter = new Dictionary<string, StackData>();
1822
private Harmony harmony = new Harmony(nameof(ConstructorProfiler));

src/ConstructorProfiler/ConstructorProfiler.csproj

+1
Original file line numberDiff line numberDiff line change
@@ -59,5 +59,6 @@
5959
<ItemGroup>
6060
<Analyzer Include="..\..\packages\Microsoft.Unity.Analyzers.1.8.2\analyzers\dotnet\cs\Microsoft.Unity.Analyzers.dll" />
6161
</ItemGroup>
62+
<Import Project="..\Common\Common.projitems" Label="Shared" />
6263
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
6364
</Project>
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,7 @@
11
using System.Reflection;
2-
using System.Runtime.CompilerServices;
32
using System.Runtime.InteropServices;
43

5-
// General Information about an assembly is controlled through the following
6-
// set of attributes. Change these attribute values to modify the information
7-
// associated with an assembly.
84
[assembly: AssemblyTitle("ConstructorProfiler")]
95
[assembly: AssemblyDescription("")]
10-
[assembly: AssemblyConfiguration("")]
11-
[assembly: AssemblyCompany("")]
126
[assembly: AssemblyProduct("ConstructorProfiler")]
13-
[assembly: AssemblyCopyright("Copyright © 2020")]
14-
[assembly: AssemblyTrademark("")]
15-
[assembly: AssemblyCulture("")]
16-
17-
// Setting ComVisible to false makes the types in this assembly not visible
18-
// to COM components. If you need to access a type in this assembly from
19-
// COM, set the ComVisible attribute to true on that type.
20-
[assembly: ComVisible(false)]
21-
22-
// The following GUID is for the ID of the typelib if this project is exposed to COM
237
[assembly: Guid("241492bb-4f96-4286-b787-04b68bd44ddb")]
24-
25-
// Version information for an assembly consists of the following four values:
26-
//
27-
// Major Version
28-
// Minor Version
29-
// Build Number
30-
// Revision
31-
//
32-
// You can specify all the values or you can default the Build and Revision Numbers
33-
// by using the '*' as shown below:
34-
// [assembly: AssemblyVersion("1.0.*")]
35-
[assembly: AssemblyVersion("1.0.0.0")]
36-
[assembly: AssemblyFileVersion("1.0.0.0")]

src/CtorShotgun/CtorShotgun.csproj

+1
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@
6363
<ItemGroup>
6464
<None Include="packages.config" />
6565
</ItemGroup>
66+
<Import Project="..\Common\Common.projitems" Label="Shared" />
6667
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
6768
<Import Project="..\..\packages\BepInEx.Core.5.3.0.3\build\BepInEx.Core.targets" Condition="Exists('..\..\packages\BepInEx.Core.5.3.0.3\build\BepInEx.Core.targets')" />
6869
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
+1-30
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,7 @@
11
using System.Reflection;
2-
using System.Runtime.CompilerServices;
32
using System.Runtime.InteropServices;
43

5-
// General Information about an assembly is controlled through the following
6-
// set of attributes. Change these attribute values to modify the information
7-
// associated with an assembly.
84
[assembly: AssemblyTitle("CtorShotgun")]
95
[assembly: AssemblyDescription("")]
10-
[assembly: AssemblyConfiguration("")]
11-
[assembly: AssemblyCompany("")]
126
[assembly: AssemblyProduct("CtorShotgun")]
13-
[assembly: AssemblyCopyright("Copyright © 2020")]
14-
[assembly: AssemblyTrademark("")]
15-
[assembly: AssemblyCulture("")]
16-
17-
// Setting ComVisible to false makes the types in this assembly not visible
18-
// to COM components. If you need to access a type in this assembly from
19-
// COM, set the ComVisible attribute to true on that type.
20-
[assembly: ComVisible(false)]
21-
22-
// The following GUID is for the ID of the typelib if this project is exposed to COM
23-
[assembly: Guid("b168eedb-82b6-445b-ad19-96214b0d6537")]
24-
25-
// Version information for an assembly consists of the following four values:
26-
//
27-
// Major Version
28-
// Minor Version
29-
// Build Number
30-
// Revision
31-
//
32-
// You can specify all the values or you can default the Build and Revision Numbers
33-
// by using the '*' as shown below:
34-
// [assembly: AssemblyVersion("1.0.*")]
35-
[assembly: AssemblyVersion("1.0.0.0")]
36-
[assembly: AssemblyFileVersion("1.0.0.0")]
7+
[assembly: Guid("b168eedb-82b6-445b-ad19-96214b0d6537")]

src/DemystifyExceptions/DemystifyExceptions.csproj

+1
Original file line numberDiff line numberDiff line change
@@ -77,5 +77,6 @@
7777
<ItemGroup>
7878
<None Include="packages.config" />
7979
</ItemGroup>
80+
<Import Project="..\Common\Common.projitems" Label="Shared" />
8081
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
8182
</Project>
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,7 @@
11
using System.Reflection;
22
using System.Runtime.InteropServices;
33

4-
// General Information about an assembly is controlled through the following
5-
// set of attributes. Change these attribute values to modify the information
6-
// associated with an assembly.
74
[assembly: AssemblyTitle("DemystifyExceptions")]
8-
[assembly: AssemblyDescription("")]
9-
[assembly: AssemblyConfiguration("")]
10-
[assembly: AssemblyCompany("")]
5+
[assembly: AssemblyDescription("Turns exceptions into a more readable format, especially useful for async and enumerators")]
116
[assembly: AssemblyProduct("DemystifyExceptions")]
12-
[assembly: AssemblyCopyright("Copyright © 2019")]
13-
[assembly: AssemblyTrademark("")]
14-
[assembly: AssemblyCulture("")]
15-
16-
// Setting ComVisible to false makes the types in this assembly not visible
17-
// to COM components. If you need to access a type in this assembly from
18-
// COM, set the ComVisible attribute to true on that type.
19-
[assembly: ComVisible(false)]
20-
21-
// The following GUID is for the ID of the typelib if this project is exposed to COM
227
[assembly: Guid("679f65cb-10e1-4858-84d5-78d7a993facd")]
23-
24-
// Version information for an assembly consists of the following four values:
25-
//
26-
// Major Version
27-
// Minor Version
28-
// Build Number
29-
// Revision
30-
//
31-
// You can specify all the values or you can default the Build and Revision Numbers
32-
// by using the '*' as shown below:
33-
// [assembly: AssemblyVersion("1.0.*")]
34-
[assembly: AssemblyVersion("1.1.0")]

src/MirrorInternalLogs/MirrorInternalLogs.csproj

+1
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@
8686
<ItemGroup>
8787
<None Include="packages.config" />
8888
</ItemGroup>
89+
<Import Project="..\Common\Common.projitems" Label="Shared" />
8990
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
9091
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
9192
Other similar extension points exist, see Microsoft.Common.targets.
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,7 @@
11
using System.Reflection;
22
using System.Runtime.InteropServices;
33

4-
// General Information about an assembly is controlled through the following
5-
// set of attributes. Change these attribute values to modify the information
6-
// associated with an assembly.
74
[assembly: AssemblyTitle("MirrorInternalLogs")]
8-
[assembly: AssemblyDescription("")]
9-
[assembly: AssemblyConfiguration("")]
10-
[assembly: AssemblyCompany("")]
5+
[assembly: AssemblyDescription("Capture and mirror Unity internal debug logs into unity_log.txt")]
116
[assembly: AssemblyProduct("MirrorInternalLogs")]
12-
[assembly: AssemblyCopyright("Copyright © 2020")]
13-
[assembly: AssemblyTrademark("")]
14-
[assembly: AssemblyCulture("")]
15-
16-
// Setting ComVisible to false makes the types in this assembly not visible
17-
// to COM components. If you need to access a type in this assembly from
18-
// COM, set the ComVisible attribute to true on that type.
19-
[assembly: ComVisible(false)]
20-
21-
// The following GUID is for the ID of the typelib if this project is exposed to COM
227
[assembly: Guid("29571930-F2E9-45DC-BB65-5B60C2B16850")]
23-
24-
// Version information for an assembly consists of the following four values:
25-
//
26-
// Major Version
27-
// Minor Version
28-
// Build Number
29-
// Revision
30-
//
31-
// You can specify all the values or you can default the Build and Revision Numbers
32-
// by using the '*' as shown below:
33-
// [assembly: AssemblyVersion("1.0.*")]
34-
[assembly: AssemblyVersion("1.3.0.0")]
35-
[assembly: AssemblyFileVersion("1.3.0.0")]
+1-30
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,7 @@
11
using System.Reflection;
2-
using System.Runtime.CompilerServices;
32
using System.Runtime.InteropServices;
43

5-
// General Information about an assembly is controlled through the following
6-
// set of attributes. Change these attribute values to modify the information
7-
// associated with an assembly.
84
[assembly: AssemblyTitle("ScriptEngine")]
9-
[assembly: AssemblyDescription("")]
10-
[assembly: AssemblyConfiguration("")]
11-
[assembly: AssemblyCompany("")]
5+
[assembly: AssemblyDescription(@"Loads and reloads BepInEx plugins from the BepInEx\scripts folder")]
126
[assembly: AssemblyProduct("ScriptEngine")]
13-
[assembly: AssemblyCopyright("Copyright © 2019")]
14-
[assembly: AssemblyTrademark("")]
15-
[assembly: AssemblyCulture("")]
16-
17-
// Setting ComVisible to false makes the types in this assembly not visible
18-
// to COM components. If you need to access a type in this assembly from
19-
// COM, set the ComVisible attribute to true on that type.
20-
[assembly: ComVisible(false)]
21-
22-
// The following GUID is for the ID of the typelib if this project is exposed to COM
237
[assembly: Guid("967c527c-1a7e-4c83-9427-e92a6092f59e")]
24-
25-
// Version information for an assembly consists of the following four values:
26-
//
27-
// Major Version
28-
// Minor Version
29-
// Build Number
30-
// Revision
31-
//
32-
// You can specify all the values or you can default the Build and Revision Numbers
33-
// by using the '*' as shown below:
34-
// [assembly: AssemblyVersion("1.0.*")]
35-
[assembly: AssemblyVersion("1.0.0.0")]
36-
[assembly: AssemblyFileVersion(ScriptEngine.ScriptEngine.Version)]

src/ScriptEngine/ScriptEngine.cs

+2-1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
using System.Linq;
1111
using System.Reflection;
1212
using System.Text;
13+
using Common;
1314
using UnityEngine;
1415

1516
namespace ScriptEngine
@@ -18,7 +19,7 @@ namespace ScriptEngine
1819
public class ScriptEngine : BaseUnityPlugin
1920
{
2021
public const string GUID = "com.bepis.bepinex.scriptengine";
21-
public const string Version = "1.0.1";
22+
public const string Version = Metadata.Version;
2223

2324
public string ScriptDirectory => Path.Combine(Paths.BepInExRootPath, "scripts");
2425

src/ScriptEngine/ScriptEngine.csproj

+1
Original file line numberDiff line numberDiff line change
@@ -72,5 +72,6 @@
7272
<ItemGroup>
7373
<Analyzer Include="..\..\packages\Microsoft.Unity.Analyzers.1.8.2\analyzers\dotnet\cs\Microsoft.Unity.Analyzers.dll" />
7474
</ItemGroup>
75+
<Import Project="..\Common\Common.projitems" Label="Shared" />
7576
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
7677
</Project>

src/SimpleProfiler/MonoProfilerController/MonoProfilerController.cs

+5-3
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,16 @@
22
using System.IO;
33
using BepInEx;
44
using BepInEx.Configuration;
5+
using Common;
56
using UnityEngine;
67

78
namespace MonoProfiler
89
{
9-
[BepInPlugin("MonoProfiler", "MonoProfiler Controller", Version)]
10+
[BepInPlugin(GUID, "MonoProfiler Controller", Version)]
1011
public class MonoProfilerController : BaseUnityPlugin
1112
{
12-
public const string Version = "1.1";
13+
public const string GUID = "MonoProfiler";
14+
public const string Version = Metadata.Version;
1315

1416
private ConfigEntry<bool> _uniqueNames;
1517
private ConfigEntry<KeyboardShortcut> _key;
@@ -32,7 +34,7 @@ private void Update()
3234
if (_key.Value.IsDown())
3335
{
3436
var dumpFile = MonoProfilerPatcher.RunProfilerDump();
35-
if(_uniqueNames.Value)
37+
if (_uniqueNames.Value)
3638
dumpFile.MoveTo(Path.Combine(dumpFile.DirectoryName, $"{Path.GetFileNameWithoutExtension(dumpFile.Name)}_{DateTime.Now:yyyy-MM-dd_HH-mm-ss}{dumpFile.Extension}"));
3739
Logger.LogMessage("Saved profiler dump to " + dumpFile.FullName);
3840
}

src/SimpleProfiler/MonoProfilerController/MonoProfilerController.csproj

+1
Original file line numberDiff line numberDiff line change
@@ -58,5 +58,6 @@
5858
<ItemGroup>
5959
<Analyzer Include="..\..\..\packages\Microsoft.Unity.Analyzers.1.8.2\analyzers\dotnet\cs\Microsoft.Unity.Analyzers.dll" />
6060
</ItemGroup>
61+
<Import Project="..\..\Common\Common.projitems" Label="Shared" />
6162
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
6263
</Project>
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,7 @@
11
using System.Reflection;
22
using System.Runtime.InteropServices;
3-
using MonoProfiler;
43

54
[assembly: AssemblyTitle("MonoProfilerController")]
65
[assembly: AssemblyDescription("BepInEx plugin that allows more control over MonoProfiler")]
7-
[assembly: AssemblyCompany("https://github.com/BepInEx/BepInEx.Debug")]
86
[assembly: AssemblyProduct("MonoProfilerController")]
9-
[assembly: AssemblyCopyright("Copyright © 2020")]
10-
11-
[assembly: ComVisible(false)]
12-
[assembly: Guid("e643a810-00a8-4b6f-83fc-b8631257eb43")]
13-
14-
[assembly: AssemblyVersion(MonoProfilerController.Version)]
7+
[assembly: Guid("e643a810-00a8-4b6f-83fc-b8631257eb43")]

0 commit comments

Comments
 (0)