Skip to content

Commit

Permalink
Fix path finder and clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
FejZa committed May 10, 2024
1 parent dcc4731 commit 4007c67
Show file tree
Hide file tree
Showing 30 changed files with 49 additions and 367 deletions.
3 changes: 0 additions & 3 deletions .npmignore

This file was deleted.

4 changes: 3 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
Placeholder to be replaced by root [changelog](../../../CHANGELOG.md) during build
# Changelog

Please refer to the package's [Releases GitHub Page](https://github.com/realitycollective/com.realitytoolkit.spatial-persistence.arfoundation/releases) for the changelog.

This file was deleted.

11 changes: 10 additions & 1 deletion Editor/AssemblyInfo.cs.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
"GUID:9753fcbb5b1feaf459f435ac95e51baa",
"GUID:b2d046948d6452a4b8485efc9ce0f88c",
"GUID:2a3f0ca4e21332c44bfdce311ea8943e",
"GUID:c148ca4f0506aba4bb7c9e15a44bf2e3"
"GUID:c148ca4f0506aba4bb7c9e15a44bf2e3",
"GUID:4ddd23ea56a3a40f0aa0036d1624a53e"
],
"includePlatforms": [
"Editor"
Expand Down
13 changes: 7 additions & 6 deletions Editor/SpatialPersistence_ARFoundationPackageInstaller.cs
Original file line number Diff line number Diff line change
@@ -1,34 +1,35 @@
// Copyright (c) Reality Collective. All rights reserved.
// Copyright (c) Reality Collective. All rights reserved.
// Licensed under the MIT License. See LICENSE in the project root for license information.

using RealityCollective.ServiceFramework.Editor;
using RealityCollective.ServiceFramework.Editor.Packages;
using RealityCollective.Utilities.Editor;
using RealityCollective.Utilities.Extensions;
using RealityToolkit.Editor;
using RealityToolkit.Editor.Settings;
using System.IO;
using UnityEditor;
using UnityEngine;

namespace RealityToolkit.SpatialPersistence.ARFoundation.Editor
{
[InitializeOnLoad]
internal static class SpatialPersistence_ARFoundationPackageInstaller
{
private static readonly string destinationPath = Application.dataPath + "/RealityToolkit.Generated/SpatialPersistence_ARFoundation";
private static readonly string sourcePath = Path.GetFullPath($"{PathFinderUtility.ResolvePath<IPathFinder>(typeof(SpatialPersistence_ARFoundationPackagePathFinder)).ForwardSlashes()}{Path.DirectorySeparatorChar}{"Assets~"}");
private static readonly string destinationPath = Path.Combine(RealityToolkitEditorSettings.Instance.AssetImportPath, "SpatialPersistence_ARFoundation");
private static readonly string sourcePath = Path.GetFullPath($"{PathFinderUtility.ResolvePath<IPathFinder>(typeof(SpatialPersistence_ARFoundationPackagePathFinder)).ForwardSlashes()}{Path.DirectorySeparatorChar}{RealityToolkitPreferences.HIDDEN_PACKAGE_ASSETS_PATH}");

static SpatialPersistence_ARFoundationPackageInstaller()
{
EditorApplication.delayCall += CheckPackage;
}

[MenuItem(ServiceFrameworkPreferences.Editor_Menu_Keyword + "/Reality Toolkit/Packages/Install SpatialPersistence_ARFoundation Package Assets...", true)]
[MenuItem(RealityToolkitPreferences.Editor_Menu_Keyword + "/Packages / Install SpatialPersistence_ARFoundation Package Assets...", true)]
private static bool ImportPackageAssetsValidation()
{
return !Directory.Exists($"{destinationPath}{Path.DirectorySeparatorChar}");
}

[MenuItem(ServiceFrameworkPreferences.Editor_Menu_Keyword + "/Reality Toolkit/Packages/Install SpatialPersistence_ARFoundation Package Assets...")]
[MenuItem(RealityToolkitPreferences.Editor_Menu_Keyword + "/Packages / Install SpatialPersistence_ARFoundation Package Assets...")]
private static void ImportPackageAssets()
{
EditorPreferences.Set($"{nameof(SpatialPersistence_ARFoundationPackageInstaller)}.Assets", false);
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2022 Reality Collective
Copyright (c) 2022-2024 Reality Collective

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
11 changes: 10 additions & 1 deletion Runtime/AssemblyInfo.cs.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 0 additions & 8 deletions Tests.meta

This file was deleted.

8 changes: 0 additions & 8 deletions Tests/Editor.meta

This file was deleted.

9 changes: 0 additions & 9 deletions Tests/Editor/AssemblyInfo.cs

This file was deleted.

2 changes: 0 additions & 2 deletions Tests/Editor/AssemblyInfo.cs.meta

This file was deleted.

96 changes: 0 additions & 96 deletions Tests/Editor/EditorExampleTest.cs

This file was deleted.

11 changes: 0 additions & 11 deletions Tests/Editor/EditorExampleTest.cs.meta

This file was deleted.

This file was deleted.

This file was deleted.

8 changes: 0 additions & 8 deletions Tests/Runtime.meta

This file was deleted.

9 changes: 0 additions & 9 deletions Tests/Runtime/AssemblyInfo.cs

This file was deleted.

2 changes: 0 additions & 2 deletions Tests/Runtime/AssemblyInfo.cs.meta

This file was deleted.

This file was deleted.

This file was deleted.

Loading

0 comments on commit 4007c67

Please sign in to comment.