diff --git a/Editor/AssemblyInfo.cs b/Editor/AssemblyInfo.cs new file mode 100644 index 0000000..cee60dd --- /dev/null +++ b/Editor/AssemblyInfo.cs @@ -0,0 +1,9 @@ +// Copyright (c) Reality Collective. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +using System.Reflection; + +[assembly: AssemblyVersion("1.0.10")] +[assembly: AssemblyTitle("com.realitycollective.utilities.editor")] +[assembly: AssemblyCompany("Reality Collective")] +[assembly: AssemblyCopyright("Copyright (c) Reality Collective. All rights reserved.")] diff --git a/Editor/AssemblyInfo.cs.meta b/Editor/AssemblyInfo.cs.meta new file mode 100644 index 0000000..3e03617 --- /dev/null +++ b/Editor/AssemblyInfo.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b4fade3405f485a46a1a24be2acaf33b +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Editor/Utilities/AssemblyDefinitionPreProcessor.cs b/Editor/Utilities/AssemblyDefinitionPostprocessor.cs similarity index 83% rename from Editor/Utilities/AssemblyDefinitionPreProcessor.cs rename to Editor/Utilities/AssemblyDefinitionPostprocessor.cs index f65b7f7..ce6f15f 100644 --- a/Editor/Utilities/AssemblyDefinitionPreProcessor.cs +++ b/Editor/Utilities/AssemblyDefinitionPostprocessor.cs @@ -9,7 +9,7 @@ namespace RealityCollective.Editor.Utilities { - internal class AssemblyDefinitionPreProcessor : AssetPostprocessor + internal class AssemblyDefinitionPostprocessor : AssetPostprocessor { [Serializable] private class PackageInfo @@ -39,16 +39,21 @@ private void OnPreprocessAsset() var text = File.ReadAllText(assetPath); var packageJson = JsonUtility.FromJson(text); - if (!packageJson.Name.Contains("com.xrtk")) + if (!packageJson.Name.Contains("com.realitycollective") && + !packageJson.Name.Contains("com.realitytoolkit")) { return; } var packageVersion = packageJson.Version; - if (packageVersion.Contains("-preview.")) + if (packageVersion.Contains("-pre.")) { +#if UNITY_2021_1_OR_NEWER + packageVersion = packageVersion[..packageVersion.IndexOf("-", StringComparison.Ordinal)]; +#else packageVersion = packageVersion.Substring(0, packageVersion.IndexOf("-", StringComparison.Ordinal)); +#endif } var newVersion = $"[assembly: AssemblyVersion(\"{packageVersion}\")]"; @@ -67,8 +72,8 @@ private void OnPreprocessAsset() [assembly: AssemblyVersion(""0.0.0"")] [assembly: AssemblyTitle(""com.{assemblyName}"")] -[assembly: AssemblyCompany(""XRTK"")] -[assembly: AssemblyCopyright(""Copyright (c) XRTK. All rights reserved."")] +[assembly: AssemblyCompany(""Reality Collective"")] +[assembly: AssemblyCopyright(""Copyright (c) Reality Collective. All rights reserved."")] " : File.ReadAllText(assemblyInfoPath); diff --git a/Editor/Utilities/AssemblyDefinitionPreProcessor.cs.meta b/Editor/Utilities/AssemblyDefinitionPostprocessor.cs.meta similarity index 100% rename from Editor/Utilities/AssemblyDefinitionPreProcessor.cs.meta rename to Editor/Utilities/AssemblyDefinitionPostprocessor.cs.meta diff --git a/Runtime/AssemblyInfo.cs b/Runtime/AssemblyInfo.cs new file mode 100644 index 0000000..0bb5d68 --- /dev/null +++ b/Runtime/AssemblyInfo.cs @@ -0,0 +1,9 @@ +// Copyright (c) Reality Collective. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +using System.Reflection; + +[assembly: AssemblyVersion("1.0.10")] +[assembly: AssemblyTitle("com.realitycollective.utilities")] +[assembly: AssemblyCompany("Reality Collective")] +[assembly: AssemblyCopyright("Copyright (c) Reality Collective. All rights reserved.")] diff --git a/Runtime/AssemblyInfo.cs.meta b/Runtime/AssemblyInfo.cs.meta new file mode 100644 index 0000000..19105f9 --- /dev/null +++ b/Runtime/AssemblyInfo.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 1b2ab339a26424b42a838ed5ba250b0d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Tests/AssemblyInfo.cs b/Tests/AssemblyInfo.cs new file mode 100644 index 0000000..3a92ae5 --- /dev/null +++ b/Tests/AssemblyInfo.cs @@ -0,0 +1,9 @@ +// Copyright (c) Reality Collective. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +using System.Reflection; + +[assembly: AssemblyVersion("1.0.10")] +[assembly: AssemblyTitle("com.realitycollective.utilities.tests")] +[assembly: AssemblyCompany("Reality Collective")] +[assembly: AssemblyCopyright("Copyright (c) Reality Collective. All rights reserved.")] diff --git a/Tests/AssemblyInfo.cs.meta b/Tests/AssemblyInfo.cs.meta new file mode 100644 index 0000000..c512c4d --- /dev/null +++ b/Tests/AssemblyInfo.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: f23ed519a6a51c6409646e5e30d3153d +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/package.json b/package.json index 75fda9a..1ad6f00 100644 --- a/package.json +++ b/package.json @@ -1,12 +1,12 @@ { "name": "com.realitycollective.utilities", "displayName": "RealityCollective.Utilities", - "description": "A collection of useful utilities for Unity Projects by the Reality Collective", + "description": "A collection of useful utilities for Unity Projects by the Reality Collective.", "keywords": [ "Unity", "Tools" ], - "version": "1.0.9", + "version": "1.0.10-pre.2", "unity": "2020.3", "homepage": "https://realitycollective.io", "bugs": {