From 7838df6538ba285418c89c1751024a9d5bc978c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dino=20Fejzagi=C4=87?= Date: Sun, 5 May 2024 16:50:54 +0200 Subject: [PATCH] Fix assembly info pre processor --- Editor/Utilities/AssemblyDefinitionPreProcessor.cs | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/Editor/Utilities/AssemblyDefinitionPreProcessor.cs b/Editor/Utilities/AssemblyDefinitionPreProcessor.cs index f65b7f7..0e6834b 100644 --- a/Editor/Utilities/AssemblyDefinitionPreProcessor.cs +++ b/Editor/Utilities/AssemblyDefinitionPreProcessor.cs @@ -39,16 +39,17 @@ 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.")) { - packageVersion = packageVersion.Substring(0, packageVersion.IndexOf("-", StringComparison.Ordinal)); + packageVersion = packageVersion[..packageVersion.IndexOf("-", StringComparison.Ordinal)]; } var newVersion = $"[assembly: AssemblyVersion(\"{packageVersion}\")]"; @@ -67,8 +68,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);