From 019b74073e36616d85b4b9389e3b90d92ecf8783 Mon Sep 17 00:00:00 2001 From: Ivan Murzak Date: Wed, 24 Sep 2025 00:39:21 -0700 Subject: [PATCH 1/6] Fix image loader animation link in README.md --- README.md | 2 +- Unity-Package/Assets/root/README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 242d654..fffbf76 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ [![License](https://img.shields.io/github/license/IvanMurzak/Unity-ImageLoader?label=License)](https://github.com/IvanMurzak/Unity-ImageLoader/blob/main/LICENSE) [![Stand With Ukraine](https://raw.githubusercontent.com/vshymanskyy/StandWithUkraine/main/badges/StandWithUkraine.svg)](https://stand-with-ukraine.pp.ua) -![Image Loader Animation](https://github.com/IvanMurza/Unity-ImageLoader/blob/main/docs/img/header.gif 'Image Loading Animation') +![Image Loader Animation](https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/docs/img/header.gif 'Image Loading Animation') Async image loader with two caching layers for Unity. It supports loading images from web or local paths and provides memory and disk caching to optimize performance. The package includes features for automatic image setting, cancellation handling, error handling, and lifecycle management. diff --git a/Unity-Package/Assets/root/README.md b/Unity-Package/Assets/root/README.md index 242d654..fffbf76 100644 --- a/Unity-Package/Assets/root/README.md +++ b/Unity-Package/Assets/root/README.md @@ -10,7 +10,7 @@ [![License](https://img.shields.io/github/license/IvanMurzak/Unity-ImageLoader?label=License)](https://github.com/IvanMurzak/Unity-ImageLoader/blob/main/LICENSE) [![Stand With Ukraine](https://raw.githubusercontent.com/vshymanskyy/StandWithUkraine/main/badges/StandWithUkraine.svg)](https://stand-with-ukraine.pp.ua) -![Image Loader Animation](https://github.com/IvanMurza/Unity-ImageLoader/blob/main/docs/img/header.gif 'Image Loading Animation') +![Image Loader Animation](https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/docs/img/header.gif 'Image Loading Animation') Async image loader with two caching layers for Unity. It supports loading images from web or local paths and provides memory and disk caching to optimize performance. The package includes features for automatic image setting, cancellation handling, error handling, and lifecycle management. From 2641675b7bce051cb135389e6525273d923061cd Mon Sep 17 00:00:00 2001 From: Ivan Murzak Date: Wed, 24 Sep 2025 00:49:26 -0700 Subject: [PATCH 2/6] Update image URLs in TestUtils and add test images --- .../Assets/root/Tests/Base/Utils/TestUtils.cs | 6 +++--- .../Test Images => docs/img/test}/ImageA.jpg | Bin .../Test Images => docs/img/test}/ImageB.png | Bin .../Test Images => docs/img/test}/ImageC.png | Bin 4 files changed, 3 insertions(+), 3 deletions(-) rename {Unity-Package/Test Images => docs/img/test}/ImageA.jpg (100%) rename {Unity-Package/Test Images => docs/img/test}/ImageB.png (100%) rename {Unity-Package/Test Images => docs/img/test}/ImageC.png (100%) diff --git a/Unity-Package/Assets/root/Tests/Base/Utils/TestUtils.cs b/Unity-Package/Assets/root/Tests/Base/Utils/TestUtils.cs index 503e6be..91c5dd2 100644 --- a/Unity-Package/Assets/root/Tests/Base/Utils/TestUtils.cs +++ b/Unity-Package/Assets/root/Tests/Base/Utils/TestUtils.cs @@ -12,9 +12,9 @@ public static partial class TestUtils { public static readonly string[] ImageURLs = { - "https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/Test%20Images/ImageA.jpg", - "https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/Test%20Images/ImageB.png", - "https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/Test%20Images/ImageC.png" + "https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/docs/img/test/ImageA.jpg", + "https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/docs/img/test/ImageB.png", + "https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/docs/img/test/ImageC.png" }; public static string IncorrectImageURL => $"https://doesntexist.com/{Guid.NewGuid()}.png"; public static IEnumerable IncorrectImageURLs(int count = 3) => Enumerable.Range(0, count).Select(_ => IncorrectImageURL); diff --git a/Unity-Package/Test Images/ImageA.jpg b/docs/img/test/ImageA.jpg similarity index 100% rename from Unity-Package/Test Images/ImageA.jpg rename to docs/img/test/ImageA.jpg diff --git a/Unity-Package/Test Images/ImageB.png b/docs/img/test/ImageB.png similarity index 100% rename from Unity-Package/Test Images/ImageB.png rename to docs/img/test/ImageB.png diff --git a/Unity-Package/Test Images/ImageC.png b/docs/img/test/ImageC.png similarity index 100% rename from Unity-Package/Test Images/ImageC.png rename to docs/img/test/ImageC.png From 48e36fdd5999b639b61432d63da716d90b86ac9d Mon Sep 17 00:00:00 2001 From: Ivan Murzak Date: Wed, 24 Sep 2025 02:10:11 -0700 Subject: [PATCH 3/6] Remove obsolete asset validation tests and associated files from Asset Store Tools package. Update package.json to reference the GitHub repository directly. Add new project settings files for memory and version control configurations. Update ProjectVersion.txt to reflect the new Unity editor version. Clean up unnecessary files and ensure proper package management. --- .github/workflows/release.yml | 2 +- .github/workflows/test_pull_request.yml | 2 +- Installer/.vscode/extensions.json | 5 + Installer/.vscode/launch.json | 10 + Installer/.vscode/settings.json | 108 +-- .../com.unity.asset-store-tools/CHANGELOG.md | 324 --------- .../CHANGELOG.md.meta | 7 - .../com.unity.asset-store-tools/Editor.meta | 8 - .../Editor/Api.meta | 8 - .../Editor/Api/Abstractions.meta | 8 - .../Api/Abstractions/AuthenticationBase.cs | 48 -- .../Abstractions/AuthenticationBase.cs.meta | 11 - .../Editor/Api/Abstractions/IAssetStoreApi.cs | 21 - .../Api/Abstractions/IAssetStoreApi.cs.meta | 11 - .../Api/Abstractions/IAssetStoreClient.cs | 18 - .../Abstractions/IAssetStoreClient.cs.meta | 11 - .../Api/Abstractions/IAuthenticationType.cs | 11 - .../Abstractions/IAuthenticationType.cs.meta | 11 - .../Api/Abstractions/IPackageUploader.cs | 12 - .../Api/Abstractions/IPackageUploader.cs.meta | 11 - .../Api/Abstractions/PackageUploaderBase.cs | 59 -- .../Abstractions/PackageUploaderBase.cs.meta | 11 - .../Editor/Api/ApiUtility.cs | 76 -- .../Editor/Api/ApiUtility.cs.meta | 11 - .../Editor/Api/AssetStoreApi.cs | 268 ------- .../Editor/Api/AssetStoreApi.cs.meta | 11 - .../Editor/Api/AssetStoreClient.cs | 55 -- .../Editor/Api/AssetStoreClient.cs.meta | 11 - .../Editor/Api/CloudTokenAuthentication.cs | 25 - .../Api/CloudTokenAuthentication.cs.meta | 11 - .../Editor/Api/CredentialsAuthentication.cs | 26 - .../Api/CredentialsAuthentication.cs.meta | 11 - .../Editor/Api/Models.meta | 8 - .../Editor/Api/Models/Category.cs | 58 -- .../Editor/Api/Models/Category.cs.meta | 11 - .../Editor/Api/Models/Package.cs | 80 --- .../Editor/Api/Models/Package.cs.meta | 11 - .../Api/Models/PackageAdditionalData.cs | 41 -- .../Api/Models/PackageAdditionalData.cs.meta | 11 - .../Editor/Api/Models/User.cs | 51 -- .../Editor/Api/Models/User.cs.meta | 11 - .../Editor/Api/Responses.meta | 8 - .../Api/Responses/AssetStoreResponse.cs | 45 -- .../Api/Responses/AssetStoreResponse.cs.meta | 11 - .../AssetStoreToolsVersionResponse.cs | 38 - .../AssetStoreToolsVersionResponse.cs.meta | 11 - .../Api/Responses/AuthenticationResponse.cs | 74 -- .../Responses/AuthenticationResponse.cs.meta | 11 - .../Api/Responses/CategoryDataResponse.cs | 43 -- .../Responses/CategoryDataResponse.cs.meta | 11 - .../Api/Responses/PackageThumbnailResponse.cs | 31 - .../PackageThumbnailResponse.cs.meta | 11 - ...PackageUploadedUnityVersionDataResponse.cs | 44 -- ...geUploadedUnityVersionDataResponse.cs.meta | 11 - .../PackagesAdditionalDataResponse.cs | 59 -- .../PackagesAdditionalDataResponse.cs.meta | 11 - .../Api/Responses/PackagesDataResponse.cs | 59 -- .../Responses/PackagesDataResponse.cs.meta | 11 - .../Responses/RefreshedPackageDataResponse.cs | 12 - .../RefreshedPackageDataResponse.cs.meta | 11 - .../Editor/Api/Responses/UploadResponse.cs | 28 - .../Api/Responses/UploadResponse.cs.meta | 11 - .../Editor/Api/SessionAuthentication.cs | 25 - .../Editor/Api/SessionAuthentication.cs.meta | 11 - .../Editor/Api/UnityPackageUploader.cs | 99 --- .../Editor/Api/UnityPackageUploader.cs.meta | 11 - .../Editor/Api/UploadStatus.cs | 11 - .../Editor/Api/UploadStatus.cs.meta | 11 - .../Editor/AssemblyInfo.cs | 5 - .../Editor/AssemblyInfo.cs.meta | 11 - .../Editor/AssetStoreTools.cs | 82 --- .../Editor/AssetStoreTools.cs.meta | 11 - .../Editor/AssetStoreToolsWindow.cs | 23 - .../Editor/AssetStoreToolsWindow.cs.meta | 11 - .../Editor/Constants.cs | 178 ----- .../Editor/Constants.cs.meta | 11 - .../Editor/Exporter.meta | 8 - .../Editor/Exporter/Abstractions.meta | 8 - .../Exporter/Abstractions/IPackageExporter.cs | 11 - .../Abstractions/IPackageExporter.cs.meta | 11 - .../Exporter/Abstractions/IPreviewInjector.cs | 7 - .../Abstractions/IPreviewInjector.cs.meta | 11 - .../Abstractions/PackageExporterBase.cs | 134 ---- .../Abstractions/PackageExporterBase.cs.meta | 11 - .../Abstractions/PackageExporterSettings.cs | 7 - .../PackageExporterSettings.cs.meta | 11 - .../Exporter/DefaultExporterSettings.cs | 11 - .../Exporter/DefaultExporterSettings.cs.meta | 11 - .../Editor/Exporter/DefaultPackageExporter.cs | 304 -------- .../Exporter/DefaultPackageExporter.cs.meta | 11 - .../Editor/Exporter/LegacyExporterSettings.cs | 8 - .../Exporter/LegacyExporterSettings.cs.meta | 11 - .../Editor/Exporter/LegacyPackageExporter.cs | 109 --- .../Exporter/LegacyPackageExporter.cs.meta | 11 - .../Editor/Exporter/PackageExporterResult.cs | 13 - .../Exporter/PackageExporterResult.cs.meta | 11 - .../Editor/Exporter/PreviewInjector.cs | 41 -- .../Editor/Exporter/PreviewInjector.cs.meta | 11 - .../Editor/Previews.meta | 8 - .../Editor/Previews/Scripts.meta | 8 - .../Editor/Previews/Scripts/Data.meta | 8 - .../Data/CustomPreviewGenerationSettings.cs | 19 - .../CustomPreviewGenerationSettings.cs.meta | 11 - .../Previews/Scripts/Data/FileNameFormat.cs | 9 - .../Scripts/Data/FileNameFormat.cs.meta | 11 - .../Previews/Scripts/Data/GenerationType.cs | 9 - .../Scripts/Data/GenerationType.cs.meta | 11 - .../Data/NativePreviewGenerationSettings.cs | 10 - .../NativePreviewGenerationSettings.cs.meta | 11 - .../Previews/Scripts/Data/PreviewDatabase.cs | 14 - .../Scripts/Data/PreviewDatabase.cs.meta | 11 - .../Previews/Scripts/Data/PreviewFormat.cs | 8 - .../Scripts/Data/PreviewFormat.cs.meta | 11 - .../Scripts/Data/PreviewGenerationResult.cs | 14 - .../Data/PreviewGenerationResult.cs.meta | 11 - .../Scripts/Data/PreviewGenerationSettings.cs | 12 - .../Data/PreviewGenerationSettings.cs.meta | 11 - .../Previews/Scripts/Data/PreviewMetadata.cs | 17 - .../Scripts/Data/PreviewMetadata.cs.meta | 11 - .../Editor/Previews/Scripts/Generators.meta | 8 - .../Previews/Scripts/Generators/Custom.meta | 8 - .../Scripts/Generators/Custom/AudioChannel.cs | 97 --- .../Generators/Custom/AudioChannel.cs.meta | 11 - .../Custom/AudioChannelCoordinate.cs | 18 - .../Custom/AudioChannelCoordinate.cs.meta | 11 - .../Generators/Custom/Screenshotters.meta | 8 - .../Screenshotters/ISceneScreenshotter.cs | 12 - .../ISceneScreenshotter.cs.meta | 11 - .../Screenshotters/MaterialScreenshotter.cs | 32 - .../MaterialScreenshotter.cs.meta | 11 - .../Screenshotters/MeshScreenshotter.cs | 33 - .../Screenshotters/MeshScreenshotter.cs.meta | 11 - .../Screenshotters/SceneScreenshotterBase.cs | 124 ---- .../SceneScreenshotterBase.cs.meta | 11 - .../SceneScreenshotterSettings.cs | 16 - .../SceneScreenshotterSettings.cs.meta | 11 - .../Generators/Custom/TypeGenerators.meta | 8 - .../AudioTypeGeneratorSettings.cs | 15 - .../AudioTypeGeneratorSettings.cs.meta | 11 - .../AudioTypePreviewGenerator.cs | 207 ------ .../AudioTypePreviewGenerator.cs.meta | 11 - .../TypeGenerators/ITypePreviewGenerator.cs | 16 - .../ITypePreviewGenerator.cs.meta | 11 - .../MaterialTypePreviewGenerator.cs | 85 --- .../MaterialTypePreviewGenerator.cs.meta | 11 - .../ModelTypePreviewGenerator.cs | 86 --- .../ModelTypePreviewGenerator.cs.meta | 11 - .../PrefabTypePreviewGenerator.cs | 113 --- .../PrefabTypePreviewGenerator.cs.meta | 11 - .../TextureTypeGeneratorSettings.cs | 11 - .../TextureTypeGeneratorSettings.cs.meta | 11 - .../TextureTypePreviewGenerator.cs | 116 --- .../TextureTypePreviewGenerator.cs.meta | 11 - .../TypeGenerators/TypeGeneratorSettings.cs | 12 - .../TypeGeneratorSettings.cs.meta | 11 - .../TypePreviewGeneratorBase.cs | 126 ---- .../TypePreviewGeneratorBase.cs.meta | 11 - .../TypePreviewGeneratorFromScene.cs | 111 --- .../TypePreviewGeneratorFromScene.cs.meta | 11 - .../TypePreviewGeneratorFromSceneSettings.cs | 9 - ...ePreviewGeneratorFromSceneSettings.cs.meta | 11 - .../Generators/CustomPreviewGenerator.cs | 213 ------ .../Generators/CustomPreviewGenerator.cs.meta | 11 - .../Scripts/Generators/IPreviewGenerator.cs | 15 - .../Generators/IPreviewGenerator.cs.meta | 11 - .../Generators/NativePreviewGenerator.cs | 362 ---------- .../Generators/NativePreviewGenerator.cs.meta | 11 - .../Generators/PreviewGeneratorBase.cs | 45 -- .../Generators/PreviewGeneratorBase.cs.meta | 11 - .../Editor/Previews/Scripts/Services.meta | 8 - .../Previews/Scripts/Services/Caching.meta | 8 - .../Services/Caching/CachingService.cs | 87 --- .../Services/Caching/CachingService.cs.meta | 11 - .../Services/Caching/ICachingService.cs | 11 - .../Services/Caching/ICachingService.cs.meta | 11 - .../Scripts/Services/IPreviewService.cs | 4 - .../Scripts/Services/IPreviewService.cs.meta | 11 - .../Services/PreviewServiceProvider.cs | 17 - .../Services/PreviewServiceProvider.cs.meta | 11 - .../Editor/Previews/Scripts/UI.meta | 8 - .../Editor/Previews/Scripts/UI/Data.meta | 8 - .../Previews/Scripts/UI/Data/AssetPreview.cs | 56 -- .../Scripts/UI/Data/AssetPreview.cs.meta | 11 - .../Scripts/UI/Data/AssetPreviewCollection.cs | 46 -- .../UI/Data/AssetPreviewCollection.cs.meta | 11 - .../Previews/Scripts/UI/Data/IAssetPreview.cs | 13 - .../Scripts/UI/Data/IAssetPreview.cs.meta | 11 - .../UI/Data/IAssetPreviewCollection.cs | 15 - .../UI/Data/IAssetPreviewCollection.cs.meta | 11 - .../UI/Data/IPreviewGeneratorSettings.cs | 27 - .../UI/Data/IPreviewGeneratorSettings.cs.meta | 11 - .../UI/Data/PreviewGeneratorSettings.cs | 212 ------ .../UI/Data/PreviewGeneratorSettings.cs.meta | 11 - .../Editor/Previews/Scripts/UI/Elements.meta | 8 - .../UI/Elements/AssetPreviewElement.cs | 83 --- .../UI/Elements/AssetPreviewElement.cs.meta | 11 - .../Scripts/UI/Elements/GridListElement.cs | 140 ---- .../UI/Elements/GridListElement.cs.meta | 11 - .../UI/Elements/PreviewCollectionElement.cs | 116 --- .../Elements/PreviewCollectionElement.cs.meta | 11 - .../Elements/PreviewGenerateButtonElement.cs | 50 -- .../PreviewGenerateButtonElement.cs.meta | 11 - .../Elements/PreviewGeneratorPathsElement.cs | 122 ---- .../PreviewGeneratorPathsElement.cs.meta | 11 - .../PreviewGeneratorSettingsElement.cs | 99 --- .../PreviewGeneratorSettingsElement.cs.meta | 11 - .../PreviewWindowDescriptionElement.cs | 87 --- .../PreviewWindowDescriptionElement.cs.meta | 11 - .../Scripts/UI/PreviewGeneratorWindow.cs | 51 -- .../Scripts/UI/PreviewGeneratorWindow.cs.meta | 11 - .../Editor/Previews/Scripts/UI/Views.meta | 8 - .../Scripts/UI/Views/PreviewListView.cs | 142 ---- .../Scripts/UI/Views/PreviewListView.cs.meta | 11 - .../Editor/Previews/Scripts/Utility.meta | 8 - .../Scripts/Utility/GraphicsUtility.cs | 96 --- .../Scripts/Utility/GraphicsUtility.cs.meta | 11 - .../Scripts/Utility/PreviewConvertUtility.cs | 72 -- .../Utility/PreviewConvertUtility.cs.meta | 11 - .../Scripts/Utility/PreviewSceneUtility.cs | 196 ------ .../Utility/PreviewSceneUtility.cs.meta | 11 - .../Scripts/Utility/RenderPipeline.cs | 10 - .../Scripts/Utility/RenderPipeline.cs.meta | 11 - .../Scripts/Utility/RenderPipelineUtility.cs | 32 - .../Utility/RenderPipelineUtility.cs.meta | 11 - .../Editor/Previews/Styles.meta | 8 - .../Editor/Previews/Styles/Style.uss | 210 ------ .../Editor/Previews/Styles/Style.uss.meta | 11 - .../Editor/Previews/Styles/ThemeDark.uss | 67 -- .../Editor/Previews/Styles/ThemeDark.uss.meta | 11 - .../Editor/Previews/Styles/ThemeLight.uss | 67 -- .../Previews/Styles/ThemeLight.uss.meta | 11 - .../Unity.AssetStoreTools.Editor.asmdef | 36 - .../Unity.AssetStoreTools.Editor.asmdef.meta | 7 - .../Editor/Uploader.meta | 8 - .../Editor/Uploader/Icons.meta | 8 - .../Editor/Uploader/Icons/account-dark.png | Bin 337 -> 0 bytes .../Uploader/Icons/account-dark.png.meta | 123 ---- .../Editor/Uploader/Icons/account-light.png | Bin 387 -> 0 bytes .../Uploader/Icons/account-light.png.meta | 123 ---- .../Editor/Uploader/Icons/open-in-browser.png | Bin 878 -> 0 bytes .../Uploader/Icons/open-in-browser.png.meta | 147 ---- .../Uploader/Icons/publisher-portal-dark.png | Bin 33588 -> 0 bytes .../Icons/publisher-portal-dark.png.meta | 128 ---- .../Uploader/Icons/publisher-portal-light.png | Bin 33281 -> 0 bytes .../Icons/publisher-portal-light.png.meta | 135 ---- .../Editor/Uploader/Scripts.meta | 8 - .../Editor/Uploader/Scripts/Data.meta | 8 - .../Uploader/Scripts/Data/Abstractions.meta | 8 - .../Scripts/Data/Abstractions/IPackage.cs | 34 - .../Data/Abstractions/IPackage.cs.meta | 11 - .../Data/Abstractions/IPackageContent.cs | 14 - .../Data/Abstractions/IPackageContent.cs.meta | 11 - .../Data/Abstractions/IPackageGroup.cs | 17 - .../Data/Abstractions/IPackageGroup.cs.meta | 11 - .../Scripts/Data/Abstractions/IWorkflow.cs | 36 - .../Data/Abstractions/IWorkflow.cs.meta | 11 - .../Data/Abstractions/IWorkflowServices.cs | 18 - .../Abstractions/IWorkflowServices.cs.meta | 11 - .../Scripts/Data/Abstractions/WorkflowBase.cs | 253 ------- .../Data/Abstractions/WorkflowBase.cs.meta | 11 - .../Uploader/Scripts/Data/AssetsWorkflow.cs | 329 --------- .../Scripts/Data/AssetsWorkflow.cs.meta | 11 - .../Scripts/Data/HybridPackageWorkflow.cs | 251 ------- .../Data/HybridPackageWorkflow.cs.meta | 11 - .../Editor/Uploader/Scripts/Data/Package.cs | 91 --- .../Uploader/Scripts/Data/Package.cs.meta | 11 - .../Uploader/Scripts/Data/PackageContent.cs | 68 -- .../Scripts/Data/PackageContent.cs.meta | 11 - .../Uploader/Scripts/Data/PackageGroup.cs | 64 -- .../Scripts/Data/PackageGroup.cs.meta | 11 - .../Uploader/Scripts/Data/PackageSorting.cs | 9 - .../Scripts/Data/PackageSorting.cs.meta | 11 - .../Uploader/Scripts/Data/Serialization.meta | 8 - .../Scripts/Data/Serialization/AssetPath.cs | 59 -- .../Data/Serialization/AssetPath.cs.meta | 11 - .../Serialization/AssetsWorkflowStateData.cs | 77 -- .../AssetsWorkflowStateData.cs.meta | 11 - .../HybridPackageWorkflowState.cs | 41 -- .../HybridPackageWorkflowState.cs.meta | 11 - .../UnityPackageWorkflowStateData.cs | 25 - .../UnityPackageWorkflowStateData.cs.meta | 11 - .../Data/Serialization/WorkflowStateData.cs | 68 -- .../Serialization/WorkflowStateData.cs.meta | 11 - .../Scripts/Data/UnityPackageWorkflow.cs | 135 ---- .../Scripts/Data/UnityPackageWorkflow.cs.meta | 11 - .../Uploader/Scripts/Data/WorkflowServices.cs | 53 -- .../Scripts/Data/WorkflowServices.cs.meta | 11 - .../Editor/Uploader/Scripts/Services.meta | 8 - .../Uploader/Scripts/Services/Analytics.meta | 8 - .../Services/Analytics/AnalyticsService.cs | 45 -- .../Analytics/AnalyticsService.cs.meta | 11 - .../Scripts/Services/Analytics/Data.meta | 8 - .../Analytics/Data/AuthenticationAnalytic.cs | 46 -- .../Data/AuthenticationAnalytic.cs.meta | 11 - .../Services/Analytics/Data/BaseAnalytic.cs | 35 - .../Analytics/Data/BaseAnalytic.cs.meta | 11 - .../Analytics/Data/IAssetStoreAnalytic.cs | 16 - .../Data/IAssetStoreAnalytic.cs.meta | 11 - .../Analytics/Data/IAssetStoreAnalyticData.cs | 8 - .../Data/IAssetStoreAnalyticData.cs.meta | 11 - .../Analytics/Data/PackageUploadAnalytic.cs | 72 -- .../Data/PackageUploadAnalytic.cs.meta | 11 - .../Data/ValidationResultsSerializer.cs | 91 --- .../Data/ValidationResultsSerializer.cs.meta | 11 - .../Services/Analytics/IAnalyticsService.cs | 10 - .../Analytics/IAnalyticsService.cs.meta | 11 - .../Editor/Uploader/Scripts/Services/Api.meta | 8 - .../Services/Api/AuthenticationService.cs | 100 --- .../Api/AuthenticationService.cs.meta | 11 - .../Services/Api/IAuthenticationService.cs | 16 - .../Api/IAuthenticationService.cs.meta | 11 - .../Api/IPackageDownloadingService.cs | 16 - .../Api/IPackageDownloadingService.cs.meta | 11 - .../Services/Api/IPackageUploadingService.cs | 16 - .../Api/IPackageUploadingService.cs.meta | 11 - .../Services/Api/PackageDownloadingService.cs | 109 --- .../Api/PackageDownloadingService.cs.meta | 11 - .../Services/Api/PackageUploadingService.cs | 103 --- .../Api/PackageUploadingService.cs.meta | 11 - .../Uploader/Scripts/Services/Caching.meta | 8 - .../Services/Caching/CachingService.cs | 157 ----- .../Services/Caching/CachingService.cs.meta | 11 - .../Services/Caching/ICachingService.cs | 25 - .../Services/Caching/ICachingService.cs.meta | 11 - .../Scripts/Services/IUploaderService.cs | 4 - .../Scripts/Services/IUploaderService.cs.meta | 11 - .../Scripts/Services/PackageFactory.meta | 8 - .../PackageFactory/IPackageFactoryService.cs | 18 - .../IPackageFactoryService.cs.meta | 11 - .../PackageFactory/PackageFactoryService.cs | 95 --- .../PackageFactoryService.cs.meta | 11 - .../Services/UploaderServiceProvider.cs | 26 - .../Services/UploaderServiceProvider.cs.meta | 11 - .../Editor/Uploader/Scripts/UI.meta | 8 - .../Editor/Uploader/Scripts/UI/Elements.meta | 8 - .../Scripts/UI/Elements/Abstractions.meta | 8 - .../Abstractions/ValidationElementBase.cs | 170 ----- .../ValidationElementBase.cs.meta | 11 - .../Abstractions/WorkflowElementBase.cs | 151 ---- .../Abstractions/WorkflowElementBase.cs.meta | 11 - .../Scripts/UI/Elements/AccountToolbar.cs | 102 --- .../UI/Elements/AccountToolbar.cs.meta | 11 - .../UI/Elements/AssetsWorkflowElement.cs | 215 ------ .../UI/Elements/AssetsWorkflowElement.cs.meta | 11 - .../CurrentProjectValidationElement.cs | 31 - .../CurrentProjectValidationElement.cs.meta | 11 - .../ExternalProjectValidationElement.cs | 92 --- .../ExternalProjectValidationElement.cs.meta | 11 - .../Elements/HybridPackageWorkflowElement.cs | 116 --- .../HybridPackageWorkflowElement.cs.meta | 11 - .../Scripts/UI/Elements/LoadingSpinner.cs | 52 -- .../UI/Elements/LoadingSpinner.cs.meta | 11 - .../Elements/MultiToggleSelectionElement.cs | 187 ----- .../MultiToggleSelectionElement.cs.meta | 11 - .../UI/Elements/PackageContentElement.cs | 137 ---- .../UI/Elements/PackageContentElement.cs.meta | 11 - .../Scripts/UI/Elements/PackageElement.cs | 215 ------ .../UI/Elements/PackageElement.cs.meta | 11 - .../UI/Elements/PackageGroupElement.cs | 149 ---- .../UI/Elements/PackageGroupElement.cs.meta | 11 - .../Scripts/UI/Elements/PackageListToolbar.cs | 58 -- .../UI/Elements/PackageListToolbar.cs.meta | 11 - .../UI/Elements/PackageUploadElement.cs | 321 --------- .../UI/Elements/PackageUploadElement.cs.meta | 11 - .../UI/Elements/PathSelectionElement.cs | 63 -- .../UI/Elements/PathSelectionElement.cs.meta | 11 - .../UI/Elements/PreviewGenerationElement.cs | 109 --- .../Elements/PreviewGenerationElement.cs.meta | 11 - .../Elements/UnityPackageWorkflowElement.cs | 58 -- .../UnityPackageWorkflowElement.cs.meta | 11 - .../Editor/Uploader/Scripts/UI/Views.meta | 8 - .../Uploader/Scripts/UI/Views/LoginView.cs | 284 -------- .../Scripts/UI/Views/LoginView.cs.meta | 11 - .../Scripts/UI/Views/PackageListView.cs | 249 ------- .../Scripts/UI/Views/PackageListView.cs.meta | 11 - .../Editor/Uploader/Styles.meta | 8 - .../Editor/Uploader/Styles/LoginView.meta | 8 - .../Uploader/Styles/LoginView/Style.uss | 134 ---- .../Uploader/Styles/LoginView/Style.uss.meta | 11 - .../Uploader/Styles/LoginView/ThemeDark.uss | 44 -- .../Styles/LoginView/ThemeDark.uss.meta | 11 - .../Uploader/Styles/LoginView/ThemeLight.uss | 44 -- .../Styles/LoginView/ThemeLight.uss.meta | 11 - .../Uploader/Styles/PackageListView.meta | 8 - .../Uploader/Styles/PackageListView/Style.uss | 485 ------------- .../Styles/PackageListView/Style.uss.meta | 11 - .../Styles/PackageListView/ThemeDark.uss | 238 ------- .../Styles/PackageListView/ThemeDark.uss.meta | 11 - .../Styles/PackageListView/ThemeLight.uss | 238 ------- .../PackageListView/ThemeLight.uss.meta | 11 - .../Editor/Uploader/Styles/Style.uss | 74 -- .../Editor/Uploader/Styles/Style.uss.meta | 11 - .../Editor/Uploader/Styles/ThemeDark.uss | 9 - .../Editor/Uploader/Styles/ThemeDark.uss.meta | 11 - .../Editor/Uploader/Styles/ThemeLight.uss | 9 - .../Uploader/Styles/ThemeLight.uss.meta | 11 - .../Editor/Uploader/UploaderWindow.cs | 232 ------ .../Editor/Uploader/UploaderWindow.cs.meta | 11 - .../Editor/Utility.meta | 8 - .../Editor/Utility/ASDebug.cs | 65 -- .../Editor/Utility/ASDebug.cs.meta | 11 - .../Editor/Utility/ASToolsPreferences.cs | 134 ---- .../Editor/Utility/ASToolsPreferences.cs.meta | 11 - .../Editor/Utility/ASToolsUpdater.cs | 250 ------- .../Editor/Utility/ASToolsUpdater.cs.meta | 11 - .../Editor/Utility/CacheUtil.cs | 266 ------- .../Editor/Utility/CacheUtil.cs.meta | 11 - .../Editor/Utility/FileUtility.cs | 207 ------ .../Editor/Utility/FileUtility.cs.meta | 11 - .../Editor/Utility/LegacyToolsRemover.cs | 86 --- .../Editor/Utility/LegacyToolsRemover.cs.meta | 11 - .../Editor/Utility/PackageUtility.cs | 170 ----- .../Editor/Utility/PackageUtility.cs.meta | 11 - .../Editor/Utility/ServiceProvider.cs | 113 --- .../Editor/Utility/ServiceProvider.cs.meta | 11 - .../Editor/Utility/StyleSelector.cs | 55 -- .../Editor/Utility/StyleSelector.cs.meta | 11 - .../Editor/Utility/Styles.meta | 8 - .../Editor/Utility/Styles/Updater.meta | 8 - .../Editor/Utility/Styles/Updater/Style.uss | 76 -- .../Utility/Styles/Updater/Style.uss.meta | 11 - .../Utility/Styles/Updater/ThemeDark.uss | 3 - .../Utility/Styles/Updater/ThemeDark.uss.meta | 11 - .../Utility/Styles/Updater/ThemeLight.uss | 3 - .../Styles/Updater/ThemeLight.uss.meta | 11 - .../Editor/Utility/SymlinkUtil.cs | 67 -- .../Editor/Utility/SymlinkUtil.cs.meta | 3 - .../Editor/Validator.meta | 8 - .../Editor/Validator/Icons.meta | 8 - .../Editor/Validator/Icons/error.png | Bin 1057 -> 0 bytes .../Editor/Validator/Icons/error.png.meta | 128 ---- .../Editor/Validator/Icons/error_d.png | Bin 1024 -> 0 bytes .../Editor/Validator/Icons/error_d.png.meta | 128 ---- .../Editor/Validator/Icons/success.png | Bin 1583 -> 0 bytes .../Editor/Validator/Icons/success.png.meta | 128 ---- .../Editor/Validator/Icons/success_d.png | Bin 1617 -> 0 bytes .../Editor/Validator/Icons/success_d.png.meta | 128 ---- .../Editor/Validator/Icons/undefined.png | Bin 1561 -> 0 bytes .../Editor/Validator/Icons/undefined.png.meta | 128 ---- .../Editor/Validator/Icons/undefined_d.png | Bin 1600 -> 0 bytes .../Validator/Icons/undefined_d.png.meta | 128 ---- .../Editor/Validator/Icons/warning.png | Bin 1141 -> 0 bytes .../Editor/Validator/Icons/warning.png.meta | 128 ---- .../Editor/Validator/Icons/warning_d.png | Bin 1185 -> 0 bytes .../Editor/Validator/Icons/warning_d.png.meta | 128 ---- .../Editor/Validator/Scripts.meta | 8 - .../Editor/Validator/Scripts/Categories.meta | 3 - .../Scripts/Categories/CategoryEvaluator.cs | 52 -- .../Categories/CategoryEvaluator.cs.meta | 3 - .../Scripts/Categories/ValidatorCategory.cs | 38 - .../Categories/ValidatorCategory.cs.meta | 3 - .../Scripts/CurrentProjectValidator.cs | 71 -- .../Scripts/CurrentProjectValidator.cs.meta | 11 - .../Editor/Validator/Scripts/Data.meta | 8 - .../Data/CurrentProjectValidationSettings.cs | 33 - .../CurrentProjectValidationSettings.cs.meta | 11 - .../Data/ExternalProjectValidationSettings.cs | 7 - .../ExternalProjectValidationSettings.cs.meta | 11 - .../Scripts/Data/MessageActions.meta | 8 - .../MessageActions/HighlightObjectAction.cs | 31 - .../HighlightObjectAction.cs.meta | 11 - .../Data/MessageActions/IMessageAction.cs | 16 - .../MessageActions/IMessageAction.cs.meta | 11 - .../Data/MessageActions/OpenAssetAction.cs | 38 - .../MessageActions/OpenAssetAction.cs.meta | 11 - .../Validator/Scripts/Data/TestResult.cs | 52 -- .../Validator/Scripts/Data/TestResult.cs.meta | 11 - .../Scripts/Data/TestResultMessage.cs | 53 -- .../Scripts/Data/TestResultMessage.cs.meta | 11 - .../Scripts/Data/TestResultObject.cs | 35 - .../Scripts/Data/TestResultObject.cs.meta | 11 - .../Scripts/Data/TestResultStatus.cs | 11 - .../Scripts/Data/TestResultStatus.cs.meta | 11 - .../Scripts/Data/ValidationResult.cs | 24 - .../Scripts/Data/ValidationResult.cs.meta | 11 - .../Scripts/Data/ValidationSettings.cs | 7 - .../Scripts/Data/ValidationSettings.cs.meta | 11 - .../Scripts/Data/ValidationStatus.cs | 10 - .../Scripts/Data/ValidationStatus.cs.meta | 11 - .../Validator/Scripts/Data/ValidationType.cs | 8 - .../Scripts/Data/ValidationType.cs.meta | 11 - .../Scripts/ExternalProjectValidator.cs | 259 ------- .../Scripts/ExternalProjectValidator.cs.meta | 11 - .../Editor/Validator/Scripts/IValidator.cs | 11 - .../Validator/Scripts/IValidator.cs.meta | 11 - .../Editor/Validator/Scripts/Services.meta | 8 - .../Scripts/Services/CachingService.meta | 8 - .../Services/CachingService/CachingService.cs | 55 -- .../CachingService/CachingService.cs.meta | 11 - .../CachingService/ICachingService.cs | 11 - .../CachingService/ICachingService.cs.meta | 11 - .../PreviewDatabaseContractResolver.cs | 26 - .../PreviewDatabaseContractResolver.cs.meta | 11 - .../Scripts/Services/IValidatorService.cs | 4 - .../Services/IValidatorService.cs.meta | 11 - .../Scripts/Services/Validation.meta | 8 - .../Services/Validation/Abstractions.meta | 8 - .../Abstractions/IAssetUtilityService.cs | 18 - .../Abstractions/IAssetUtilityService.cs.meta | 11 - .../IFileSignatureUtilityService.cs | 7 - .../IFileSignatureUtilityService.cs.meta | 11 - .../Abstractions/IMeshUtilityService.cs | 10 - .../Abstractions/IMeshUtilityService.cs.meta | 11 - .../Abstractions/IModelUtilityService.cs | 10 - .../Abstractions/IModelUtilityService.cs.meta | 11 - .../Abstractions/ISceneUtilityService.cs | 13 - .../Abstractions/ISceneUtilityService.cs.meta | 11 - .../Abstractions/IScriptUtilityService.cs | 14 - .../IScriptUtilityService.cs.meta | 11 - .../Validation/AssetUtilityService.cs | 216 ------ .../Validation/AssetUtilityService.cs.meta | 11 - .../Scripts/Services/Validation/Data.meta | 8 - .../Services/Validation/Data/ArchiveType.cs | 19 - .../Validation/Data/ArchiveType.cs.meta | 11 - .../Validation/Data/AssetEnumerator.cs | 84 --- .../Validation/Data/AssetEnumerator.cs.meta | 11 - .../Services/Validation/Data/AssetType.cs | 25 - .../Validation/Data/AssetType.cs.meta | 11 - .../Services/Validation/Data/LogEntry.cs | 10 - .../Services/Validation/Data/LogEntry.cs.meta | 11 - .../Validation/FileSignatureUtilityService.cs | 78 --- .../FileSignatureUtilityService.cs.meta | 11 - .../Services/Validation/MeshUtilityService.cs | 26 - .../Validation/MeshUtilityService.cs.meta | 11 - .../Validation/ModelUtilityService.cs | 147 ---- .../Validation/ModelUtilityService.cs.meta | 11 - .../Validation/SceneUtilityService.cs | 26 - .../Validation/SceneUtilityService.cs.meta | 11 - .../Validation/ScriptUtilityService.cs | 658 ------------------ .../Validation/ScriptUtilityService.cs.meta | 11 - .../Services/ValidatorServiceProvider.cs | 24 - .../Services/ValidatorServiceProvider.cs.meta | 11 - .../Validator/Scripts/Test Definitions.meta | 8 - .../Scripts/Test Definitions/AutomatedTest.cs | 121 ---- .../Test Definitions/AutomatedTest.cs.meta | 11 - .../Test Definitions/GenericTestConfig.cs | 7 - .../GenericTestConfig.cs.meta | 11 - .../Scripts/Test Definitions/ITestConfig.cs | 4 - .../Test Definitions/ITestConfig.cs.meta | 11 - .../Scripts/Test Definitions/ITestScript.cs | 9 - .../Test Definitions/ITestScript.cs.meta | 11 - .../Test Definitions/Scriptable Objects.meta | 8 - .../AutomatedTestScriptableObject.cs | 11 - .../AutomatedTestScriptableObject.cs.meta | 11 - .../Scriptable Objects/Editor.meta | 8 - ...ValidationTestScriptableObjectInspector.cs | 196 ------ ...ationTestScriptableObjectInspector.cs.meta | 11 - .../ValidationTestScriptableObject.cs | 35 - .../ValidationTestScriptableObject.cs.meta | 11 - .../Test Definitions/ValidationTest.cs | 38 - .../Test Definitions/ValidationTest.cs.meta | 11 - .../Validator/Scripts/Test Methods.meta | 8 - .../Scripts/Test Methods/Generic.meta | 8 - .../Generic/CheckAnimationClips.cs | 64 -- .../Generic/CheckAnimationClips.cs.meta | 11 - .../Generic/CheckAudioClipping.cs | 128 ---- .../Generic/CheckAudioClipping.cs.meta | 11 - .../Test Methods/Generic/CheckColliders.cs | 55 -- .../Generic/CheckColliders.cs.meta | 11 - .../Generic/CheckCompressedFiles.cs | 121 ---- .../Generic/CheckCompressedFiles.cs.meta | 11 - .../Test Methods/Generic/CheckEmptyPrefabs.cs | 46 -- .../Generic/CheckEmptyPrefabs.cs.meta | 11 - .../Generic/CheckFileMenuNames.cs | 153 ---- .../Generic/CheckFileMenuNames.cs.meta | 11 - .../Scripts/Test Methods/Generic/CheckLODs.cs | 79 --- .../Test Methods/Generic/CheckLODs.cs.meta | 11 - .../Test Methods/Generic/CheckLineEndings.cs | 77 -- .../Generic/CheckLineEndings.cs.meta | 11 - .../Test Methods/Generic/CheckMeshPrefabs.cs | 106 --- .../Generic/CheckMeshPrefabs.cs.meta | 11 - .../Generic/CheckMissingComponentsinAssets.cs | 66 -- .../CheckMissingComponentsinAssets.cs.meta | 11 - .../Generic/CheckMissingComponentsinScenes.cs | 93 --- .../CheckMissingComponentsinScenes.cs.meta | 11 - .../Generic/CheckModelImportLogs.cs | 64 -- .../Generic/CheckModelImportLogs.cs.meta | 11 - .../Generic/CheckModelOrientation.cs | 71 -- .../Generic/CheckModelOrientation.cs.meta | 11 - .../Test Methods/Generic/CheckModelTypes.cs | 58 -- .../Generic/CheckModelTypes.cs.meta | 11 - .../Generic/CheckNormalMapTextures.cs | 94 --- .../Generic/CheckNormalMapTextures.cs.meta | 11 - .../Generic/CheckPackageNaming.cs | 295 -------- .../Generic/CheckPackageNaming.cs.meta | 11 - .../Generic/CheckParticleSystems.cs | 76 -- .../Generic/CheckParticleSystems.cs.meta | 11 - .../Test Methods/Generic/CheckPathLengths.cs | 98 --- .../Generic/CheckPathLengths.cs.meta | 11 - .../Generic/CheckPrefabTransforms.cs | 71 -- .../Generic/CheckPrefabTransforms.cs.meta | 11 - .../Generic/CheckScriptCompilation.cs | 30 - .../Generic/CheckScriptCompilation.cs.meta | 11 - .../Generic/CheckShaderCompilation.cs | 63 -- .../Generic/CheckShaderCompilation.cs.meta | 11 - .../Generic/CheckTextureDimensions.cs | 57 -- .../Generic/CheckTextureDimensions.cs.meta | 11 - .../Generic/CheckTypeNamespaces.cs | 233 ------- .../Generic/CheckTypeNamespaces.cs.meta | 11 - .../Generic/RemoveExecutableFiles.cs | 38 - .../Generic/RemoveExecutableFiles.cs.meta | 11 - .../Test Methods/Generic/RemoveJPGFiles.cs | 38 - .../Generic/RemoveJPGFiles.cs.meta | 11 - .../Generic/RemoveJavaScriptFiles.cs | 38 - .../Generic/RemoveJavaScriptFiles.cs.meta | 11 - .../Generic/RemoveLossyAudioFiles.cs | 83 --- .../Generic/RemoveLossyAudioFiles.cs.meta | 11 - .../Test Methods/Generic/RemoveMixamoFiles.cs | 38 - .../Generic/RemoveMixamoFiles.cs.meta | 11 - .../Generic/RemoveSpeedTreeFiles.cs | 38 - .../Generic/RemoveSpeedTreeFiles.cs.meta | 11 - .../Test Methods/Generic/RemoveVideoFiles.cs | 38 - .../Generic/RemoveVideoFiles.cs.meta | 11 - .../Scripts/Test Methods/UnityPackage.meta | 8 - .../UnityPackage/CheckDemoScenes.cs | 172 ----- .../UnityPackage/CheckDemoScenes.cs.meta | 11 - .../UnityPackage/CheckDocumentation.cs | 73 -- .../UnityPackage/CheckDocumentation.cs.meta | 11 - .../UnityPackage/CheckPackageSize.cs | 69 -- .../UnityPackage/CheckPackageSize.cs.meta | 11 - .../CheckProjectTemplateAssets.cs | 217 ------ .../CheckProjectTemplateAssets.cs.meta | 11 - .../Editor/Validator/Scripts/UI.meta | 8 - .../Editor/Validator/Scripts/UI/Data.meta | 8 - .../Scripts/UI/Data/Abstractions.meta | 8 - .../UI/Data/Abstractions/IValidatorResults.cs | 15 - .../Abstractions/IValidatorResults.cs.meta | 11 - .../Data/Abstractions/IValidatorSettings.cs | 31 - .../Abstractions/IValidatorSettings.cs.meta | 11 - .../UI/Data/Abstractions/IValidatorTest.cs | 15 - .../Data/Abstractions/IValidatorTest.cs.meta | 11 - .../Data/Abstractions/IValidatorTestGroup.cs | 12 - .../Abstractions/IValidatorTestGroup.cs.meta | 11 - .../Scripts/UI/Data/Serialization.meta | 8 - .../Data/Serialization/ValidatorStateData.cs | 28 - .../Serialization/ValidatorStateData.cs.meta | 11 - .../ValidatorStateDataContractResolver.cs | 26 - ...ValidatorStateDataContractResolver.cs.meta | 11 - .../Serialization/ValidatorStateResults.cs | 83 --- .../ValidatorStateResults.cs.meta | 11 - .../Serialization/ValidatorStateSettings.cs | 63 -- .../ValidatorStateSettings.cs.meta | 11 - .../Scripts/UI/Data/ValidatorResults.cs | 137 ---- .../Scripts/UI/Data/ValidatorResults.cs.meta | 11 - .../Scripts/UI/Data/ValidatorSettings.cs | 236 ------- .../Scripts/UI/Data/ValidatorSettings.cs.meta | 11 - .../Scripts/UI/Data/ValidatorTest.cs | 28 - .../Scripts/UI/Data/ValidatorTest.cs.meta | 11 - .../Scripts/UI/Data/ValidatorTestGroup.cs | 18 - .../UI/Data/ValidatorTestGroup.cs.meta | 11 - .../Editor/Validator/Scripts/UI/Elements.meta | 8 - .../UI/Elements/ValidatorButtonElement.cs | 50 -- .../Elements/ValidatorButtonElement.cs.meta | 11 - .../Elements/ValidatorDescriptionElement.cs | 114 --- .../ValidatorDescriptionElement.cs.meta | 3 - .../UI/Elements/ValidatorPathsElement.cs | 128 ---- .../UI/Elements/ValidatorPathsElement.cs.meta | 11 - .../UI/Elements/ValidatorResultsElement.cs | 47 -- .../Elements/ValidatorResultsElement.cs.meta | 11 - .../UI/Elements/ValidatorSettingsElement.cs | 96 --- .../Elements/ValidatorSettingsElement.cs.meta | 11 - .../UI/Elements/ValidatorTestElement.cs | 239 ------- .../UI/Elements/ValidatorTestElement.cs.meta | 11 - .../UI/Elements/ValidatorTestGroupElement.cs | 102 --- .../ValidatorTestGroupElement.cs.meta | 11 - .../Validator/Scripts/UI/ValidatorWindow.cs | 56 -- .../Scripts/UI/ValidatorWindow.cs.meta | 11 - .../Editor/Validator/Scripts/UI/Views.meta | 8 - .../Scripts/UI/Views/ValidatorTestsView.cs | 103 --- .../UI/Views/ValidatorTestsView.cs.meta | 11 - .../Editor/Validator/Scripts/Utility.meta | 8 - .../Scripts/Utility/ValidatorUtility.cs | 142 ---- .../Scripts/Utility/ValidatorUtility.cs.meta | 11 - .../Editor/Validator/Scripts/ValidatorBase.cs | 108 --- .../Validator/Scripts/ValidatorBase.cs.meta | 11 - .../Editor/Validator/Styles.meta | 8 - .../Editor/Validator/Styles/Style.uss | 337 --------- .../Editor/Validator/Styles/Style.uss.meta | 11 - .../Editor/Validator/Styles/ThemeDark.uss | 166 ----- .../Validator/Styles/ThemeDark.uss.meta | 11 - .../Editor/Validator/Styles/ThemeLight.uss | 166 ----- .../Validator/Styles/ThemeLight.uss.meta | 11 - .../Editor/Validator/Tests.meta | 8 - .../Editor/Validator/Tests/Generic.meta | 8 - .../Tests/Generic/Check Animation Clips.asset | 27 - .../Generic/Check Animation Clips.asset.meta | 8 - .../Tests/Generic/Check Audio Clipping.asset | 32 - .../Generic/Check Audio Clipping.asset.meta | 8 - .../Tests/Generic/Check Colliders.asset | 26 - .../Tests/Generic/Check Colliders.asset.meta | 8 - .../Generic/Check Compressed Files.asset | 31 - .../Generic/Check Compressed Files.asset.meta | 8 - .../Tests/Generic/Check Empty Prefabs.asset | 31 - .../Generic/Check Empty Prefabs.asset.meta | 8 - .../Tests/Generic/Check File Menu Names.asset | 26 - .../Generic/Check File Menu Names.asset.meta | 8 - .../Validator/Tests/Generic/Check LODs.asset | 33 - .../Tests/Generic/Check LODs.asset.meta | 8 - .../Tests/Generic/Check Line Endings.asset | 26 - .../Generic/Check Line Endings.asset.meta | 8 - .../Tests/Generic/Check Mesh Prefabs.asset | 26 - .../Generic/Check Mesh Prefabs.asset.meta | 8 - .../Check Missing Components in Assets.asset | 25 - ...ck Missing Components in Assets.asset.meta | 8 - .../Check Missing Components in Scenes.asset | 25 - ...ck Missing Components in Scenes.asset.meta | 8 - .../Generic/Check Model Import Logs.asset | 26 - .../Check Model Import Logs.asset.meta | 8 - .../Generic/Check Model Orientation.asset | 25 - .../Check Model Orientation.asset.meta | 8 - .../Tests/Generic/Check Model Types.asset | 24 - .../Generic/Check Model Types.asset.meta | 8 - .../Generic/Check Normal Map Textures.asset | 25 - .../Check Normal Map Textures.asset.meta | 8 - .../Tests/Generic/Check Package Naming.asset | 30 - .../Generic/Check Package Naming.asset.meta | 8 - .../Generic/Check Particle Systems.asset | 25 - .../Generic/Check Particle Systems.asset.meta | 8 - .../Tests/Generic/Check Path Lengths.asset | 25 - .../Generic/Check Path Lengths.asset.meta | 8 - .../Generic/Check Prefab Transforms.asset | 28 - .../Check Prefab Transforms.asset.meta | 8 - .../Generic/Check Script Compilation.asset | 25 - .../Check Script Compilation.asset.meta | 8 - .../Generic/Check Shader Compilation.asset | 25 - .../Check Shader Compilation.asset.meta | 8 - .../Generic/Check Texture Dimensions.asset | 25 - .../Check Texture Dimensions.asset.meta | 8 - .../Tests/Generic/Check Type Namespaces.asset | 31 - .../Generic/Check Type Namespaces.asset.meta | 8 - .../Generic/Remove Executable Files.asset | 27 - .../Remove Executable Files.asset.meta | 8 - .../Tests/Generic/Remove JPG Files.asset | 30 - .../Tests/Generic/Remove JPG Files.asset.meta | 8 - .../Generic/Remove JavaScript Files.asset | 25 - .../Remove JavaScript Files.asset.meta | 8 - .../Generic/Remove Lossy Audio Files.asset | 32 - .../Remove Lossy Audio Files.asset.meta | 8 - .../Tests/Generic/Remove Mixamo Files.asset | 26 - .../Generic/Remove Mixamo Files.asset.meta | 8 - .../Generic/Remove SpeedTree Files.asset | 25 - .../Generic/Remove SpeedTree Files.asset.meta | 8 - .../Tests/Generic/Remove Video Files.asset | 26 - .../Generic/Remove Video Files.asset.meta | 8 - .../Editor/Validator/Tests/UnityPackage.meta | 8 - .../UnityPackage/Check Demo Scenes.asset | 34 - .../UnityPackage/Check Demo Scenes.asset.meta | 8 - .../UnityPackage/Check Documentation.asset | 32 - .../Check Documentation.asset.meta | 8 - .../UnityPackage/Check Package Size.asset | 25 - .../Check Package Size.asset.meta | 8 - .../Check Project Template Assets.asset | 36 - .../Check Project Template Assets.asset.meta | 8 - .../com.unity.asset-store-tools/LICENSE.md | 5 - .../LICENSE.md.meta | 7 - .../com.unity.asset-store-tools/package.json | 11 - .../package.json.meta | 7 - Installer/Packages/manifest.json | 3 +- Installer/Packages/packages-lock.json | 7 +- .../ProjectSettings/MemorySettings.asset | 35 + .../PackageManagerSettings.asset | 39 +- Installer/ProjectSettings/ProjectVersion.txt | 4 +- .../VersionControlSettings.asset | 8 + Installer/ProjectSettings/boot.config | 0 .../UserSettings/EditorUserSettings.asset | 19 + Installer/UserSettings/Search.settings | 1 + 766 files changed, 156 insertions(+), 30220 deletions(-) create mode 100644 Installer/.vscode/extensions.json create mode 100644 Installer/.vscode/launch.json delete mode 100644 Installer/Packages/com.unity.asset-store-tools/CHANGELOG.md delete mode 100644 Installer/Packages/com.unity.asset-store-tools/CHANGELOG.md.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/AuthenticationBase.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/AuthenticationBase.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreApi.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreApi.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreClient.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreClient.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAuthenticationType.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAuthenticationType.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IPackageUploader.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IPackageUploader.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/PackageUploaderBase.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/PackageUploaderBase.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/ApiUtility.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/ApiUtility.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreApi.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreApi.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreClient.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreClient.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/CloudTokenAuthentication.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/CloudTokenAuthentication.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/CredentialsAuthentication.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/CredentialsAuthentication.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Category.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Category.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Package.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Package.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/PackageAdditionalData.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/PackageAdditionalData.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/User.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/User.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreResponse.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreResponse.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreToolsVersionResponse.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreToolsVersionResponse.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AuthenticationResponse.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AuthenticationResponse.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/CategoryDataResponse.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/CategoryDataResponse.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageThumbnailResponse.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageThumbnailResponse.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageUploadedUnityVersionDataResponse.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageUploadedUnityVersionDataResponse.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesAdditionalDataResponse.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesAdditionalDataResponse.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesDataResponse.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesDataResponse.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/RefreshedPackageDataResponse.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/RefreshedPackageDataResponse.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/UploadResponse.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/UploadResponse.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/SessionAuthentication.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/SessionAuthentication.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/UnityPackageUploader.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/UnityPackageUploader.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/UploadStatus.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Api/UploadStatus.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/AssemblyInfo.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/AssemblyInfo.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreTools.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreTools.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreToolsWindow.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreToolsWindow.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Constants.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Constants.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPackageExporter.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPackageExporter.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPreviewInjector.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPreviewInjector.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterBase.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterBase.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultExporterSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultExporterSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultPackageExporter.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultPackageExporter.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyExporterSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyExporterSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyPackageExporter.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyPackageExporter.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PackageExporterResult.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PackageExporterResult.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PreviewInjector.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PreviewInjector.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/CustomPreviewGenerationSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/CustomPreviewGenerationSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/FileNameFormat.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/FileNameFormat.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/GenerationType.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/GenerationType.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/NativePreviewGenerationSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/NativePreviewGenerationSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewDatabase.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewDatabase.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewFormat.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewFormat.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationResult.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationResult.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewMetadata.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewMetadata.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannel.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannel.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannelCoordinate.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannelCoordinate.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/ISceneScreenshotter.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/ISceneScreenshotter.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MaterialScreenshotter.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MaterialScreenshotter.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MeshScreenshotter.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MeshScreenshotter.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterBase.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterBase.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypeGeneratorSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypeGeneratorSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypePreviewGenerator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypePreviewGenerator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ITypePreviewGenerator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ITypePreviewGenerator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/MaterialTypePreviewGenerator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/MaterialTypePreviewGenerator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ModelTypePreviewGenerator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ModelTypePreviewGenerator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/PrefabTypePreviewGenerator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/PrefabTypePreviewGenerator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypeGeneratorSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypeGeneratorSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypePreviewGenerator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypePreviewGenerator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypeGeneratorSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypeGeneratorSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorBase.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorBase.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromScene.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromScene.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromSceneSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromSceneSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/CustomPreviewGenerator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/CustomPreviewGenerator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/IPreviewGenerator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/IPreviewGenerator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/NativePreviewGenerator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/NativePreviewGenerator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/PreviewGeneratorBase.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/PreviewGeneratorBase.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/CachingService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/CachingService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/ICachingService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/ICachingService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/IPreviewService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/IPreviewService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/PreviewServiceProvider.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/PreviewServiceProvider.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreview.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreview.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreviewCollection.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreviewCollection.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreview.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreview.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreviewCollection.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreviewCollection.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IPreviewGeneratorSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IPreviewGeneratorSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/PreviewGeneratorSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/PreviewGeneratorSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/AssetPreviewElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/AssetPreviewElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/GridListElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/GridListElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewCollectionElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewCollectionElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGenerateButtonElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGenerateButtonElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorPathsElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorPathsElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorSettingsElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorSettingsElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewWindowDescriptionElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewWindowDescriptionElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/PreviewGeneratorWindow.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/PreviewGeneratorWindow.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Views.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Views/PreviewListView.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Views/PreviewListView.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/GraphicsUtility.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/GraphicsUtility.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewConvertUtility.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewConvertUtility.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewSceneUtility.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewSceneUtility.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipeline.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipeline.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipelineUtility.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipelineUtility.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/Style.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/Style.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeDark.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeDark.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeLight.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeLight.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Unity.AssetStoreTools.Editor.asmdef delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Unity.AssetStoreTools.Editor.asmdef.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/account-dark.png delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/account-dark.png.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/account-light.png delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/account-light.png.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/open-in-browser.png delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/open-in-browser.png.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/publisher-portal-dark.png delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/publisher-portal-dark.png.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/publisher-portal-light.png delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/publisher-portal-light.png.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackage.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackage.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageContent.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageContent.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageGroup.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageGroup.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflow.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflow.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflowServices.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflowServices.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/WorkflowBase.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/WorkflowBase.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/AssetsWorkflow.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/AssetsWorkflow.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/HybridPackageWorkflow.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/HybridPackageWorkflow.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Package.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Package.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageContent.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageContent.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageGroup.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageGroup.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageSorting.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageSorting.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetPath.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetPath.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetsWorkflowStateData.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetsWorkflowStateData.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/HybridPackageWorkflowState.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/HybridPackageWorkflowState.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/UnityPackageWorkflowStateData.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/UnityPackageWorkflowStateData.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/WorkflowStateData.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/WorkflowStateData.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/UnityPackageWorkflow.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/UnityPackageWorkflow.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/WorkflowServices.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/WorkflowServices.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/AnalyticsService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/AnalyticsService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/AuthenticationAnalytic.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/AuthenticationAnalytic.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/BaseAnalytic.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/BaseAnalytic.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalytic.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalytic.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalyticData.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalyticData.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/PackageUploadAnalytic.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/PackageUploadAnalytic.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/ValidationResultsSerializer.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/ValidationResultsSerializer.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/IAnalyticsService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/IAnalyticsService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/AuthenticationService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/AuthenticationService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IAuthenticationService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IAuthenticationService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageDownloadingService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageDownloadingService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageUploadingService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageUploadingService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageDownloadingService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageDownloadingService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageUploadingService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageUploadingService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/CachingService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/CachingService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/ICachingService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/ICachingService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/IUploaderService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/IUploaderService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/IPackageFactoryService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/IPackageFactoryService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/PackageFactoryService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/PackageFactoryService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/UploaderServiceProvider.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/UploaderServiceProvider.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/ValidationElementBase.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/ValidationElementBase.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/WorkflowElementBase.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/WorkflowElementBase.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AccountToolbar.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AccountToolbar.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AssetsWorkflowElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AssetsWorkflowElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/CurrentProjectValidationElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/CurrentProjectValidationElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/ExternalProjectValidationElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/ExternalProjectValidationElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/HybridPackageWorkflowElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/HybridPackageWorkflowElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/LoadingSpinner.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/LoadingSpinner.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/MultiToggleSelectionElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/MultiToggleSelectionElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageContentElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageContentElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageGroupElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageGroupElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageListToolbar.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageListToolbar.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageUploadElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageUploadElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PathSelectionElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PathSelectionElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PreviewGenerationElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PreviewGenerationElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/UnityPackageWorkflowElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/UnityPackageWorkflowElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/LoginView.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/LoginView.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/PackageListView.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/PackageListView.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/Style.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/Style.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeDark.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeDark.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeLight.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeLight.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/Style.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/Style.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeDark.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeDark.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeLight.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeLight.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/Style.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/Style.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeDark.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeDark.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeLight.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeLight.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/UploaderWindow.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/UploaderWindow.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASDebug.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASDebug.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsPreferences.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsPreferences.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsUpdater.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsUpdater.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/CacheUtil.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/CacheUtil.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/FileUtility.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/FileUtility.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/LegacyToolsRemover.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/LegacyToolsRemover.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/PackageUtility.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/PackageUtility.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ServiceProvider.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ServiceProvider.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/StyleSelector.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/StyleSelector.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/Style.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/Style.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeDark.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeDark.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeLight.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeLight.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/SymlinkUtil.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Utility/SymlinkUtil.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/error.png delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/error.png.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/error_d.png delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/error_d.png.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/success.png delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/success.png.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/success_d.png delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/success_d.png.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/undefined.png delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/undefined.png.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/undefined_d.png delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/undefined_d.png.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/warning.png delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/warning.png.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/warning_d.png delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/warning_d.png.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Categories.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Categories/CategoryEvaluator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Categories/CategoryEvaluator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Categories/ValidatorCategory.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Categories/ValidatorCategory.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/CurrentProjectValidator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/CurrentProjectValidator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/CurrentProjectValidationSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/CurrentProjectValidationSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ExternalProjectValidationSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ExternalProjectValidationSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/HighlightObjectAction.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/HighlightObjectAction.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/IMessageAction.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/IMessageAction.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/OpenAssetAction.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/OpenAssetAction.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResult.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResult.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultMessage.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultMessage.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultObject.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultObject.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultStatus.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultStatus.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationResult.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationResult.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationStatus.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationStatus.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationType.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationType.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ExternalProjectValidator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ExternalProjectValidator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/IValidator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/IValidator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/CachingService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/CachingService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/ICachingService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/ICachingService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/PreviewDatabaseContractResolver.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/PreviewDatabaseContractResolver.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/IValidatorService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/IValidatorService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IAssetUtilityService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IAssetUtilityService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IFileSignatureUtilityService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IFileSignatureUtilityService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IMeshUtilityService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IMeshUtilityService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IModelUtilityService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IModelUtilityService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/ISceneUtilityService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/ISceneUtilityService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IScriptUtilityService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IScriptUtilityService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/AssetUtilityService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/AssetUtilityService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/ArchiveType.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/ArchiveType.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetEnumerator.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetEnumerator.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetType.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetType.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/LogEntry.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/LogEntry.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/FileSignatureUtilityService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/FileSignatureUtilityService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/MeshUtilityService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/MeshUtilityService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ModelUtilityService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ModelUtilityService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/SceneUtilityService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/SceneUtilityService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ScriptUtilityService.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ScriptUtilityService.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/ValidatorServiceProvider.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/ValidatorServiceProvider.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/AutomatedTest.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/AutomatedTest.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/GenericTestConfig.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/GenericTestConfig.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestConfig.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestConfig.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestScript.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestScript.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/AutomatedTestScriptableObject.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/AutomatedTestScriptableObject.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/Editor.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/Editor/ValidationTestScriptableObjectInspector.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/Editor/ValidationTestScriptableObjectInspector.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/ValidationTestScriptableObject.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/ValidationTestScriptableObject.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ValidationTest.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ValidationTest.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAnimationClips.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAnimationClips.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAudioClipping.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAudioClipping.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckColliders.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckColliders.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckCompressedFiles.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckCompressedFiles.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckEmptyPrefabs.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckEmptyPrefabs.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckFileMenuNames.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckFileMenuNames.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLODs.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLODs.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLineEndings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLineEndings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMeshPrefabs.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMeshPrefabs.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinAssets.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinAssets.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinScenes.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinScenes.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelImportLogs.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelImportLogs.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelOrientation.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelOrientation.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelTypes.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelTypes.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckNormalMapTextures.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckNormalMapTextures.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPackageNaming.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPackageNaming.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckParticleSystems.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckParticleSystems.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPathLengths.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPathLengths.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPrefabTransforms.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPrefabTransforms.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckScriptCompilation.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckScriptCompilation.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckShaderCompilation.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckShaderCompilation.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTextureDimensions.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTextureDimensions.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTypeNamespaces.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTypeNamespaces.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveExecutableFiles.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveExecutableFiles.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJPGFiles.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJPGFiles.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJavaScriptFiles.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJavaScriptFiles.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveLossyAudioFiles.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveLossyAudioFiles.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveMixamoFiles.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveMixamoFiles.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveSpeedTreeFiles.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveSpeedTreeFiles.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveVideoFiles.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveVideoFiles.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDemoScenes.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDemoScenes.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDocumentation.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDocumentation.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckPackageSize.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckPackageSize.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckProjectTemplateAssets.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckProjectTemplateAssets.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorResults.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorResults.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTest.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTest.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTestGroup.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTestGroup.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateData.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateData.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateDataContractResolver.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateDataContractResolver.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateResults.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateResults.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorResults.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorResults.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorSettings.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorSettings.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTest.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTest.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTestGroup.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTestGroup.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorButtonElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorButtonElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorDescriptionElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorDescriptionElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorPathsElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorPathsElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorResultsElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorResultsElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorSettingsElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorSettingsElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestGroupElement.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestGroupElement.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/ValidatorWindow.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/ValidatorWindow.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Views.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Views/ValidatorTestsView.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Views/ValidatorTestsView.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Utility.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Utility/ValidatorUtility.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Utility/ValidatorUtility.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ValidatorBase.cs delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ValidatorBase.cs.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/Style.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/Style.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeDark.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeDark.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeLight.uss delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeLight.uss.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Animation Clips.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Animation Clips.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Audio Clipping.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Audio Clipping.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Colliders.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Colliders.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Compressed Files.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Compressed Files.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Empty Prefabs.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Empty Prefabs.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check File Menu Names.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check File Menu Names.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check LODs.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check LODs.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Line Endings.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Line Endings.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Mesh Prefabs.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Mesh Prefabs.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Assets.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Assets.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Scenes.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Scenes.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Import Logs.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Import Logs.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Orientation.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Orientation.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Types.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Types.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Normal Map Textures.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Normal Map Textures.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Package Naming.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Package Naming.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Particle Systems.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Particle Systems.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Path Lengths.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Path Lengths.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Prefab Transforms.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Prefab Transforms.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Script Compilation.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Script Compilation.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Shader Compilation.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Shader Compilation.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Texture Dimensions.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Texture Dimensions.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Type Namespaces.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Type Namespaces.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Executable Files.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Executable Files.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JPG Files.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JPG Files.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JavaScript Files.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JavaScript Files.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Lossy Audio Files.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Lossy Audio Files.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Mixamo Files.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Mixamo Files.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove SpeedTree Files.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove SpeedTree Files.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Video Files.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Video Files.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Demo Scenes.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Demo Scenes.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Documentation.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Documentation.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Package Size.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Package Size.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Project Template Assets.asset delete mode 100644 Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Project Template Assets.asset.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/LICENSE.md delete mode 100644 Installer/Packages/com.unity.asset-store-tools/LICENSE.md.meta delete mode 100644 Installer/Packages/com.unity.asset-store-tools/package.json delete mode 100644 Installer/Packages/com.unity.asset-store-tools/package.json.meta create mode 100644 Installer/ProjectSettings/MemorySettings.asset create mode 100644 Installer/ProjectSettings/VersionControlSettings.asset create mode 100644 Installer/ProjectSettings/boot.config create mode 100644 Installer/UserSettings/EditorUserSettings.asset create mode 100644 Installer/UserSettings/Search.settings diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 711d691..3dc6696 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -23,7 +23,7 @@ jobs: echo "InstallerProjectPath=./Installer" >> $GITHUB_OUTPUT echo "InstallerFileName=ImageLoader-Installer" >> $GITHUB_OUTPUT echo "InstallerExportMethod=com.IvanMurzak.Unity.ImageLoader.Installer.PackageExporter.ExportPackage" >> $GITHUB_OUTPUT - echo "InstallerUnityVersion=2019.4.40f1" >> $GITHUB_OUTPUT + echo "InstallerUnityVersion=2021.3.45f1" >> $GITHUB_OUTPUT check-version-tag: needs: setup diff --git a/.github/workflows/test_pull_request.yml b/.github/workflows/test_pull_request.yml index 7e45d4c..93c5210 100644 --- a/.github/workflows/test_pull_request.yml +++ b/.github/workflows/test_pull_request.yml @@ -23,7 +23,7 @@ jobs: echo "InstallerProjectPath=./Installer" >> $GITHUB_OUTPUT echo "InstallerFileName=Unity-ImageLoader-Installer" >> $GITHUB_OUTPUT echo "InstallerExportMethod=com.IvanMurzak.Unity.ImageLoader.Installer.PackageExporter.ExportPackage" >> $GITHUB_OUTPUT - echo "InstallerUnityVersion=2019.4.40f1" >> $GITHUB_OUTPUT + echo "InstallerUnityVersion=2021.3.45f1" >> $GITHUB_OUTPUT # --- EDIT MODE --- diff --git a/Installer/.vscode/extensions.json b/Installer/.vscode/extensions.json new file mode 100644 index 0000000..ddb6ff8 --- /dev/null +++ b/Installer/.vscode/extensions.json @@ -0,0 +1,5 @@ +{ + "recommendations": [ + "visualstudiotoolsforunity.vstuc" + ] +} diff --git a/Installer/.vscode/launch.json b/Installer/.vscode/launch.json new file mode 100644 index 0000000..da60e25 --- /dev/null +++ b/Installer/.vscode/launch.json @@ -0,0 +1,10 @@ +{ + "version": "0.2.0", + "configurations": [ + { + "name": "Attach to Unity", + "type": "vstuc", + "request": "attach" + } + ] +} \ No newline at end of file diff --git a/Installer/.vscode/settings.json b/Installer/.vscode/settings.json index e232cd6..cb81b36 100644 --- a/Installer/.vscode/settings.json +++ b/Installer/.vscode/settings.json @@ -1,55 +1,55 @@ -{ - "files.exclude": - { - "**/.DS_Store":true, - "**/.git":true, - "**/.gitmodules":true, - "**/*.booproj":true, - "**/*.pidb":true, - "**/*.suo":true, - "**/*.user":true, - "**/*.userprefs":true, - "**/*.unityproj":true, - "**/*.dll":true, - "**/*.exe":true, - "**/*.pdf":true, - "**/*.mid":true, - "**/*.midi":true, - "**/*.wav":true, - "**/*.gif":true, - "**/*.ico":true, - "**/*.jpg":true, - "**/*.jpeg":true, - "**/*.png":true, - "**/*.psd":true, - "**/*.tga":true, - "**/*.tif":true, - "**/*.tiff":true, - "**/*.3ds":true, - "**/*.3DS":true, - "**/*.fbx":true, - "**/*.FBX":true, - "**/*.lxo":true, - "**/*.LXO":true, - "**/*.ma":true, - "**/*.MA":true, - "**/*.obj":true, - "**/*.OBJ":true, - "**/*.asset":true, - "**/*.cubemap":true, - "**/*.flare":true, - "**/*.mat":true, - "**/*.meta":true, - "**/*.prefab":true, - "**/*.unity":true, - "build/":true, - "Build/":true, - "Library/":true, - "library/":true, - "obj/":true, - "Obj/":true, - "ProjectSettings/":true, - "temp/":true, - "Temp/":true - } +{ + "files.exclude": { + "**/.DS_Store": true, + "**/.git": true, + "**/.gitmodules": true, + "**/*.booproj": true, + "**/*.pidb": true, + "**/*.suo": true, + "**/*.user": true, + "**/*.userprefs": true, + "**/*.unityproj": true, + "**/*.dll": true, + "**/*.exe": true, + "**/*.pdf": true, + "**/*.mid": true, + "**/*.midi": true, + "**/*.wav": true, + "**/*.gif": true, + "**/*.ico": true, + "**/*.jpg": true, + "**/*.jpeg": true, + "**/*.png": true, + "**/*.psd": true, + "**/*.tga": true, + "**/*.tif": true, + "**/*.tiff": true, + "**/*.3ds": true, + "**/*.3DS": true, + "**/*.fbx": true, + "**/*.FBX": true, + "**/*.lxo": true, + "**/*.LXO": true, + "**/*.ma": true, + "**/*.MA": true, + "**/*.obj": true, + "**/*.OBJ": true, + "**/*.asset": true, + "**/*.cubemap": true, + "**/*.flare": true, + "**/*.mat": true, + "**/*.meta": true, + "**/*.prefab": true, + "**/*.unity": true, + "build/": true, + "Build/": true, + "Library/": true, + "library/": true, + "obj/": true, + "Obj/": true, + "ProjectSettings/": true, + "temp/": true, + "Temp/": true + }, + "dotnet.defaultSolution": "Installer.sln" } \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/CHANGELOG.md b/Installer/Packages/com.unity.asset-store-tools/CHANGELOG.md deleted file mode 100644 index d51cbe8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/CHANGELOG.md +++ /dev/null @@ -1,324 +0,0 @@ -# Changelog -All notable changes to this package will be documented in this file. - -## [12.0.1] - 2025-01-16 - -### Preview Generator changes -- Updated generated preview collection UI to display the asset extension -- Fixed an issue with some prefab and model asset types not generating previews -- Fixed an error that could occur when changing scenes after deleting a preview source asset - -## [12.0.0] - 2025-01-13 - -### General changes -- The code comprising the Asset Store Publishing Tools has been refactored. -- Added dependency on Newtonsoft Json - -### Uploader changes -- Updated window to retain its state if closed unless a domain reload occurs -- Added option to generate higher resolution asset previews when exporting -- Fixed a rare issue where authentication would fail -- Minor UI tweaks - -### Validator changes -- Added validation tests for: - - Package naming - - Project Template assets -- Updated the Type Namespace validation test to check for Unity top level namespaces - -### Exporter changes -- Updated how asset previews are generated/included for the package that is being exported - -### Preview Generator -- Added a Preview Generator window that can be used to pre-generate and inspect package previews before exporting - -## [11.4.4] - 2024-11-29 - -### Validator Changes -- The validator UI window description section can now be expanded or shrunk to take up less screen space -- Updated severity of the Model Importer Logs validation test - -### Exporter Changes -- Updated exporter to always exclude hidden files and folders beginning with the dot symbol (e.g.: .hiddenFolder/ or .hiddenfile.txt) -- Updated exporter to explicitly exclude extended attribute files when exporting packages on macOS systems - -### Other -- Moved the Asset Store Tools toolbar items into the Tools section -- Fixed several window-related compilation warnings when using Unity 6 versions of the Editor - -## [11.4.3] - 2024-08-01 - -### Validator Changes -- Hotfix: Remove non-ascii characters from the demo scene validation - -## [11.4.2] - 2024-07-30 - -### Validator Changes -- Check for nested .unitypackage files in the demo scene validation -- Prevent normal map test from erroring when misc importer types are detected -- Remove Templates category from the uncompressed images requirement list - -## [11.4.1] - 2024-05-10 - -### Exporter Changes -- Fixed an issue with bundled plugin folder contents not being exported - -### Other -- Miscellaneous internal changes - -## [11.4.0] - 2024-01-23 - -### Uploader Changes -- Added prevention of uploading packages larger than 6 GB -- Added a prompt to allow automatically generating meta files within hidden folders -- Fixed some obsolete API usage warnings in newer Unity versions - -### Validator Changes -- Added validation tests for: - - Animation Clip take names - - Model import logs - - Uncompressed Package size -- Updated the fail severity of Audio Clipping validation test -- Updated the Demo Scene test to treat default scenes with custom skyboxes as valid demo scenes -- Fixed some obsolete API usage warnings in newer Unity versions - -### Other -- Added an option to check for Asset Store Publishing Tools updates - -## [11.3.1] - 2023-08-14 - -### Uploader Changes -- Added the option to select indirect package dependencies from the project (e.g. Mathematics package installed by the Burst package) - -### Validator Changes -- Updated the Texture Dimensions test to ignore 'Sprite' and 'Editor GUI' texture types - -### Exporter Changes -- Updated exporter to ignore the 'ProjectSettings/ProjectVersion.txt' asset when exporting 'Complete Project' category packages - -## [11.3.0] - 2023-07-04 - -### Uploader Changes - -- Added the option to validate a pre-exported package -- Added the option to export a .unitypackage file without uploading -- Updated the dependency selection UI - -### Validator Changes - -- Added the option to validate several asset paths at once - - Note: when validating package that is comprised of several folders (e.g. Assets/MyPackage + - Assets/StreamingAssets + Assets/WebGLTemplates), please select all applicable paths that would be included in the package -- Added several new validation tests for: - - File Menu Names - - Compressed files - - Model Types - - Texture Dimensions - - Particle Systems - - Normal Map Textures - - Audio Clipping - - Path Lengths - - Script Compilation -- Updated validation test severities based on package category -- Updated validation tests to each have their own test logic class -- Updated validation tests to be displayed in alphabetical order -- Fixed several issues with the namespace check test -- Fixed scenes in Samples~ folders not being taken into account for the sample scene check test -- Other internal changes - -### Exporter Changes - -- Package exporter is now a separate module (similar to Uploader and Validator) -- Fixed hidden folders being included when exporting package content - - Note: this prevents an issue with the Unity Editor, where exported hidden folders would appear in the Project window - as empty folders when imported, despite having content on disk. Content nested within hidden folders is still collected, - provided it contains unique .meta files - -## [11.2.2] - 2023-02-23 - -### Validator Changes - -- Updated the 'LOD Setup' test to address some issues - - Added additional checks for LOD renderers (inactive renderer check, LOD Group reference check, relative hierarchy position to LOD Group check) - - LOD Group Component is no longer required to be on the root of the Prefab - - Updated the test result message interface when invalid Prefabs are found - -## [11.2.1] - 2023-01-17 - -### Uploader Changes - -- Added a more informative error when exporting content with clashing guid meta files in hidden folders -- Fixed a compilation issue for Unity 2020.1 and 2020.2 -- Fixed a rare error condition when queueing multiple package uploads in quick succession -- Fixed Asset Store Uploader state not being properly reset if the uploading process fails - -### Validator Changes - -- Updated the Asset Store Validator description -- Fixed a rare memory overflow issue when performing package validation - -## [11.2.0] - 2022-11-03 - -### Uploader Changes - -- Uploader will now use the custom package exporter by default - - An option to use the legacy (native) exporter can be found in the Asset Store Publishing Tools' settings window -- When exporting from the Assets folder, package dependencies can now be selected individually instead of being a choice between 'All' or 'None' - - This option is only available with the custom exporter -- Changed the way the Uploader reports completed uploading tasks - - Modal pop-up has been replaced by a new UI view state - - Added an option to the Asset Store Publishing Tools' Settings to display the pop-up after a completed upload -- Changed exported .unitypackage files to have distinguishable file names -- Fixed the Uploader window indefinitely stalling at 100% upload progress when a response from the Asset Store server is not received -- Fixed native package exporter producing broken packages when the export path contained hidden folders -- Fixed an issue with high CPU usage when uploading packages -- Fixed Asset Store Publishing Tools' settings not being saved between Editor sessions on macOS -- Other minor changes and tweaks - -### Validator Changes - -- Added two new tests: - - 'Types have namespaces': checks whether scripts and native libraries under the validated path are nested under a namespace - - 'Consistent line endings': checks whether scripts under the validated path have consistent line endings. This is similar to the warning from the Unity Editor compilation pipeline when a script contains both Windows and UNIX line endings. -- Improved 'Reset Prefabs' test to display and be more informative about prefabs with unusually low transform values -- Improved 'SpeedTree asset inclusion' test to search for '.st' files -- Improved 'Documentation inclusion' test to treat '.md' files as valid documentation files -- Improved 'Lossy audio file inclusion' test to treat '.aif' and '.aiff' files as valid non-lossy audio files -- Improved 'Lossy audio file inclusion' test to search the project for non-lossy variants of existing lossy audio files -- Removed 'Duplicate animation names' test -- Tweaked validation severities for several tests -- Other minor changes and tweaks - -## [11.1.0] - 2022-09-14 - -### Uploader Changes - -- Package Publisher Portal links can now be opened for all packages regardless of package status -- External Dependency Manager can now be selected as a 'Special Folder' if found in the root Assets folder - -### Validator Changes - -- Added category selection for the Validator - - Categories help determine the outcome of package validation more accurately. For example, documentation is not crucial for art packages, but is required for tooling packages. -- Added a list of prefabs with missing mesh references to 'Meshes have Prefabs' test when the test fails -- Corrected the message for a passing 'Shader compilation errors' test -- Improved the floating point precision accuracy of 'Reset Prefabs' test -- Fixed 'Missing Components in Assets' test checking all project folders instead of only the set path -- Fixed 'Prefabs for meshes' test not checking meshes in certain paths -- Fixed 'Reset Prefabs' test failing because of Prefabs with a Rect Transform Component -- Fixed 'Reset Prefabs' test ignoring Transform rotation -- Fixed test description text overlapping in some cases -- Other minor changes and tweaks - -## [11.0.2] - 2022-08-09 - -- Corrected some namespaces which were causing issues when deriving classes from Editor class - -## [11.0.1] - 2022-08-05 - -### Uploader Changes - -- Added Settings window (Asset Store Tools > Settings) -- Added Soft/Junction Symlink support (enable through Settings) -- Added workflow and path selection serialization (workflow saved locally, paths locally and online) -- No more logs when using the `-nullable` compiler option (thanks @alfish) -- Some API refactoring in preparation for CLI support -- Other minor fixes/improvements - -**Note:** when updating Asset Store Tools from the Package Manager, don't forget to remove the old version from the project (V11.0.0) before importing the new one (V11.0.1) - - -## [11.0.0] - 2022-07-20 - -### Uploader changes - -- UI has been reworked using UI Toolkit -- New login window, allowing to login using Unity Cloud Services -- Improved top bar, including search and sorting -- Draft packages moved to the top -- Added category, size, and last modified date next to the package -- Added a link to the publishing portal next to the package -- New uploading flow: “Pre-exported .unitypackage” -- Previous uploading flow (folder selection) has been renamed to “From Assets Folder” -- Dependencies check has been renamed to “Include Package Manifest” for clarity -- Special Folders can now be selected and uploaded together with the package’s main folder (i.e. StreamingAssets, Plugins) -- You can now upload to multiple packages at the same time without waiting for the first one to finish -- Package can now be validated in the Uploading window by pressing the “Validate” button -- Added refresh and logout buttons to the bottom toolbar for easier access -- Packages caching - package information will no longer be redownloaded every time you open the Uploader window during the same Editor session -- (Experimental) Custom exporter - will export your package ~2 times faster, but may miss some asset previews in the final product. To enable it - click three dots on the top left side of the window and enable “Use Custom Exporting” - - -### Validator changes - -- UI has been reworked using UI Toolkit -- New tests based on the new guidelines -- Updated tests’ titles, descriptions, and error reporting - -## [5.0.5] - 2021-11-04 - -- Fixed namespace issues - -## [5.0.4] - 2020-07-28 - -- Fixed issues with Unity 2020.1 - -## [5.0.3] - 2020-05-07 - -- Remove "Remove Standard Assets" check - -## [5.0.2] - 2020-04-21 - -- Enable auto login with Unity account -- Upload package with thread - -## [5.0.1] - 2020-03-23 - -- Fix domain resolve issue - -## [5.0.0] - 2019-10-09 - -- Added "Package Validator" tool -- Added Help window -- Added logout confirmation popup -- Updated toolbar menu layout -- Removed "Mass Labeler" tool -- Updated layout of Login and Package Upload windows -- Error messages are now more elaborate and user-friendly -- Removed deprecated "Main Assets" step from the Package Upload window -- Package Upload window now has a step for including package manager dependencies -- Tooltips are now added to each upload process step - - -## [4.1.0] - 2018-05-14 - -- Made Tool compatible with 2017.1 - -## [4.0.7] - 2017-07-10 - -- Tweaked menu items. - -## [4.0.6] - 2016-07-15 - -- Improved error messages. - -## [4.0.5] - 2016-03-17 - -- Enabling upload of fbm files. - -## [4.0.4] - 2015-11-16 - -- Login improvements - -## [4.0.3] - 2015-11-16 - -- Prepare the Tools for Unity 5.3 - -## [4.0.2] - 2015-10-23 - -- Fixed issue where Upload button would not work for some projects. -- Fixed issues for publishers that only had one package. - -## [4.0.0] - 2015-09-01 - -- Replaced Package Manager with Package Upload. Package management is now handled by Publisher Administration \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/CHANGELOG.md.meta b/Installer/Packages/com.unity.asset-store-tools/CHANGELOG.md.meta deleted file mode 100644 index 0db1ee3..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/CHANGELOG.md.meta +++ /dev/null @@ -1,7 +0,0 @@ -fileFormatVersion: 2 -guid: 06607220dbd46414e8f66bf9c5e3eb79 -TextScriptImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor.meta b/Installer/Packages/com.unity.asset-store-tools/Editor.meta deleted file mode 100644 index 8521ad6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 166da5c6fc70e814a8262463903b2714 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api.meta deleted file mode 100644 index 0cf8e3f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: d48a2325d352e7a4cae56d3f8eeaab2d -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions.meta deleted file mode 100644 index 80ccfb1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 25799fb31cd475347af7f5442c231797 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/AuthenticationBase.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/AuthenticationBase.cs deleted file mode 100644 index 84d1fa8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/AuthenticationBase.cs +++ /dev/null @@ -1,48 +0,0 @@ -using AssetStoreTools.Api.Responses; -using AssetStoreTools.Utility; -using System; -using System.Collections.Generic; -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; -using UnityEngine; - -namespace AssetStoreTools.Api -{ - internal abstract class AuthenticationBase : IAuthenticationType - { - protected Uri LoginUrl = ApiUtility.CreateUri(Constants.Api.AuthenticateUrl, true); - protected FormUrlEncodedContent AuthenticationContent; - - protected FormUrlEncodedContent GetAuthenticationContent(params KeyValuePair[] content) - { - var baseContent = Constants.Api.DefaultAssetStoreQuery(); - - try { baseContent.Add("license_hash", ApiUtility.GetLicenseHash()); } catch { ASDebug.LogWarning("Could not retrieve license hash"); } - try { baseContent.Add("hardware_hash", ApiUtility.GetHardwareHash()); } catch { ASDebug.LogWarning("Could not retrieve hardware hash"); } - - foreach (var extraContent in content) - { - baseContent.Add(extraContent.Key, extraContent.Value); - } - - return new FormUrlEncodedContent(baseContent); - } - - protected AuthenticationResponse ParseResponse(HttpResponseMessage response) - { - try - { - response.EnsureSuccessStatusCode(); - var responseString = response.Content.ReadAsStringAsync().Result; - return new AuthenticationResponse(responseString); - } - catch (HttpRequestException e) - { - return new AuthenticationResponse(response.StatusCode, e) { Success = false }; - } - } - - public abstract Task Authenticate(IAssetStoreClient client, CancellationToken cancellationToken = default); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/AuthenticationBase.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/AuthenticationBase.cs.meta deleted file mode 100644 index 6b0cd8f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/AuthenticationBase.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: f677e03f1be1048439a1fa5e7a0a37b6 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreApi.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreApi.cs deleted file mode 100644 index 86db5cd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreApi.cs +++ /dev/null @@ -1,21 +0,0 @@ -using AssetStoreTools.Api.Models; -using AssetStoreTools.Api.Responses; -using System; -using System.Threading; -using System.Threading.Tasks; - -namespace AssetStoreTools.Api -{ - internal interface IAssetStoreApi - { - Task GetLatestAssetStoreToolsVersion(CancellationToken cancellationToken = default); - Task Authenticate(IAuthenticationType authenticationType, CancellationToken cancellationToken = default); - void Deauthenticate(); - Task GetPackages(CancellationToken cancellationToken = default); - Task GetCategories(CancellationToken cancellationToken = default); - Task GetPackageThumbnail(Package package, CancellationToken cancellationToken = default); - Task RefreshPackageMetadata(Package package, CancellationToken cancellationToken = default); - Task GetPackageUploadedVersions(Package package, CancellationToken cancellationToken = default); - Task UploadPackage(IPackageUploader uploader, IProgress progress = null, CancellationToken cancellationToken = default); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreApi.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreApi.cs.meta deleted file mode 100644 index 91ac851..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreApi.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: e616488c25d278741bb0d08168219309 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreClient.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreClient.cs deleted file mode 100644 index f6a6d3e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreClient.cs +++ /dev/null @@ -1,18 +0,0 @@ -using System; -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; - -namespace AssetStoreTools.Api -{ - internal interface IAssetStoreClient - { - void SetSessionId(string sessionId); - void ClearSessionId(); - - Task Get(Uri uri, CancellationToken cancellationToken = default); - Task Post(Uri uri, HttpContent content, CancellationToken cancellationToken = default); - Task Put(Uri uri, HttpContent content, CancellationToken cancellationToken = default); - Task Send(HttpRequestMessage request, CancellationToken cancellationToken = default); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreClient.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreClient.cs.meta deleted file mode 100644 index 6671aaf..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAssetStoreClient.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: b2bbadec62178cc4189e605367b219e7 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAuthenticationType.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAuthenticationType.cs deleted file mode 100644 index 8fa5c78..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAuthenticationType.cs +++ /dev/null @@ -1,11 +0,0 @@ -using AssetStoreTools.Api.Responses; -using System.Threading; -using System.Threading.Tasks; - -namespace AssetStoreTools.Api -{ - internal interface IAuthenticationType - { - Task Authenticate(IAssetStoreClient client, CancellationToken cancellationToken); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAuthenticationType.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAuthenticationType.cs.meta deleted file mode 100644 index 916782f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IAuthenticationType.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 0000dcd6975bc8e4abc546a19f194040 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IPackageUploader.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IPackageUploader.cs deleted file mode 100644 index ef7c89f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IPackageUploader.cs +++ /dev/null @@ -1,12 +0,0 @@ -using AssetStoreTools.Api.Responses; -using System; -using System.Threading; -using System.Threading.Tasks; - -namespace AssetStoreTools.Api -{ - internal interface IPackageUploader - { - Task Upload(IAssetStoreClient client, IProgress progress, CancellationToken cancellationToken = default); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IPackageUploader.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IPackageUploader.cs.meta deleted file mode 100644 index b4eb3db..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/IPackageUploader.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 0fc6c47b1c0a65540a40efbf1491193b -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/PackageUploaderBase.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/PackageUploaderBase.cs deleted file mode 100644 index e26bfc1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/PackageUploaderBase.cs +++ /dev/null @@ -1,59 +0,0 @@ -using AssetStoreTools.Api.Responses; -using System; -using System.IO; -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; - -namespace AssetStoreTools.Api -{ - internal abstract class PackageUploaderBase : IPackageUploader - { - protected const int UploadChunkSizeBytes = 32768; - protected const int UploadResponseTimeoutMs = 10000; - - protected abstract void ValidateSettings(); - public abstract Task Upload(IAssetStoreClient client, IProgress progress = null, CancellationToken cancellationToken = default); - - protected void EnsureSuccessResponse(HttpResponseMessage response) - { - try - { - response.EnsureSuccessStatusCode(); - } - catch - { - throw new Exception(response.Content.ReadAsStringAsync().Result); - } - } - - protected void WaitForUploadCompletion(Task response, FileStream requestFileStream, IProgress progress, CancellationToken cancellationToken) - { - // Progress tracking - int updateIntervalMs = 100; - bool allBytesSent = false; - DateTime timeOfCompletion = default; - - while (!response.IsCompleted) - { - float uploadProgress = (float)requestFileStream.Position / requestFileStream.Length * 100; - progress?.Report(uploadProgress); - Thread.Sleep(updateIntervalMs); - - // A timeout for rare cases, when package uploading reaches 100%, but Put task IsComplete value remains 'False' - if (requestFileStream.Position == requestFileStream.Length) - { - if (!allBytesSent) - { - allBytesSent = true; - timeOfCompletion = DateTime.UtcNow; - } - else if (DateTime.UtcNow.Subtract(timeOfCompletion).TotalMilliseconds > UploadResponseTimeoutMs) - { - throw new TimeoutException(); - } - } - } - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/PackageUploaderBase.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/PackageUploaderBase.cs.meta deleted file mode 100644 index 4764456..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Abstractions/PackageUploaderBase.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 2718ddd16e425ba4a82ab973724bcff7 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/ApiUtility.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/ApiUtility.cs deleted file mode 100644 index 545d6d4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/ApiUtility.cs +++ /dev/null @@ -1,76 +0,0 @@ -using AssetStoreTools.Api.Models; -using AssetStoreTools.Utility; -using System; -using System.Collections.Generic; -using System.Linq; -using UnityEditorInternal; - -namespace AssetStoreTools.Api -{ - internal class ApiUtility - { - public static Uri CreateUri(string url, bool includeDefaultAssetStoreQuery) => CreateUri(url, null, includeDefaultAssetStoreQuery); - public static Uri CreateUri(string url, IDictionary queryParameters, bool includeDefaultAssetStoreQuery) - { - IDictionary fullQueryParameters = includeDefaultAssetStoreQuery ? - Constants.Api.DefaultAssetStoreQuery() : new Dictionary(); - - if (queryParameters != null && queryParameters.Count > 0) - { - foreach (var kvp in queryParameters) - fullQueryParameters.Add(kvp); - } - - var builder = new UriBuilder(url); - if (fullQueryParameters.Count == 0) - return builder.Uri; - - var fullQueryParameterString = string.Empty; - foreach (var queryParam in fullQueryParameters) - { - var escapedValue = queryParam.Value != null ? Uri.EscapeDataString(queryParam.Value) : string.Empty; - fullQueryParameterString += $"{queryParam.Key}={escapedValue}&"; - } - fullQueryParameterString = fullQueryParameterString.Remove(fullQueryParameterString.Length - 1); - - builder.Query = fullQueryParameterString; - return builder.Uri; - } - - public static List CombinePackageData(List mainPackageData, List extraPackageData, List categoryData) - { - foreach (var package in mainPackageData) - { - var extraData = extraPackageData.FirstOrDefault(x => package.PackageId == x.PackageId); - - if (extraData == null) - { - ASDebug.LogWarning($"Could not find extra data for Package {package.PackageId}"); - continue; - } - - var categoryId = extraData.CategoryId; - var category = categoryData.FirstOrDefault(x => x.Id.ToString() == categoryId); - if (category != null) - package.Category = category.Name; - else - package.Category = "Unknown"; - - package.Modified = extraData.Modified; - package.Size = extraData.Size; - } - - return mainPackageData; - } - - public static string GetLicenseHash() - { - return InternalEditorUtility.GetAuthToken().Substring(0, 40); - } - - public static string GetHardwareHash() - { - return InternalEditorUtility.GetAuthToken().Substring(40, 40); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/ApiUtility.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/ApiUtility.cs.meta deleted file mode 100644 index 5291958..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/ApiUtility.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 5becec0b3c0ba274fb0b01544e63b6c4 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreApi.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreApi.cs deleted file mode 100644 index a8530dc..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreApi.cs +++ /dev/null @@ -1,268 +0,0 @@ -using AssetStoreTools.Api.Models; -using AssetStoreTools.Api.Responses; -using Newtonsoft.Json.Linq; -using System; -using System.Linq; -using System.Threading; -using System.Threading.Tasks; - -namespace AssetStoreTools.Api -{ - internal class AssetStoreApi : IAssetStoreApi - { - private IAssetStoreClient _client; - - public AssetStoreApi(IAssetStoreClient client) - { - _client = client; - } - - public async Task GetLatestAssetStoreToolsVersion(CancellationToken cancellationToken = default) - { - try - { - var uri = ApiUtility.CreateUri(Constants.Api.AssetStoreToolsLatestVersionUrl, false); - var response = await _client.Get(uri, cancellationToken); - cancellationToken.ThrowIfCancellationRequested(); - response.EnsureSuccessStatusCode(); - var responseStr = response.Content.ReadAsStringAsync().Result; - return new AssetStoreToolsVersionResponse(responseStr); - } - catch (OperationCanceledException e) - { - return new AssetStoreToolsVersionResponse() { Success = false, Cancelled = true, Exception = e }; - } - catch (Exception e) - { - return new AssetStoreToolsVersionResponse() { Success = false, Exception = e }; - } - } - - public async Task Authenticate(IAuthenticationType authenticationType, CancellationToken cancellationToken = default) - { - try - { - var loginResponse = await authenticationType.Authenticate(_client, cancellationToken); - if (loginResponse.Success) - { - _client.SetSessionId(loginResponse.User.SessionId); - } - - return loginResponse; - } - catch (OperationCanceledException e) - { - return new AuthenticationResponse() { Success = false, Cancelled = true, Exception = e }; - } - catch (Exception e) - { - return new AuthenticationResponse() { Success = false, Exception = e }; - } - } - - public void Deauthenticate() - { - _client.ClearSessionId(); - } - - public async Task GetPackages(CancellationToken cancellationToken = default) - { - try - { - var mainDataResponse = await GetPackageDataMain(cancellationToken); - if (!mainDataResponse.Success) - throw mainDataResponse.Exception; - var additionalDataResponse = await GetPackageDataExtra(cancellationToken); - if (!additionalDataResponse.Success) - throw additionalDataResponse.Exception; - var categoryDataResponse = await GetCategories(cancellationToken); - if (!categoryDataResponse.Success) - throw categoryDataResponse.Exception; - - var joinedData = ApiUtility.CombinePackageData(mainDataResponse.Packages, additionalDataResponse.Packages, categoryDataResponse.Categories); - return new PackagesDataResponse() { Success = true, Packages = joinedData }; - } - catch (OperationCanceledException e) - { - return new PackagesDataResponse() { Success = false, Cancelled = true, Exception = e }; - } - catch (Exception e) - { - return new PackagesDataResponse() { Success = false, Exception = e }; - } - } - - private async Task GetPackageDataMain(CancellationToken cancellationToken) - { - try - { - var uri = ApiUtility.CreateUri(Constants.Api.GetPackagesUrl, true); - var response = await _client.Get(uri, cancellationToken); - - cancellationToken.ThrowIfCancellationRequested(); - response.EnsureSuccessStatusCode(); - - var responseStr = response.Content.ReadAsStringAsync().Result; - return new PackagesDataResponse(responseStr); - } - catch (OperationCanceledException e) - { - return new PackagesDataResponse() { Success = false, Cancelled = true, Exception = e }; - } - catch (Exception e) - { - return new PackagesDataResponse() { Success = false, Exception = e }; - } - } - - private async Task GetPackageDataExtra(CancellationToken cancellationToken) - { - try - { - var uri = ApiUtility.CreateUri(Constants.Api.GetPackagesAdditionalDataUrl, true); - var response = await _client.Get(uri, cancellationToken); - - cancellationToken.ThrowIfCancellationRequested(); - response.EnsureSuccessStatusCode(); - - var responseStr = response.Content.ReadAsStringAsync().Result; - return new PackagesAdditionalDataResponse(responseStr); - } - catch (OperationCanceledException e) - { - return new PackagesAdditionalDataResponse() { Success = false, Cancelled = true, Exception = e }; - } - catch (Exception e) - { - return new PackagesAdditionalDataResponse() { Success = false, Exception = e }; - } - } - - public async Task GetCategories(CancellationToken cancellationToken) - { - try - { - var uri = ApiUtility.CreateUri(Constants.Api.GetCategoriesUrl, true); - var response = await _client.Get(uri, cancellationToken); - - cancellationToken.ThrowIfCancellationRequested(); - response.EnsureSuccessStatusCode(); - - var responseStr = response.Content.ReadAsStringAsync().Result; - return new CategoryDataResponse(responseStr); - } - catch (OperationCanceledException e) - { - return new CategoryDataResponse() { Success = false, Cancelled = true, Exception = e }; - } - catch (Exception e) - { - return new CategoryDataResponse() { Success = false, Exception = e }; - } - } - - public async Task GetPackageThumbnail(Package package, CancellationToken cancellationToken = default) - { - try - { - if (string.IsNullOrEmpty(package.IconUrl)) - throw new Exception($"Could not retrieve thumbnail for package {package.PackageId} - icon url is null"); - - var response = await _client.Get(new Uri(package.IconUrl), cancellationToken); - - cancellationToken.ThrowIfCancellationRequested(); - response.EnsureSuccessStatusCode(); - - var responseBytes = response.Content.ReadAsByteArrayAsync().Result; - return new PackageThumbnailResponse(responseBytes); - } - catch (OperationCanceledException e) - { - return new PackageThumbnailResponse() { Success = false, Cancelled = true, Exception = e }; - } - catch (Exception e) - { - return new PackageThumbnailResponse() { Success = false, Exception = e }; - } - } - - public async Task RefreshPackageMetadata(Package package, CancellationToken cancellationToken = default) - { - try - { - var refreshedPackage = JObject.FromObject(package).DeepClone().ToObject(); - - var packagesResponse = await GetPackageDataExtra(cancellationToken); - if (!packagesResponse.Success) - throw packagesResponse.Exception; - - // Find the updated package data in the latest data json - var packageRefreshSource = packagesResponse.Packages.FirstOrDefault(x => x.PackageId == refreshedPackage.PackageId); - if (packageRefreshSource == null) - return new RefreshedPackageDataResponse() { Success = false, Exception = new MissingMemberException($"Unable to find downloaded package data for package id {package.PackageId}") }; - - // Retrieve the category map - var categoryData = await GetCategories(cancellationToken); - if (!categoryData.Success) - return new RefreshedPackageDataResponse() { Success = false, Exception = packagesResponse.Exception }; - - // Update the package data - refreshedPackage.Name = packageRefreshSource.Name; - refreshedPackage.Status = packageRefreshSource.Status; - var newCategory = categoryData.Categories.FirstOrDefault(x => x.Id.ToString() == packageRefreshSource.CategoryId); - refreshedPackage.Category = newCategory != null ? newCategory.Name : "Unknown"; - refreshedPackage.Modified = packageRefreshSource.Modified; - refreshedPackage.Size = packageRefreshSource.Size; - - return new RefreshedPackageDataResponse() { Success = true, Package = refreshedPackage }; - } - catch (OperationCanceledException) - { - return new RefreshedPackageDataResponse() { Success = false, Cancelled = true }; - } - catch (Exception e) - { - return new RefreshedPackageDataResponse() { Success = false, Exception = e }; - } - } - - public async Task GetPackageUploadedVersions(Package package, CancellationToken cancellationToken = default) - { - try - { - var uri = ApiUtility.CreateUri(Constants.Api.GetPackageUploadedVersionsUrl(package.PackageId, package.VersionId), true); - var response = await _client.Get(uri, cancellationToken); - - cancellationToken.ThrowIfCancellationRequested(); - response.EnsureSuccessStatusCode(); - - var responseStr = response.Content.ReadAsStringAsync().Result; - return new PackageUploadedUnityVersionDataResponse(responseStr); - } - catch (OperationCanceledException e) - { - return new PackageUploadedUnityVersionDataResponse() { Success = false, Cancelled = true, Exception = e }; - } - catch (Exception e) - { - return new PackageUploadedUnityVersionDataResponse() { Success = false, Exception = e }; - } - } - - public async Task UploadPackage(IPackageUploader uploader, IProgress progress = null, CancellationToken cancellationToken = default) - { - try - { - return await uploader.Upload(_client, progress, cancellationToken); - } - catch (OperationCanceledException e) - { - return new PackageUploadResponse() { Success = false, Cancelled = true, Exception = e }; - } - catch (Exception e) - { - return new PackageUploadResponse() { Success = false, Exception = e }; - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreApi.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreApi.cs.meta deleted file mode 100644 index d248bfe..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreApi.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 684fca3fffd79d944a32d9b3adbfc007 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreClient.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreClient.cs deleted file mode 100644 index f71bff8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreClient.cs +++ /dev/null @@ -1,55 +0,0 @@ -using System; -using System.Net; -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; - -namespace AssetStoreTools.Api -{ - internal class AssetStoreClient : IAssetStoreClient - { - private HttpClient _httpClient; - - public AssetStoreClient() - { - ServicePointManager.DefaultConnectionLimit = 500; - _httpClient = new HttpClient(); - _httpClient.DefaultRequestHeaders.ConnectionClose = false; - _httpClient.DefaultRequestHeaders.Add("Accept", "application/json"); - _httpClient.Timeout = TimeSpan.FromMinutes(1320); - } - - public void SetSessionId(string sessionId) - { - ClearSessionId(); - - if (!string.IsNullOrEmpty(sessionId)) - _httpClient.DefaultRequestHeaders.Add("X-Unity-Session", sessionId); - } - - public void ClearSessionId() - { - _httpClient.DefaultRequestHeaders.Remove("X-Unity-Session"); - } - - public Task Get(Uri uri, CancellationToken cancellationToken = default) - { - return _httpClient.GetAsync(uri, cancellationToken); - } - - public Task Post(Uri uri, HttpContent content, CancellationToken cancellationToken = default) - { - return _httpClient.PostAsync(uri, content, cancellationToken); - } - - public Task Put(Uri uri, HttpContent content, CancellationToken cancellationToken = default) - { - return _httpClient.PutAsync(uri, content, cancellationToken); - } - - public Task Send(HttpRequestMessage request, CancellationToken cancellationToken = default) - { - return _httpClient.SendAsync(request, cancellationToken); - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreClient.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreClient.cs.meta deleted file mode 100644 index 097e6a3..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/AssetStoreClient.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 80b4527c908161a4b9f06dc393b502f9 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/CloudTokenAuthentication.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/CloudTokenAuthentication.cs deleted file mode 100644 index 5a1bd5e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/CloudTokenAuthentication.cs +++ /dev/null @@ -1,25 +0,0 @@ -using AssetStoreTools.Api.Responses; -using System.Collections.Generic; -using System.Threading; -using System.Threading.Tasks; - -namespace AssetStoreTools.Api -{ - internal class CloudTokenAuthentication : AuthenticationBase - { - public CloudTokenAuthentication(string cloudToken) - { - AuthenticationContent = GetAuthenticationContent( - new KeyValuePair("user_access_token", cloudToken) - ); - } - - public override async Task Authenticate(IAssetStoreClient client, CancellationToken cancellationToken) - { - var result = await client.Post(LoginUrl, AuthenticationContent, cancellationToken); - cancellationToken.ThrowIfCancellationRequested(); - - return ParseResponse(result); - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/CloudTokenAuthentication.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/CloudTokenAuthentication.cs.meta deleted file mode 100644 index 4d1495a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/CloudTokenAuthentication.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 99f1baec74f26a34bb972b19c92d523f -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/CredentialsAuthentication.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/CredentialsAuthentication.cs deleted file mode 100644 index 2c51505..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/CredentialsAuthentication.cs +++ /dev/null @@ -1,26 +0,0 @@ -using AssetStoreTools.Api.Responses; -using System.Collections.Generic; -using System.Threading; -using System.Threading.Tasks; - -namespace AssetStoreTools.Api -{ - internal class CredentialsAuthentication : AuthenticationBase - { - public CredentialsAuthentication(string email, string password) - { - AuthenticationContent = GetAuthenticationContent( - new KeyValuePair("user", email), - new KeyValuePair("pass", password) - ); - } - - public override async Task Authenticate(IAssetStoreClient client, CancellationToken cancellationToken) - { - var result = await client.Post(LoginUrl, AuthenticationContent, cancellationToken); - cancellationToken.ThrowIfCancellationRequested(); - - return ParseResponse(result); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/CredentialsAuthentication.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/CredentialsAuthentication.cs.meta deleted file mode 100644 index 35404d1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/CredentialsAuthentication.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 353e556b63fd441428f387bc85aa612c -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models.meta deleted file mode 100644 index bfcab0b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 1f83e4b5507886f4b873c22c146b8f6a -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Category.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Category.cs deleted file mode 100644 index 2cb1298..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Category.cs +++ /dev/null @@ -1,58 +0,0 @@ -using Newtonsoft.Json.Serialization; -using System.Collections.Generic; - -namespace AssetStoreTools.Api.Models -{ - internal class Category - { - public int Id { get; set; } - public string Name { get; set; } - public string Status { get; set; } - - public class AssetStoreCategoryResolver : DefaultContractResolver - { - private Dictionary _propertyConversions; - - public AssetStoreCategoryResolver() - { - _propertyConversions = new Dictionary() - { - { nameof(Category.Name), "assetstore_name" } - }; - } - - protected override string ResolvePropertyName(string propertyName) - { - if (_propertyConversions.ContainsKey(propertyName)) - return _propertyConversions[propertyName]; - - return base.ResolvePropertyName(propertyName); - } - } - - public class CachedCategoryResolver : DefaultContractResolver - { - private static CachedCategoryResolver _instance; - public static CachedCategoryResolver Instance => _instance ?? (_instance = new CachedCategoryResolver()); - - private Dictionary _propertyConversion; - - private CachedCategoryResolver() - { - this.NamingStrategy = new SnakeCaseNamingStrategy(); - _propertyConversion = new Dictionary() - { - { nameof(Category.Name), "name" } - }; - } - - protected override string ResolvePropertyName(string propertyName) - { - if (_propertyConversion.ContainsKey(propertyName)) - return _propertyConversion[propertyName]; - - return base.ResolvePropertyName(propertyName); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Category.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Category.cs.meta deleted file mode 100644 index cbdb96e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Category.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 5897866bc65f5834dab1f17371daada7 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Package.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Package.cs deleted file mode 100644 index 442c919..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Package.cs +++ /dev/null @@ -1,80 +0,0 @@ -using Newtonsoft.Json.Serialization; -using System.Collections.Generic; - -namespace AssetStoreTools.Api.Models -{ - internal class Package - { - public string PackageId { get; set; } - public string VersionId { get; set; } - public string Name { get; set; } - public string Status { get; set; } - public string Category { get; set; } - public bool IsCompleteProject { get; set; } - public string RootGuid { get; set; } - public string RootPath { get; set; } - public string ProjectPath { get; set; } - public string Modified { get; set; } - public string Size { get; set; } - public string IconUrl { get; set; } - - public class AssetStorePackageResolver : DefaultContractResolver - { - private static AssetStorePackageResolver _instance; - public static AssetStorePackageResolver Instance => _instance ?? (_instance = new AssetStorePackageResolver()); - - private Dictionary _propertyConversions; - - private AssetStorePackageResolver() - { - _propertyConversions = new Dictionary() - { - { nameof(Package.VersionId), "id" }, - { nameof(Package.IsCompleteProject), "is_complete_project" }, - { nameof(Package.RootGuid), "root_guid" }, - { nameof(Package.RootPath), "root_path" }, - { nameof(Package.ProjectPath), "project_path" }, - { nameof(Package.IconUrl), "icon_url" } - }; - } - - protected override string ResolvePropertyName(string propertyName) - { - if (_propertyConversions.ContainsKey(propertyName)) - return _propertyConversions[propertyName]; - - return base.ResolvePropertyName(propertyName); - } - } - - public class CachedPackageResolver : DefaultContractResolver - { - private static CachedPackageResolver _instance; - public static CachedPackageResolver Instance => _instance ?? (_instance = new CachedPackageResolver()); - - private Dictionary _propertyConversion; - - private CachedPackageResolver() - { - this.NamingStrategy = new SnakeCaseNamingStrategy(); - _propertyConversion = new Dictionary() - { - { nameof(Package.PackageId), "package_id" }, - { nameof(Package.VersionId), "version_id" }, - { nameof(Package.IsCompleteProject), "is_complete_project" }, - { nameof(Package.RootGuid), "root_guid" }, - { nameof(Package.RootPath), "root_path" }, - { nameof(Package.IconUrl), "icon_url" } - }; - } - - protected override string ResolvePropertyName(string propertyName) - { - if (_propertyConversion.ContainsKey(propertyName)) - return _propertyConversion[propertyName]; - - return base.ResolvePropertyName(propertyName); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Package.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Package.cs.meta deleted file mode 100644 index 6e345c3..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/Package.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 7e9f0b99820061b49abf6e8cf544a727 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/PackageAdditionalData.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/PackageAdditionalData.cs deleted file mode 100644 index 8686ccc..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/PackageAdditionalData.cs +++ /dev/null @@ -1,41 +0,0 @@ -using Newtonsoft.Json.Serialization; -using System.Collections.Generic; - -namespace AssetStoreTools.Api.Models -{ - internal class PackageAdditionalData - { - public string Name { get; set; } - public string Status { get; set; } - public string PackageId { get; set; } - public string VersionId { get; set; } - public string CategoryId { get; set; } - public string Modified { get; set; } - public string Size { get; set; } - - public class AssetStorePackageResolver : DefaultContractResolver - { - private static AssetStorePackageResolver _instance; - public static AssetStorePackageResolver Instance => _instance ?? (_instance = new AssetStorePackageResolver()); - - private Dictionary _propertyConversions; - - private AssetStorePackageResolver() - { - _propertyConversions = new Dictionary() - { - { nameof(PackageAdditionalData.PackageId), "id" }, - { nameof(PackageAdditionalData.CategoryId), "category_id" } - }; - } - - protected override string ResolvePropertyName(string propertyName) - { - if (_propertyConversions.ContainsKey(propertyName)) - return _propertyConversions[propertyName]; - - return base.ResolvePropertyName(propertyName); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/PackageAdditionalData.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/PackageAdditionalData.cs.meta deleted file mode 100644 index 75113a2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/PackageAdditionalData.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 0663f29f3fcd0e34ab77338d1bdbb528 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/User.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/User.cs deleted file mode 100644 index c80a506..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/User.cs +++ /dev/null @@ -1,51 +0,0 @@ -using Newtonsoft.Json.Serialization; -using System.Collections.Generic; - -namespace AssetStoreTools.Api.Models -{ - internal class User - { - public string Id { get; set; } - public string SessionId { get; set; } - public string Name { get; set; } - public string Username { get; set; } - public string PublisherId { get; set; } - public bool IsPublisher => !string.IsNullOrEmpty(PublisherId); - - public override string ToString() - { - return - $"{nameof(Id)}: {Id}\n" + - $"{nameof(Name)}: {Name}\n" + - $"{nameof(Username)}: {Username}\n" + - $"{nameof(PublisherId)}: {PublisherId}\n" + - $"{nameof(IsPublisher)}: {IsPublisher}\n" + - $"{nameof(SessionId)}: [HIDDEN]"; - } - - public class AssetStoreUserResolver : DefaultContractResolver - { - private static AssetStoreUserResolver _instance; - public static AssetStoreUserResolver Instance => _instance ?? (_instance = new AssetStoreUserResolver()); - - private Dictionary _propertyConversions; - - private AssetStoreUserResolver() - { - _propertyConversions = new Dictionary() - { - { nameof(User.SessionId), "xunitysession" }, - { nameof(User.PublisherId), "publisher" } - }; - } - - protected override string ResolvePropertyName(string propertyName) - { - if (_propertyConversions.ContainsKey(propertyName)) - return _propertyConversions[propertyName]; - - return base.ResolvePropertyName(propertyName); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/User.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/User.cs.meta deleted file mode 100644 index bf60282..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Models/User.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: caf38df5cd685a345a1ebec8f7651c93 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses.meta deleted file mode 100644 index 534c529..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 49581213e7b6ca645955cce8ce23ac4b -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreResponse.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreResponse.cs deleted file mode 100644 index 2e7a6b2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreResponse.cs +++ /dev/null @@ -1,45 +0,0 @@ -using Newtonsoft.Json; -using Newtonsoft.Json.Linq; -using System; - -namespace AssetStoreTools.Api.Responses -{ - /// - /// A structure used to return the success outcome and the result of Asset Store API calls - /// - internal class AssetStoreResponse - { - public bool Success { get; set; } = false; - public bool Cancelled { get; set; } = false; - public Exception Exception { get; set; } - - public AssetStoreResponse() { } - - public AssetStoreResponse(Exception e) : this() - { - Exception = e; - } - - protected void ValidateAssetStoreResponse(string json) - { - var dict = JsonConvert.DeserializeObject(json); - if (dict == null) - throw new Exception("Response is empty"); - - // Some json responses return an error field on error - if (dict.ContainsKey("error")) - { - // Server side error message - // Do not write to console since this is an error that - // is "expected" ie. can be handled by the gui. - throw new Exception(dict.GetValue("error").ToString()); - } - // Some json responses return status+message fields instead of an error field. Go figure. - else if (dict.ContainsKey("status") && dict.GetValue("status").ToString() != "ok" - && dict.ContainsKey("message")) - { - throw new Exception(dict.GetValue("message").ToString()); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreResponse.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreResponse.cs.meta deleted file mode 100644 index 3169e74..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreResponse.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: ee338db031a0cfb459f7cac7f41a5d75 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreToolsVersionResponse.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreToolsVersionResponse.cs deleted file mode 100644 index ec3bb87..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreToolsVersionResponse.cs +++ /dev/null @@ -1,38 +0,0 @@ -using Newtonsoft.Json; -using Newtonsoft.Json.Linq; -using System; - -namespace AssetStoreTools.Api.Responses -{ - internal class AssetStoreToolsVersionResponse : AssetStoreResponse - { - public string Version { get; set; } - - public AssetStoreToolsVersionResponse() : base() { } - public AssetStoreToolsVersionResponse(Exception e) : base(e) { } - - public AssetStoreToolsVersionResponse(string json) - { - try - { - ValidateAssetStoreResponse(json); - ParseVersion(json); - Success = true; - } - catch (Exception e) - { - Success = false; - Exception = e; - } - } - - private void ParseVersion(string json) - { - var dict = JsonConvert.DeserializeObject(json); - if (!dict.ContainsKey("version")) - throw new Exception("Version was not found"); - - Version = dict.GetValue("version").ToString(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreToolsVersionResponse.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreToolsVersionResponse.cs.meta deleted file mode 100644 index cdcdfd5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AssetStoreToolsVersionResponse.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 40558675926f913478a654350149209e -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AuthenticationResponse.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AuthenticationResponse.cs deleted file mode 100644 index 09c786c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AuthenticationResponse.cs +++ /dev/null @@ -1,74 +0,0 @@ -using AssetStoreTools.Api.Models; -using Newtonsoft.Json; -using System; -using System.Net; -using System.Net.Http; - -namespace AssetStoreTools.Api.Responses -{ - internal class AuthenticationResponse : AssetStoreResponse - { - public User User { get; set; } - - public AuthenticationResponse() : base() { } - - public AuthenticationResponse(Exception e) : base(e) { } - - public AuthenticationResponse(HttpStatusCode statusCode, HttpRequestException fallbackException) - { - string message; - switch (statusCode) - { - case HttpStatusCode.Unauthorized: - message = "Incorrect email and/or password. Please try again."; - break; - case HttpStatusCode.InternalServerError: - message = "Authentication request failed\nIf you were logging in with your Unity Cloud account, please make sure you are still logged in.\n" + - "This might also be caused by too many invalid login attempts - if that is the case, please try again later."; - break; - default: - Exception = fallbackException; - return; - } - - Exception = new Exception(message); - } - - public AuthenticationResponse(string json) - { - try - { - ValidateAssetStoreResponse(json); - var serializerSettings = new JsonSerializerSettings() - { - ContractResolver = User.AssetStoreUserResolver.Instance - }; - User = JsonConvert.DeserializeObject(json, serializerSettings); - ValidateLoginData(); - ValidatePublisher(); - Success = true; - } - catch (Exception e) - { - Success = false; - Exception = e; - } - } - - private void ValidateLoginData() - { - if (string.IsNullOrEmpty(User.Id) - || string.IsNullOrEmpty(User.SessionId) - || string.IsNullOrEmpty(User.Name) - || string.IsNullOrEmpty(User.Username)) - throw new Exception("Could not parse the necessary publisher information from the response."); - } - - private void ValidatePublisher() - { - if (!User.IsPublisher) - throw new Exception($"Your Unity ID {User.Name} is not currently connected to a publisher account. " + - $"Please create a publisher profile."); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AuthenticationResponse.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AuthenticationResponse.cs.meta deleted file mode 100644 index 8a0544c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/AuthenticationResponse.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: ec3a5cb59a7e78646b07f800d317874d -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/CategoryDataResponse.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/CategoryDataResponse.cs deleted file mode 100644 index 4ff740b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/CategoryDataResponse.cs +++ /dev/null @@ -1,43 +0,0 @@ -using AssetStoreTools.Api.Models; -using Newtonsoft.Json; -using Newtonsoft.Json.Linq; -using System; -using System.Collections.Generic; - -namespace AssetStoreTools.Api.Responses -{ - internal class CategoryDataResponse : AssetStoreResponse - { - public List Categories { get; set; } - - public CategoryDataResponse() : base() { } - public CategoryDataResponse(Exception e) : base(e) { } - - public CategoryDataResponse(string json) - { - try - { - var categoryArray = JsonConvert.DeserializeObject(json); - - Categories = new List(); - var serializer = new JsonSerializer() - { - ContractResolver = new Category.AssetStoreCategoryResolver() - }; - - foreach (var categoryData in categoryArray) - { - var category = categoryData.ToObject(serializer); - Categories.Add(category); - } - - Success = true; - } - catch (Exception e) - { - Success = false; - Exception = e; - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/CategoryDataResponse.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/CategoryDataResponse.cs.meta deleted file mode 100644 index 9c79529..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/CategoryDataResponse.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: e3789323453f1604286b436f77bdca97 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageThumbnailResponse.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageThumbnailResponse.cs deleted file mode 100644 index f4e8ac9..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageThumbnailResponse.cs +++ /dev/null @@ -1,31 +0,0 @@ -using System; -using UnityEngine; - -namespace AssetStoreTools.Api.Responses -{ - internal class PackageThumbnailResponse : AssetStoreResponse - { - public Texture2D Thumbnail { get; set; } - public PackageThumbnailResponse() : base() { } - public PackageThumbnailResponse(Exception e) : base(e) { } - - public PackageThumbnailResponse(byte[] textureBytes) - { - try - { - var tex = new Texture2D(1, 1, TextureFormat.RGBA32, false); - var success = tex.LoadImage(textureBytes); - if (!success) - throw new Exception("Could not retrieve image from the provided texture bytes"); - - Thumbnail = tex; - Success = true; - } - catch (Exception e) - { - Success = false; - Exception = e; - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageThumbnailResponse.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageThumbnailResponse.cs.meta deleted file mode 100644 index 4187474..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageThumbnailResponse.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: dacfba636b3757e408514b850d715e18 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageUploadedUnityVersionDataResponse.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageUploadedUnityVersionDataResponse.cs deleted file mode 100644 index 4f57d64..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageUploadedUnityVersionDataResponse.cs +++ /dev/null @@ -1,44 +0,0 @@ -using Newtonsoft.Json; -using Newtonsoft.Json.Linq; -using System; -using System.Collections.Generic; - -namespace AssetStoreTools.Api.Responses -{ - internal class PackageUploadedUnityVersionDataResponse : AssetStoreResponse - { - public List UnityVersions { get; set; } - - public PackageUploadedUnityVersionDataResponse() : base() { } - public PackageUploadedUnityVersionDataResponse(Exception e) : base(e) { } - - public PackageUploadedUnityVersionDataResponse(string json) - { - try - { - ValidateAssetStoreResponse(json); - ParseVersionData(json); - Success = true; - } - catch (Exception e) - { - Success = false; - Exception = e; - } - } - - private void ParseVersionData(string json) - { - var data = JsonConvert.DeserializeObject(json); - try - { - var content = data.GetValue("content").ToObject(); - UnityVersions = content.GetValue("unity_versions").ToObject>(); - } - catch - { - throw new Exception("Could not parse the unity versions array"); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageUploadedUnityVersionDataResponse.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageUploadedUnityVersionDataResponse.cs.meta deleted file mode 100644 index d34cef1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackageUploadedUnityVersionDataResponse.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 2552f659a600e124aa952f3ba760ddf3 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesAdditionalDataResponse.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesAdditionalDataResponse.cs deleted file mode 100644 index df01e70..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesAdditionalDataResponse.cs +++ /dev/null @@ -1,59 +0,0 @@ -using AssetStoreTools.Api.Models; -using Newtonsoft.Json; -using Newtonsoft.Json.Linq; -using System; -using System.Collections.Generic; - -namespace AssetStoreTools.Api.Responses -{ - internal class PackagesAdditionalDataResponse : AssetStoreResponse - { - public List Packages { get; set; } - - public PackagesAdditionalDataResponse() : base() { } - public PackagesAdditionalDataResponse(Exception e) : base(e) { } - - public PackagesAdditionalDataResponse(string json) - { - try - { - ValidateAssetStoreResponse(json); - ParseExtraData(json); - Success = true; - } - catch (Exception e) - { - Success = false; - Exception = e; - } - } - - private void ParseExtraData(string json) - { - var packageDict = JsonConvert.DeserializeObject(json); - if (!packageDict.ContainsKey("packages")) - throw new Exception("Response did not not contain the list of packages"); - - Packages = new List(); - var serializer = new JsonSerializer() - { - ContractResolver = PackageAdditionalData.AssetStorePackageResolver.Instance - }; - - var packageArray = packageDict.GetValue("packages").ToObject(); - foreach (var packageData in packageArray) - { - var package = packageData.ToObject(serializer); - - // Some fields are based on the latest version in the json - var latestVersion = packageData["versions"].ToObject().Last; - - package.VersionId = latestVersion["id"].ToString(); - package.Modified = latestVersion["modified"].ToString(); - package.Size = latestVersion["size"].ToString(); - - Packages.Add(package); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesAdditionalDataResponse.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesAdditionalDataResponse.cs.meta deleted file mode 100644 index c5e3704..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesAdditionalDataResponse.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 88d58ad5e0eea6345b5c83f30ee8ebd5 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesDataResponse.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesDataResponse.cs deleted file mode 100644 index d9fb47c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesDataResponse.cs +++ /dev/null @@ -1,59 +0,0 @@ -using AssetStoreTools.Api.Models; -using Newtonsoft.Json; -using Newtonsoft.Json.Linq; -using System; -using System.Collections.Generic; - -namespace AssetStoreTools.Api.Responses -{ - internal class PackagesDataResponse : AssetStoreResponse - { - public List Packages { get; set; } - - public PackagesDataResponse() : base() { } - public PackagesDataResponse(Exception e) : base(e) { } - - public PackagesDataResponse(string json) - { - try - { - ValidateAssetStoreResponse(json); - ParseMainData(json); - Success = true; - } - catch (Exception e) - { - Success = false; - Exception = e; - } - } - - private void ParseMainData(string json) - { - var packageDict = JsonConvert.DeserializeObject(json); - if (!packageDict.ContainsKey("packages")) - throw new Exception("Response did not not contain the list of packages"); - - Packages = new List(); - var serializer = new JsonSerializer() - { - ContractResolver = Package.AssetStorePackageResolver.Instance - }; - - foreach (var packageToken in packageDict["packages"]) - { - var property = (JProperty)packageToken; - var packageData = property.Value.ToObject(serializer); - - // Package Id is the key of the package object - packageData.PackageId = property.Name; - - // Package Icon Url is returned without the https: prefix - if (!string.IsNullOrEmpty(packageData.IconUrl)) - packageData.IconUrl = $"https:{packageData.IconUrl}"; - - Packages.Add(packageData); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesDataResponse.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesDataResponse.cs.meta deleted file mode 100644 index c47ff0b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/PackagesDataResponse.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 705ec748e689148479f54666993cd79d -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/RefreshedPackageDataResponse.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/RefreshedPackageDataResponse.cs deleted file mode 100644 index a0479a0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/RefreshedPackageDataResponse.cs +++ /dev/null @@ -1,12 +0,0 @@ -using AssetStoreTools.Api.Models; -using System; - -namespace AssetStoreTools.Api.Responses -{ - internal class RefreshedPackageDataResponse : AssetStoreResponse - { - public Package Package { get; set; } - public RefreshedPackageDataResponse() { } - public RefreshedPackageDataResponse(Exception e) : base(e) { } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/RefreshedPackageDataResponse.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/RefreshedPackageDataResponse.cs.meta deleted file mode 100644 index 2b7a974..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/RefreshedPackageDataResponse.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 20f710024d5ed514db02672f12ac361c -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/UploadResponse.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/UploadResponse.cs deleted file mode 100644 index 3fa2160..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/UploadResponse.cs +++ /dev/null @@ -1,28 +0,0 @@ -using System; - -namespace AssetStoreTools.Api.Responses -{ - internal class PackageUploadResponse : AssetStoreResponse - { - public UploadStatus Status { get; set; } - - public PackageUploadResponse() : base() { } - public PackageUploadResponse(Exception e) : base(e) { } - - public PackageUploadResponse(string json) - { - try - { - ValidateAssetStoreResponse(json); - Status = UploadStatus.Success; - Success = true; - } - catch (Exception e) - { - Success = false; - Status = UploadStatus.Fail; - Exception = e; - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/UploadResponse.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/UploadResponse.cs.meta deleted file mode 100644 index 6ac626b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/Responses/UploadResponse.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 8f1758cfa8119cf49a61b010a04352e4 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/SessionAuthentication.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/SessionAuthentication.cs deleted file mode 100644 index eb5e54c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/SessionAuthentication.cs +++ /dev/null @@ -1,25 +0,0 @@ -using AssetStoreTools.Api.Responses; -using System.Collections.Generic; -using System.Threading; -using System.Threading.Tasks; - -namespace AssetStoreTools.Api -{ - internal class SessionAuthentication : AuthenticationBase - { - public SessionAuthentication(string sessionId) - { - AuthenticationContent = GetAuthenticationContent( - new KeyValuePair("reuse_session", sessionId) - ); - } - - public override async Task Authenticate(IAssetStoreClient client, CancellationToken cancellationToken) - { - var result = await client.Post(LoginUrl, AuthenticationContent, cancellationToken); - cancellationToken.ThrowIfCancellationRequested(); - - return ParseResponse(result); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/SessionAuthentication.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/SessionAuthentication.cs.meta deleted file mode 100644 index f11fc25..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/SessionAuthentication.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 02e970f660088cc4b89003608d59cd06 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/UnityPackageUploader.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/UnityPackageUploader.cs deleted file mode 100644 index 17c765f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/UnityPackageUploader.cs +++ /dev/null @@ -1,99 +0,0 @@ -using AssetStoreTools.Api.Responses; -using System; -using System.Collections.Generic; -using System.IO; -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; - -namespace AssetStoreTools.Api -{ - internal class UnityPackageUploadSettings - { - public string VersionId { get; set; } - public string UnityPackagePath { get; set; } - public string RootGuid { get; set; } - public string RootPath { get; set; } - public string ProjectPath { get; set; } - } - - internal class UnityPackageUploader : PackageUploaderBase - { - private UnityPackageUploadSettings _settings; - private Uri _uploadUri; - - public UnityPackageUploader(UnityPackageUploadSettings settings) - { - _settings = settings; - } - - protected override void ValidateSettings() - { - if (string.IsNullOrEmpty(_settings.VersionId)) - throw new Exception("Version Id is unset"); - - if (string.IsNullOrEmpty(_settings.UnityPackagePath) - || !File.Exists(_settings.UnityPackagePath)) - throw new Exception("Package file could not be found"); - - if (!_settings.UnityPackagePath.EndsWith(".unitypackage")) - throw new Exception("Provided package file is not .unitypackage"); - } - - public override async Task Upload(IAssetStoreClient client, IProgress progress = null, CancellationToken cancellationToken = default) - { - try - { - ValidateSettings(); - - var endpoint = Constants.Api.UploadUnityPackageUrl(_settings.VersionId); - var query = new Dictionary() - { - { "root_guid", _settings.RootGuid }, - { "root_path", _settings.RootPath }, - { "project_path", _settings.ProjectPath } - }; - - _uploadUri = ApiUtility.CreateUri(endpoint, query, true); - } - catch (Exception e) - { - return new PackageUploadResponse() { Success = false, Status = UploadStatus.Fail, Exception = e }; - } - - return await Task.Run(() => UploadTask(client, progress, cancellationToken)); - } - - private PackageUploadResponse UploadTask(IAssetStoreClient client, IProgress progress, CancellationToken cancellationToken) - { - try - { - using (FileStream requestFileStream = new FileStream(_settings.UnityPackagePath, FileMode.Open, FileAccess.Read)) - { - var content = new StreamContent(requestFileStream, UploadChunkSizeBytes); - - var response = client.Put(_uploadUri, content, cancellationToken); - WaitForUploadCompletion(response, requestFileStream, progress, cancellationToken); - - cancellationToken.ThrowIfCancellationRequested(); - EnsureSuccessResponse(response.Result); - - var responseStr = response.Result.Content.ReadAsStringAsync().Result; - return new PackageUploadResponse(responseStr); - } - } - catch (OperationCanceledException e) - { - return new PackageUploadResponse() { Success = false, Cancelled = true, Status = UploadStatus.Cancelled, Exception = e }; - } - catch (TimeoutException e) - { - return new PackageUploadResponse() { Success = true, Status = UploadStatus.ResponseTimeout, Exception = e }; - } - catch (Exception e) - { - return new PackageUploadResponse() { Success = false, Exception = e, Status = UploadStatus.Fail }; - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/UnityPackageUploader.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/UnityPackageUploader.cs.meta deleted file mode 100644 index cbff3f3..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/UnityPackageUploader.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 95bd0284375397f41a2065e07d4ba526 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/UploadStatus.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/UploadStatus.cs deleted file mode 100644 index cc3adf4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/UploadStatus.cs +++ /dev/null @@ -1,11 +0,0 @@ -namespace AssetStoreTools.Api -{ - internal enum UploadStatus - { - Default = 0, - Success = 1, - Fail = 2, - Cancelled = 3, - ResponseTimeout = 4 - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/UploadStatus.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Api/UploadStatus.cs.meta deleted file mode 100644 index 3c25205..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Api/UploadStatus.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 0a121831a941cb64a8a9d21ca6fda9c3 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/AssemblyInfo.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/AssemblyInfo.cs deleted file mode 100644 index 81fbd08..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/AssemblyInfo.cs +++ /dev/null @@ -1,5 +0,0 @@ -using System.Runtime.CompilerServices; -[assembly: InternalsVisibleTo("AssetStoreTools.Tests")] -[assembly: InternalsVisibleTo("DynamicProxyGenAssembly2")] -[assembly: InternalsVisibleTo("ab-builder")] -[assembly: InternalsVisibleTo("Inspector-Editor")] diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/AssemblyInfo.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/AssemblyInfo.cs.meta deleted file mode 100644 index 972ae52..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/AssemblyInfo.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: ccfd7faf75ab3c74a98015e772288d86 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreTools.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreTools.cs deleted file mode 100644 index 373ac32..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreTools.cs +++ /dev/null @@ -1,82 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.UI; -using AssetStoreTools.Uploader; -using AssetStoreTools.Utility; -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.UI; -using System; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools -{ - internal static class AssetStoreTools - { - [MenuItem("Tools/Asset Store/Uploader", false, 0)] - public static void ShowAssetStoreToolsUploader() - { - Type inspectorType = Type.GetType("UnityEditor.InspectorWindow,UnityEditor.dll"); - var wnd = EditorWindow.GetWindow(inspectorType); - wnd.Show(); - } - - [MenuItem("Tools/Asset Store/Validator", false, 1)] - public static void ShowAssetStoreToolsValidator() - { - Type inspectorType = Type.GetType("UnityEditor.InspectorWindow,UnityEditor.dll"); - var wnd = EditorWindow.GetWindow(typeof(UploaderWindow), inspectorType); - wnd.Show(); - } - - public static void ShowAssetStoreToolsValidator(ValidationSettings settings, ValidationResult result) - { - ShowAssetStoreToolsValidator(); - EditorWindow.GetWindow().Load(settings, result); - } - - [MenuItem("Tools/Asset Store/Preview Generator", false, 2)] - public static void ShowAssetStoreToolsPreviewGenerator() - { - Type inspectorType = Type.GetType("UnityEditor.InspectorWindow,UnityEditor.dll"); - var wnd = EditorWindow.GetWindow(inspectorType); - wnd.Show(); - } - - public static void ShowAssetStoreToolsPreviewGenerator(PreviewGenerationSettings settings) - { - ShowAssetStoreToolsPreviewGenerator(); - EditorWindow.GetWindow().Load(settings); - } - - [MenuItem("Tools/Asset Store/Publisher Portal", false, 20)] - public static void OpenPublisherPortal() - { - Application.OpenURL("https://publisher.unity.com/"); - } - - [MenuItem("Tools/Asset Store/Submission Guidelines", false, 21)] - public static void OpenSubmissionGuidelines() - { - Application.OpenURL("https://assetstore.unity.com/publishing/submission-guidelines/"); - } - - [MenuItem("Tools/Asset Store/Provide Feedback", false, 22)] - public static void OpenFeedback() - { - Application.OpenURL("https://forum.unity.com/threads/new-asset-store-tools-version-coming-july-20th-2022.1310939/"); - } - - [MenuItem("Tools/Asset Store/Check for Updates", false, 45)] - public static void OpenUpdateChecker() - { - var wnd = EditorWindow.GetWindowWithRect(new Rect(Screen.width / 2, Screen.height / 2, 400, 150), true); - wnd.Show(); - } - - [MenuItem("Tools/Asset Store/Settings", false, 50)] - public static void OpenSettings() - { - ASToolsPreferencesProvider.OpenSettings(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreTools.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreTools.cs.meta deleted file mode 100644 index 9452bb0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreTools.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 6060eef206afc844caaa1732538e8890 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreToolsWindow.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreToolsWindow.cs deleted file mode 100644 index 43f3c11..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreToolsWindow.cs +++ /dev/null @@ -1,23 +0,0 @@ -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools -{ - internal abstract class AssetStoreToolsWindow : EditorWindow - { - protected abstract string WindowTitle { get; } - - private void DefaultInit() - { - titleContent = new GUIContent(WindowTitle); - Init(); - } - - protected abstract void Init(); - - private void OnEnable() - { - DefaultInit(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreToolsWindow.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreToolsWindow.cs.meta deleted file mode 100644 index 2fe87e5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/AssetStoreToolsWindow.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: c1057a05baaa45942808573065c02a03 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Constants.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Constants.cs deleted file mode 100644 index d2c777a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Constants.cs +++ /dev/null @@ -1,178 +0,0 @@ -using AssetStoreTools.Previews.Data; -using System; -using System.Collections.Generic; -using UnityEditor; -using UnityEngine; -using PackageInfo = UnityEditor.PackageManager.PackageInfo; - -namespace AssetStoreTools -{ - internal class Constants - { -#if UNITY_EDITOR_OSX - public static readonly string UnityPath = System.IO.Path.Combine(EditorApplication.applicationPath, "Contents", "MacOS", "Unity"); -#else - public static readonly string UnityPath = EditorApplication.applicationPath; -#endif - public static readonly string RootProjectPath = Application.dataPath.Substring(0, Application.dataPath.Length - "Assets".Length); - - private static bool GetArgument(string argumentName, out string argumentValue) - { - argumentValue = string.Empty; - var args = Environment.GetCommandLineArgs(); - - for (int i = 0; i < args.Length; i++) - { - if (!args[i].Equals(argumentName, StringComparison.OrdinalIgnoreCase)) - continue; - - if (i + 1 >= args.Length) - return false; - - argumentValue = args[i + 1]; - break; - } - - return !string.IsNullOrEmpty(argumentValue); - } - - public class Api - { - public static readonly string ApiVersion = $"V{PackageInfo.FindForAssetPath("Packages/com.unity.asset-store-tools").version}"; - public const string AssetStoreToolsLatestVersionUrl = "https://api.assetstore.unity3d.com/package/latest-version/115"; - - private const string AssetStoreBaseUrlDefault = "https://kharma.unity3d.com"; - private const string AssetStoreBaseUrlOverrideArgument = "-assetStoreUrl"; - public static readonly string AssetStoreBaseUrl = !GetArgument(AssetStoreBaseUrlOverrideArgument, out var overriddenUrl) - ? AssetStoreBaseUrlDefault - : overriddenUrl; - - public static readonly string AuthenticateUrl = $"{AssetStoreBaseUrl}/login"; - public static readonly string GetPackagesUrl = $"{AssetStoreBaseUrl}/api/asset-store-tools/metadata/0.json"; - public static readonly string GetPackagesAdditionalDataUrl = $"{AssetStoreBaseUrl}/api/management/packages.json"; - public static readonly string GetCategoriesUrl = $"{AssetStoreBaseUrl}/api/management/categories.json"; - - public static string GetPackageUploadedVersionsUrl(string packageId, string versionId) => - $"{AssetStoreBaseUrl}/api/content/preview/{packageId}/{versionId}.json"; - public static string UploadUnityPackageUrl(string versionId) => - $"{AssetStoreBaseUrl}/api/asset-store-tools/package/{versionId}/unitypackage.json"; - - public static IDictionary DefaultAssetStoreQuery() - { - var dict = new Dictionary() - { - { "unityversion", Application.unityVersion }, - { "toolversion", ApiVersion } - }; - return dict; - } - } - - public class Updater - { - public const string AssetStoreToolsUrl = "https://assetstore.unity.com/packages/tools/utilities/asset-store-publishing-tools-115"; - } - - public class Cache - { - public const string SessionTokenKey = "kharma.sessionid"; - public const string TempCachePath = "Temp/AssetStoreToolsCache"; - public const string PersistentCachePath = "Library/AssetStoreToolsCache"; - - public const string PackageDataFileName = "PackageMetadata.json"; - public const string CategoryDataFile = "Categories.json"; - public const string ValidationResultFile = "ValidationStateData.asset"; - - public static string PackageThumbnailFileName(string packageId) => $"{packageId}.png"; - public static string WorkflowStateDataFileName(string packageId) => $"{packageId}-workflowStateData.asset"; - } - - public class Uploader - { - public const string MinRequiredUnitySupportVersion = "2021.3"; - public const long MaxPackageSizeBytes = 6576668672; // 6 GB + 128MB of headroom - public const string AccountRegistrationUrl = "https://publisher.unity.com/access"; - public const string AccountForgottenPasswordUrl = "https://id.unity.com/password/new"; - - public class Analytics - { - public const string VendorKey = "unity.assetStoreTools"; - public const int MaxEventsPerHour = 20; - public const int MaxNumberOfElements = 1000; - - public class AuthenticationAnalytics - { - public const string EventName = "assetStoreToolsLogin"; - public const int EventVersion = 1; - } - - public class PackageUploadAnalytics - { - public const string EventName = "assetStoreTools"; - public const int EventVersion = 3; - } - } - } - - public class Validator - { - public const string SubmissionGuidelinesUrl = "https://assetstore.unity.com/publishing/submission-guidelines#Overview"; - public const string SupportTicketUrl = "https://support.unity.com/hc/en-us/requests/new?ticket_form_id=65905"; - - public class Tests - { - public const string TestDefinitionsPath = "Packages/com.unity.asset-store-tools/Editor/Validator/Tests"; - public const string TestMethodsPath = "Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods"; - - public static readonly string GenericTestMethodsPath = $"{TestMethodsPath}/Generic"; - public static readonly string UnityPackageTestMethodsPath = $"{TestMethodsPath}/UnityPackage"; - } - } - - public class Previews - { - public const string PreviewDatabaseFile = "PreviewDatabase.json"; - - public static readonly string DefaultOutputPath = $"{Cache.TempCachePath}/AssetPreviews"; - public const FileNameFormat DefaultFileNameFormat = FileNameFormat.Guid; - - public class Native - { - public static readonly string DefaultOutputPath = $"{Previews.DefaultOutputPath}/Native"; - public const PreviewFormat DefaultFormat = PreviewFormat.PNG; - public const bool DefaultWaitForPreviews = true; - public const bool DefaultChunkedPreviewLoading = true; - public const int DefaultChunkSize = 100; - } - - public class Custom - { - public static readonly string DefaultOutputPath = $"{Previews.DefaultOutputPath}/Custom"; - public const PreviewFormat DefaultFormat = PreviewFormat.JPG; - public const int DefaultWidth = 300; - public const int DefaultHeight = 300; - public const int DefaultDepth = 32; - - public const int DefaultNativeWidth = 900; - public const int DefaultNativeHeight = 900; - - public static readonly Color DefaultAudioSampleColor = new Color(1f, 0.55f, 0); - public static readonly Color DefaultAudioBackgroundColor = new Color(0.32f, 0.32f, 0.32f); - } - } - - public class WindowStyles - { - public const string UploaderStylesPath = "Packages/com.unity.asset-store-tools/Editor/Uploader/Styles"; - public const string ValidatorStylesPath = "Packages/com.unity.asset-store-tools/Editor/Validator/Styles"; - public const string ValidatorIconsPath = "Packages/com.unity.asset-store-tools/Editor/Validator/Icons"; - public const string PreviewGeneratorStylesPath = "Packages/com.unity.asset-store-tools/Editor/Previews/Styles"; - public const string UpdaterStylesPath = "Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater"; - } - - public class Debug - { - public const string DebugModeKey = "ASTDebugMode"; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Constants.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Constants.cs.meta deleted file mode 100644 index 682cecb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Constants.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a4ee1f78505bda748ae24b3dfd2606ca -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter.meta deleted file mode 100644 index 4e1143b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 5f5ca981958937a43997a9f365759edf -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions.meta deleted file mode 100644 index ac18e6c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 2072d354c04b19c48b22593536b3ebcf -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPackageExporter.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPackageExporter.cs deleted file mode 100644 index 0201a8e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPackageExporter.cs +++ /dev/null @@ -1,11 +0,0 @@ -using System.Threading.Tasks; - -namespace AssetStoreTools.Exporter -{ - internal interface IPackageExporter - { - PackageExporterSettings Settings { get; } - - Task Export(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPackageExporter.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPackageExporter.cs.meta deleted file mode 100644 index 91a3d96..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPackageExporter.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 41bc3a111ed1fd64c8b9acef211d9e51 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPreviewInjector.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPreviewInjector.cs deleted file mode 100644 index ba503d8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPreviewInjector.cs +++ /dev/null @@ -1,7 +0,0 @@ -namespace AssetStoreTools.Exporter -{ - internal interface IPreviewInjector - { - void Inject(string temporaryPackagePath); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPreviewInjector.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPreviewInjector.cs.meta deleted file mode 100644 index 534a5dd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/IPreviewInjector.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: dcff58dc716351f43b2709cfacdfebba -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterBase.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterBase.cs deleted file mode 100644 index 885a188..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterBase.cs +++ /dev/null @@ -1,134 +0,0 @@ -using AssetStoreTools.Utility; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Threading.Tasks; -using UnityEditor; - -namespace AssetStoreTools.Exporter -{ - internal abstract class PackageExporterBase : IPackageExporter - { - public PackageExporterSettings Settings { get; private set; } - - public const string ProgressBarTitle = "Exporting Package"; - public const string ProgressBarStepSavingAssets = "Saving Assets..."; - public const string ProgressBarStepGatheringFiles = "Gathering files..."; - public const string ProgressBarStepGeneratingPreviews = "Generating previews..."; - public const string ProgressBarStepCompressingPackage = "Compressing package..."; - - private static readonly string[] PluginFolderExtensions = { "androidlib", "bundle", "plugin", "framework", "xcframework" }; - - public PackageExporterBase(PackageExporterSettings settings) - { - Settings = settings; - } - - public async Task Export() - { - try - { - ValidateSettings(); - } - catch (Exception e) - { - return new PackageExporterResult() { Success = false, Exception = e }; - } - - return await ExportImpl(); - } - - protected virtual void ValidateSettings() - { - if (Settings == null) - throw new ArgumentException("Settings cannot be null"); - - if (string.IsNullOrEmpty(Settings.OutputFilename)) - throw new ArgumentException("Output path cannot be null"); - - if (Settings.OutputFilename.EndsWith("/") || Settings.OutputFilename.EndsWith("\\")) - throw new ArgumentException("Output path must be a valid filename and not end with a directory separator character"); - } - - protected abstract Task ExportImpl(); - - protected string[] GetAssetPaths(string rootPath) - { - // To-do: slight optimization is possible in the future by having a list of excluded folders/file extensions - List paths = new List(); - - // Add files within given directory - var filePaths = Directory.GetFiles(rootPath).Select(p => p.Replace('\\', '/')).ToArray(); - paths.AddRange(filePaths); - - // Add directories within given directory - var directoryPaths = Directory.GetDirectories(rootPath).Select(p => p.Replace('\\', '/')).ToArray(); - foreach (var nestedDirectory in directoryPaths) - paths.AddRange(GetAssetPaths(nestedDirectory)); - - // Add the given directory itself if it is not empty - if (filePaths.Length > 0 || directoryPaths.Length > 0) - paths.Add(rootPath); - - return paths.ToArray(); - } - - protected string GetAssetGuid(string assetPath, bool generateIfPlugin, bool scrapeFromMeta) - { - if (!FileUtility.ShouldHaveMeta(assetPath)) - return string.Empty; - - // Skip ProjectVersion.txt file specifically as it may introduce - // project compatibility issues when imported - if (string.Compare(assetPath, "ProjectSettings/ProjectVersion.txt", StringComparison.OrdinalIgnoreCase) == 0) - return string.Empty; - - // Attempt retrieving guid from the Asset Database first - var guid = AssetDatabase.AssetPathToGUID(assetPath); - if (guid != string.Empty) - return guid; - - // Some special folders (e.g. SomeName.framework) do not have meta files inside them. - // Their contents should be exported with any arbitrary GUID so that Unity Importer could pick them up - if (generateIfPlugin && PathBelongsToPlugin(assetPath)) - return GUID.Generate().ToString(); - - // Files in hidden folders (e.g. Samples~) are not part of the Asset Database, - // therefore GUIDs need to be scraped from the .meta file. - // Note: only do this for non-native exporter since the native exporter - // will not be able to retrieve the asset path from a hidden folder - if (scrapeFromMeta) - { - var metaPath = $"{assetPath}.meta"; - - if (!File.Exists(metaPath)) - return string.Empty; - - using (StreamReader reader = new StreamReader(metaPath)) - { - string line; - while ((line = reader.ReadLine()) != string.Empty) - { - if (!line.StartsWith("guid:")) - continue; - var metaGuid = line.Substring("guid:".Length).Trim(); - return metaGuid; - } - } - } - - return string.Empty; - } - - private bool PathBelongsToPlugin(string assetPath) - { - return PluginFolderExtensions.Any(extension => assetPath.ToLower().Contains($".{extension}/")); - } - - protected virtual void PostExportCleanup() - { - EditorUtility.ClearProgressBar(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterBase.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterBase.cs.meta deleted file mode 100644 index 1c88d87..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterBase.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: aab20a0b596e60b40b1f7f7e0f54858e -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterSettings.cs deleted file mode 100644 index 6197ba5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterSettings.cs +++ /dev/null @@ -1,7 +0,0 @@ -namespace AssetStoreTools.Exporter -{ - internal abstract class PackageExporterSettings - { - public string OutputFilename; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterSettings.cs.meta deleted file mode 100644 index 25ff427..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/Abstractions/PackageExporterSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 82c350daaabdc784e95e09cdc8511e23 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultExporterSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultExporterSettings.cs deleted file mode 100644 index 82a10ac..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultExporterSettings.cs +++ /dev/null @@ -1,11 +0,0 @@ -using AssetStoreTools.Previews.Generators; - -namespace AssetStoreTools.Exporter -{ - internal class DefaultExporterSettings : PackageExporterSettings - { - public string[] ExportPaths; - public string[] Dependencies; - public IPreviewGenerator PreviewGenerator; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultExporterSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultExporterSettings.cs.meta deleted file mode 100644 index 31644b1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultExporterSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 92cbd0e60b4bb9049bcf1e9fd92ccae6 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultPackageExporter.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultPackageExporter.cs deleted file mode 100644 index c8d6c42..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultPackageExporter.cs +++ /dev/null @@ -1,304 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Utility; -using Newtonsoft.Json.Linq; -using System; -using System.Collections.Generic; -using System.Diagnostics; -using System.IO; -using System.Linq; -using System.Threading.Tasks; -using UnityEditor; -using UnityEngine; -using CacheConstants = AssetStoreTools.Constants.Cache; - -namespace AssetStoreTools.Exporter -{ - internal class DefaultPackageExporter : PackageExporterBase - { - private const string TemporaryExportPathName = "CustomExport"; - - private DefaultExporterSettings _defaultExportSettings; - - public DefaultPackageExporter(DefaultExporterSettings settings) : base(settings) - { - _defaultExportSettings = settings; - } - - protected override void ValidateSettings() - { - base.ValidateSettings(); - - if (_defaultExportSettings.ExportPaths == null || _defaultExportSettings.ExportPaths.Length == 0) - throw new ArgumentException("Export paths array cannot be empty"); - } - - protected override async Task ExportImpl() - { - return await this.Export(); - } - - private new async Task Export() - { - ASDebug.Log("Using custom package exporter"); - - // Save assets before exporting - EditorUtility.DisplayProgressBar(ProgressBarTitle, ProgressBarStepSavingAssets, 0.1f); - AssetDatabase.SaveAssets(); - - try - { - // Create a temporary export path - PostExportCleanup(); - var temporaryExportPath = GetTemporaryExportPath(); - if (!Directory.Exists(temporaryExportPath)) - Directory.CreateDirectory(temporaryExportPath); - - // Construct an unzipped package structure - CreateTempPackageStructure(temporaryExportPath); - - var previewGenerationResult = await GeneratePreviews(); - InjectPreviews(previewGenerationResult, temporaryExportPath); - - // Build a .unitypackage file from the temporary folder - CreateUnityPackage(temporaryExportPath, _defaultExportSettings.OutputFilename); - - EditorUtility.RevealInFinder(_defaultExportSettings.OutputFilename); - - ASDebug.Log($"Package file has been created at {_defaultExportSettings.OutputFilename}"); - return new PackageExporterResult() { Success = true, ExportedPath = _defaultExportSettings.OutputFilename, PreviewGenerationResult = previewGenerationResult }; - } - catch (Exception e) - { - return new PackageExporterResult() { Success = false, Exception = e }; - } - finally - { - PostExportCleanup(); - } - } - - private string GetTemporaryExportPath() - { - return $"{CacheConstants.TempCachePath}/{TemporaryExportPathName}"; - } - - private void CreateTempPackageStructure(string tempOutputPath) - { - EditorUtility.DisplayProgressBar(ProgressBarTitle, ProgressBarStepGatheringFiles, 0.4f); - var pathGuidPairs = GetPathGuidPairs(_defaultExportSettings.ExportPaths); - - foreach (var pair in pathGuidPairs) - { - var originalAssetPath = pair.Key; - var outputAssetPath = $"{tempOutputPath}/{pair.Value}"; - - if (Directory.Exists(outputAssetPath)) - { - var path1 = File.ReadAllText($"{outputAssetPath}/pathname"); - var path2 = originalAssetPath; - throw new InvalidOperationException($"Multiple assets with guid {pair.Value} have been detected " + - $"when exporting the package. Please resolve the guid conflicts and try again:\n{path1}\n{path2}"); - } - - Directory.CreateDirectory(outputAssetPath); - - // Every exported asset has a pathname file - using (StreamWriter writer = new StreamWriter($"{outputAssetPath}/pathname")) - writer.Write(originalAssetPath); - - // Only files (not folders) have an asset file - if (File.Exists(originalAssetPath)) - File.Copy(originalAssetPath, $"{outputAssetPath}/asset"); - - // Most files and folders have an asset.meta file (but ProjectSettings folder assets do not) - if (File.Exists($"{originalAssetPath}.meta")) - File.Copy($"{originalAssetPath}.meta", $"{outputAssetPath}/asset.meta"); - - // To-do: handle previews in hidden folders as they are not part of the AssetDatabase - var previewObject = AssetDatabase.LoadAssetAtPath(originalAssetPath); - if (previewObject == null) - continue; - } - - if (_defaultExportSettings.Dependencies == null || _defaultExportSettings.Dependencies.Length == 0) - return; - - var exportDependenciesDict = new JObject(); - var allRegistryPackages = PackageUtility.GetAllRegistryPackages(); - - foreach (var exportDependency in _defaultExportSettings.Dependencies) - { - var registryPackage = allRegistryPackages.FirstOrDefault(x => x.name == exportDependency); - if (registryPackage == null) - { - // Package is either not from a registry source or does not exist in the project - UnityEngine.Debug.LogWarning($"Found an unsupported Package Manager dependency: {exportDependency}.\n" + - "This dependency is not supported in the project's manifest.json and will be skipped."); - continue; - } - - exportDependenciesDict[registryPackage.name] = registryPackage.version; - } - - if (exportDependenciesDict.Count == 0) - return; - - var exportManifestJson = new JObject(); - exportManifestJson["dependencies"] = exportDependenciesDict; - - var tempManifestDirectoryPath = $"{tempOutputPath}/packagemanagermanifest"; - Directory.CreateDirectory(tempManifestDirectoryPath); - var tempManifestFilePath = $"{tempManifestDirectoryPath}/asset"; - - File.WriteAllText(tempManifestFilePath, exportManifestJson.ToString()); - } - - private Dictionary GetPathGuidPairs(string[] exportPaths) - { - var pathGuidPairs = new Dictionary(); - - foreach (var exportPath in exportPaths) - { - var assetPaths = GetAssetPaths(exportPath); - - foreach (var assetPath in assetPaths) - { - var guid = GetAssetGuid(assetPath, true, true); - if (string.IsNullOrEmpty(guid)) - continue; - - pathGuidPairs.Add(assetPath, guid); - } - } - - return pathGuidPairs; - } - - private async Task GeneratePreviews() - { - if (_defaultExportSettings.PreviewGenerator == null) - return null; - - void ReportProgress(float progress) - { - EditorUtility.DisplayProgressBar(ProgressBarTitle, ProgressBarStepGeneratingPreviews, progress); - } - - _defaultExportSettings.PreviewGenerator.OnProgressChanged += ReportProgress; - var result = await _defaultExportSettings.PreviewGenerator.Generate(); - _defaultExportSettings.PreviewGenerator.OnProgressChanged -= ReportProgress; - EditorUtility.ClearProgressBar(); - - if (!result.Success) - { - UnityEngine.Debug.LogWarning($"An error was encountered while generating previews. Exported package may be missing previews.\n{result.Exception}"); - } - - return result; - } - - private void InjectPreviews(PreviewGenerationResult result, string temporaryExportPath) - { - if (result == null || !result.Success) - return; - - var injector = new PreviewInjector(result); - injector.Inject(temporaryExportPath); - } - - private void CreateUnityPackage(string pathToArchive, string outputPath) - { - if (Directory.GetDirectories(pathToArchive).Length == 0) - throw new InvalidOperationException("Unable to export package. The specified path is empty"); - - EditorUtility.DisplayProgressBar(ProgressBarTitle, ProgressBarStepCompressingPackage, 0.8f); - - // Archiving process working path will be set to the - // temporary package path so adjust the output path accordingly - if (!Path.IsPathRooted(outputPath)) - outputPath = $"{Application.dataPath.Substring(0, Application.dataPath.Length - "/Assets".Length)}/{outputPath}"; - -#if UNITY_EDITOR_WIN - CreateUnityPackageUniversal(pathToArchive, outputPath); -#elif UNITY_EDITOR_OSX || UNITY_EDITOR_LINUX - CreateUnityPackageOsxLinux(pathToArchive, outputPath); -#endif - } - - private void CreateUnityPackageUniversal(string pathToArchive, string outputPath) - { - var _7zPath = EditorApplication.applicationContentsPath; -#if UNITY_EDITOR_WIN - _7zPath = Path.Combine(_7zPath, "Tools", "7z.exe"); -#elif UNITY_EDITOR_OSX || UNITY_EDITOR_LINUX - _7zPath = Path.Combine(_7zPath, "Tools", "7za"); -#endif - if (!File.Exists(_7zPath)) - throw new FileNotFoundException("Archiving utility was not found in your Unity installation directory"); - - var argumentsTar = $"a -r -ttar -y -bd archtemp.tar ."; - var result = StartProcess(_7zPath, argumentsTar, pathToArchive); - if (result != 0) - throw new Exception("Failed to compress the package"); - - // Create a GZIP archive - var argumentsGzip = $"a -tgzip -bd -y \"{outputPath}\" archtemp.tar"; - result = StartProcess(_7zPath, argumentsGzip, pathToArchive); - if (result != 0) - throw new Exception("Failed to compress the package"); - } - -#if UNITY_EDITOR_OSX || UNITY_EDITOR_LINUX - private void CreateUnityPackageOsxLinux(string pathToArchive, string outputPath) - { - var tarPath = "/usr/bin/tar"; - - if (!File.Exists(tarPath)) - { - // Fallback to the universal export method - ASDebug.LogWarning("'/usr/bin/tar' executable not found. Falling back to 7za"); - CreateUnityPackageUniversal(pathToArchive, outputPath); - return; - } - - // Create a TAR archive - var arguments = $"-czpf \"{outputPath}\" ."; - var result = StartProcess(tarPath, arguments, pathToArchive); - if (result != 0) - throw new Exception("Failed to compress the package"); - } -#endif - - private int StartProcess(string processPath, string arguments, string workingDirectory) - { - var info = new ProcessStartInfo() - { - FileName = processPath, - Arguments = arguments, - WorkingDirectory = workingDirectory, - CreateNoWindow = true, - UseShellExecute = false - }; - -#if UNITY_EDITOR_OSX - // Prevent OSX-specific archive pollution - info.EnvironmentVariables.Add("COPYFILE_DISABLE", "1"); -#endif - - using (Process process = Process.Start(info)) - { - process.WaitForExit(); - return process.ExitCode; - } - } - - protected override void PostExportCleanup() - { - base.PostExportCleanup(); - - var tempExportPath = GetTemporaryExportPath(); - if (Directory.Exists(tempExportPath)) - Directory.Delete(tempExportPath, true); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultPackageExporter.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultPackageExporter.cs.meta deleted file mode 100644 index fa1bd63..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/DefaultPackageExporter.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 32f50122a1b2bc2428cf8fba321e2414 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyExporterSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyExporterSettings.cs deleted file mode 100644 index 52a7cad..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyExporterSettings.cs +++ /dev/null @@ -1,8 +0,0 @@ -namespace AssetStoreTools.Exporter -{ - internal class LegacyExporterSettings : PackageExporterSettings - { - public string[] ExportPaths; - public bool IncludeDependencies; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyExporterSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyExporterSettings.cs.meta deleted file mode 100644 index dbade08..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyExporterSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: c7dea1cfe45989e4eab6fc5fd18c1e10 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyPackageExporter.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyPackageExporter.cs deleted file mode 100644 index 1720043..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyPackageExporter.cs +++ /dev/null @@ -1,109 +0,0 @@ -using AssetStoreTools.Utility; -using System; -using System.Collections.Generic; -using System.IO; -using System.Reflection; -using System.Threading; -using System.Threading.Tasks; - -namespace AssetStoreTools.Exporter -{ - internal class LegacyPackageExporter : PackageExporterBase - { - private const string ExportMethodWithoutDependencies = "UnityEditor.PackageUtility.ExportPackage"; - private const string ExportMethodWithDependencies = "UnityEditor.PackageUtility.ExportPackageAndPackageManagerManifest"; - - private LegacyExporterSettings _legacyExportSettings; - - public LegacyPackageExporter(LegacyExporterSettings settings) : base(settings) - { - _legacyExportSettings = settings; - } - - protected override void ValidateSettings() - { - base.ValidateSettings(); - - if (_legacyExportSettings.ExportPaths == null || _legacyExportSettings.ExportPaths.Length == 0) - throw new ArgumentException("Export paths array cannot be empty"); - } - - protected override async Task ExportImpl() - { - return await this.Export(); - } - - private async new Task Export() - { - ASDebug.Log("Using native package exporter"); - - try - { - var guids = GetGuids(_legacyExportSettings.ExportPaths, out bool onlyFolders); - - if (guids.Length == 0 || onlyFolders) - throw new ArgumentException("Package Exporting failed: provided export paths are empty or only contain empty folders"); - - string exportMethod = ExportMethodWithoutDependencies; - if (_legacyExportSettings.IncludeDependencies) - exportMethod = ExportMethodWithDependencies; - - var split = exportMethod.Split('.'); - var assembly = Assembly.Load(split[0]); // UnityEditor - var typeName = $"{split[0]}.{split[1]}"; // UnityEditor.PackageUtility - var methodName = split[2]; // ExportPackage or ExportPackageAndPackageManagerManifest - - var type = assembly.GetType(typeName); - var method = type.GetMethod(methodName, BindingFlags.Static | BindingFlags.NonPublic | BindingFlags.Public, - null, new Type[] { typeof(string[]), typeof(string) }, null); - - ASDebug.Log("Invoking native export method"); - - method?.Invoke(null, new object[] { guids, _legacyExportSettings.OutputFilename }); - - // The internal exporter methods are asynchronous, therefore - // we need to wait for exporting to finish before returning - await Task.Run(() => - { - while (!File.Exists(_legacyExportSettings.OutputFilename)) - Thread.Sleep(100); - }); - - ASDebug.Log($"Package file has been created at {_legacyExportSettings.OutputFilename}"); - return new PackageExporterResult() { Success = true, ExportedPath = _legacyExportSettings.OutputFilename }; - } - catch (Exception e) - { - return new PackageExporterResult() { Success = false, Exception = e }; - } - finally - { - PostExportCleanup(); - } - } - - private string[] GetGuids(string[] exportPaths, out bool onlyFolders) - { - var guids = new List(); - onlyFolders = true; - - foreach (var exportPath in exportPaths) - { - var assetPaths = GetAssetPaths(exportPath); - - foreach (var assetPath in assetPaths) - { - var guid = GetAssetGuid(assetPath, false, false); - if (string.IsNullOrEmpty(guid)) - continue; - - guids.Add(guid); - if (onlyFolders == true && (File.Exists(assetPath))) - onlyFolders = false; - } - } - - return guids.ToArray(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyPackageExporter.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyPackageExporter.cs.meta deleted file mode 100644 index 853e472..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/LegacyPackageExporter.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 3200380dff2de104aa79620e4b41dc70 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PackageExporterResult.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PackageExporterResult.cs deleted file mode 100644 index a0ae7a5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PackageExporterResult.cs +++ /dev/null @@ -1,13 +0,0 @@ -using AssetStoreTools.Previews.Data; -using System; - -namespace AssetStoreTools.Exporter -{ - internal class PackageExporterResult - { - public bool Success; - public string ExportedPath; - public PreviewGenerationResult PreviewGenerationResult; - public Exception Exception; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PackageExporterResult.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PackageExporterResult.cs.meta deleted file mode 100644 index 840bcf6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PackageExporterResult.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: e685b1c322eab4540919d4fc970e812d -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PreviewInjector.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PreviewInjector.cs deleted file mode 100644 index 69e06da..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PreviewInjector.cs +++ /dev/null @@ -1,41 +0,0 @@ -using AssetStoreTools.Previews.Data; -using System.Collections.Generic; -using System.IO; -using System.Linq; - -namespace AssetStoreTools.Exporter -{ - internal class PreviewInjector : IPreviewInjector - { - private PreviewGenerationResult _result; - - public PreviewInjector(PreviewGenerationResult result) - { - _result = result; - } - - public void Inject(string temporaryPackagePath) - { - if (_result == null || !_result.Success) - return; - - var previews = _result.Previews.Where(x => x.Type == _result.GenerationType && x.Exists()); - InjectFilesIntoGuidFolders(previews, temporaryPackagePath); - } - - private void InjectFilesIntoGuidFolders(IEnumerable previews, string temporaryPackagePath) - { - foreach (var assetFolder in Directory.EnumerateDirectories(temporaryPackagePath)) - { - var guid = assetFolder.Replace("\\", "/").Split('/').Last(); - var generatedPreview = previews.FirstOrDefault(x => x.Guid.Equals(guid)); - - if (generatedPreview == null) - continue; - - // Note: Unity Importer and Asset Store only operate with .png extensions - File.Copy(generatedPreview.Path, $"{assetFolder}/preview.png", true); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PreviewInjector.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PreviewInjector.cs.meta deleted file mode 100644 index 98e155a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Exporter/PreviewInjector.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 772db784128e32d4792bb680258c71df -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews.meta deleted file mode 100644 index 747d5eb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 13e8cd63112e52d43a7e65949f0143a4 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts.meta deleted file mode 100644 index f95e49f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: cbe1aebea6551424997b361fab69f266 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data.meta deleted file mode 100644 index 89f1356..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: ae99e2e3b5a83d1469110306c96f4c58 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/CustomPreviewGenerationSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/CustomPreviewGenerationSettings.cs deleted file mode 100644 index 2705875..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/CustomPreviewGenerationSettings.cs +++ /dev/null @@ -1,19 +0,0 @@ -using UnityEngine; - -namespace AssetStoreTools.Previews.Data -{ - internal class CustomPreviewGenerationSettings : PreviewGenerationSettings - { - public override GenerationType GenerationType => GenerationType.Custom; - - public int Width; - public int Height; - public int Depth; - - public int NativeWidth; - public int NativeHeight; - - public Color AudioSampleColor; - public Color AudioBackgroundColor; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/CustomPreviewGenerationSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/CustomPreviewGenerationSettings.cs.meta deleted file mode 100644 index 38f9eba..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/CustomPreviewGenerationSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 2ccb1292c1c4ba94cb6f4022ecfdfa50 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/FileNameFormat.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/FileNameFormat.cs deleted file mode 100644 index cb841a8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/FileNameFormat.cs +++ /dev/null @@ -1,9 +0,0 @@ -namespace AssetStoreTools.Previews.Data -{ - internal enum FileNameFormat - { - Guid = 0, - FullAssetPath = 1, - AssetName = 2, - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/FileNameFormat.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/FileNameFormat.cs.meta deleted file mode 100644 index 9a6639f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/FileNameFormat.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 38a1babecfeaf524f98e8d67882acf48 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/GenerationType.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/GenerationType.cs deleted file mode 100644 index fef979f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/GenerationType.cs +++ /dev/null @@ -1,9 +0,0 @@ -namespace AssetStoreTools.Previews.Data -{ - internal enum GenerationType - { - Unknown = 0, - Native = 1, - Custom = 2 - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/GenerationType.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/GenerationType.cs.meta deleted file mode 100644 index f179123..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/GenerationType.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 66697a5d16404d948ba3191ddfc60bd9 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/NativePreviewGenerationSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/NativePreviewGenerationSettings.cs deleted file mode 100644 index fff204e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/NativePreviewGenerationSettings.cs +++ /dev/null @@ -1,10 +0,0 @@ -namespace AssetStoreTools.Previews.Data -{ - internal class NativePreviewGenerationSettings : PreviewGenerationSettings - { - public override GenerationType GenerationType => GenerationType.Native; - public bool WaitForPreviews; - public bool ChunkedPreviewLoading; - public int ChunkSize; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/NativePreviewGenerationSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/NativePreviewGenerationSettings.cs.meta deleted file mode 100644 index e3e7940..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/NativePreviewGenerationSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 5b2ef019acae6fe43b5565858e15433a -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewDatabase.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewDatabase.cs deleted file mode 100644 index cabc56c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewDatabase.cs +++ /dev/null @@ -1,14 +0,0 @@ -using System.Collections.Generic; - -namespace AssetStoreTools.Previews.Data -{ - internal class PreviewDatabase - { - public List Previews; - - public PreviewDatabase() - { - Previews = new List(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewDatabase.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewDatabase.cs.meta deleted file mode 100644 index fd55b05..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewDatabase.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: cf8cef28a68324742a7e4b47efc87563 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewFormat.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewFormat.cs deleted file mode 100644 index e68f29a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewFormat.cs +++ /dev/null @@ -1,8 +0,0 @@ -namespace AssetStoreTools.Previews.Data -{ - internal enum PreviewFormat - { - JPG = 0, - PNG = 1 - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewFormat.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewFormat.cs.meta deleted file mode 100644 index 0d8c214..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewFormat.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 0500e4459ebfe8448a13194af49f89fa -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationResult.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationResult.cs deleted file mode 100644 index 6fb7791..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationResult.cs +++ /dev/null @@ -1,14 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace AssetStoreTools.Previews.Data -{ - internal class PreviewGenerationResult - { - public GenerationType GenerationType; - public bool Success; - public IEnumerable GeneratedPreviews; - public IEnumerable Previews; - public Exception Exception; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationResult.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationResult.cs.meta deleted file mode 100644 index 7062382..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationResult.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: e040f2cdf0177824dacb158b23a63374 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationSettings.cs deleted file mode 100644 index 920ac13..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationSettings.cs +++ /dev/null @@ -1,12 +0,0 @@ -namespace AssetStoreTools.Previews.Data -{ - internal abstract class PreviewGenerationSettings - { - public abstract GenerationType GenerationType { get; } - public string[] InputPaths; - public string OutputPath; - public PreviewFormat Format; - public FileNameFormat PreviewFileNamingFormat; - public bool OverwriteExisting; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationSettings.cs.meta deleted file mode 100644 index 38563dc..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewGenerationSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 7e578ae6616505a4795da8f632d63229 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewMetadata.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewMetadata.cs deleted file mode 100644 index a7ba227..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewMetadata.cs +++ /dev/null @@ -1,17 +0,0 @@ -using System.IO; - -namespace AssetStoreTools.Previews.Data -{ - internal class PreviewMetadata - { - public GenerationType Type; - public string Guid; - public string Name; - public string Path; - - public bool Exists() - { - return File.Exists(Path); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewMetadata.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewMetadata.cs.meta deleted file mode 100644 index 2aed929..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Data/PreviewMetadata.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 4ff6be4e277d8314e921baff52ea25bc -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators.meta deleted file mode 100644 index 7019d5c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: ed651159a2004574789e97726da5090c -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom.meta deleted file mode 100644 index cac3d99..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: f675855c3d971694785806c0c7a463be -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannel.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannel.cs deleted file mode 100644 index f46e406..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannel.cs +++ /dev/null @@ -1,97 +0,0 @@ -using System.Collections.Generic; -using System.Linq; -using UnityEngine; - -namespace AssetStoreTools.Previews.Generators.Custom -{ - internal class AudioChannel - { - private int _yMin; - private int _yMax; - - private int _yBaseline; - private int _yAmplitude; - - private List _samples; - - public AudioChannel(int minY, int maxY, List samples) - { - _yMin = minY; - _yMax = maxY; - - _yBaseline = (_yMin + _yMax) / 2; - _yAmplitude = _yMax - _yBaseline; - - _samples = samples; - } - - public IEnumerable GetCoordinateData(int desiredWidth) - { - var coordinates = new List(); - var step = Mathf.RoundToInt((float)_samples.Count / desiredWidth); - - for (int i = 0; i < desiredWidth; i++) - { - var startIndex = i * step; - var endIndex = (i + 1) * step; - var sampleChunk = CreateChunk(startIndex, endIndex); - - if (sampleChunk.Count() == 0) - break; - - DownsampleMax(sampleChunk, out var aboveBaseline, out var belowBaseline); - - var yAboveBaseline = SampleToCoordinate(aboveBaseline); - var yBelowBaseline = SampleToCoordinate(belowBaseline); - - coordinates.Add(new AudioChannelCoordinate(i, _yBaseline, yAboveBaseline, yBelowBaseline)); - } - - // If there weren't enough samples to complete the desired width - fill out the rest with zeroes - for (int i = coordinates.Count; i < desiredWidth; i++) - coordinates.Add(new AudioChannelCoordinate(i, _yBaseline, 0, 0)); - - return coordinates; - } - - private IEnumerable CreateChunk(int startIndex, int endIndex) - { - var chunk = new List(); - for (int i = startIndex; i < endIndex; i++) - { - if (i >= _samples.Count) - break; - - chunk.Add(_samples[i]); - } - - return chunk; - } - - private void DownsampleMax(IEnumerable samples, out float valueAboveBaseline, out float valueBelowBaseline) - { - valueAboveBaseline = 0; - valueBelowBaseline = 0; - - foreach (var sample in samples) - { - if (sample > 0 && sample > valueAboveBaseline) - { - valueAboveBaseline = sample; - continue; - } - - if (sample < 0 && sample < valueBelowBaseline) - { - valueBelowBaseline = sample; - continue; - } - } - } - - private int SampleToCoordinate(float sample) - { - return _yBaseline + (int)(sample * _yAmplitude); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannel.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannel.cs.meta deleted file mode 100644 index 4a7d3fb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannel.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 82fab55b08a1be94cb2e18f3feae91ec -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannelCoordinate.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannelCoordinate.cs deleted file mode 100644 index 1030eed..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannelCoordinate.cs +++ /dev/null @@ -1,18 +0,0 @@ -namespace AssetStoreTools.Previews.Generators.Custom -{ - internal struct AudioChannelCoordinate - { - public int X { get; private set; } - public int YBaseline { get; private set; } - public int YAboveBaseline { get; private set; } - public int YBelowBaseline { get; private set; } - - public AudioChannelCoordinate(int x, int yBaseline, int yAboveBaseline, int yBelowBaseline) - { - X = x; - YBaseline = yBaseline; - YAboveBaseline = yAboveBaseline; - YBelowBaseline = yBelowBaseline; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannelCoordinate.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannelCoordinate.cs.meta deleted file mode 100644 index 9142554..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/AudioChannelCoordinate.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: b54462f6af82a2644944d6e4bde23c9e -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters.meta deleted file mode 100644 index 91cfc9f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: c07070deed666d54cb72a89a5fcd7ef7 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/ISceneScreenshotter.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/ISceneScreenshotter.cs deleted file mode 100644 index ec7cd57..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/ISceneScreenshotter.cs +++ /dev/null @@ -1,12 +0,0 @@ -using UnityEngine; - -namespace AssetStoreTools.Previews.Generators.Custom.Screenshotters -{ - internal interface ISceneScreenshotter - { - SceneScreenshotterSettings Settings { get; } - - string Screenshot(string outputPath); - string Screenshot(GameObject target, string outputPath); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/ISceneScreenshotter.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/ISceneScreenshotter.cs.meta deleted file mode 100644 index 1c18549..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/ISceneScreenshotter.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 045ac265a792af243918af0849ee2ac8 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MaterialScreenshotter.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MaterialScreenshotter.cs deleted file mode 100644 index a446208..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MaterialScreenshotter.cs +++ /dev/null @@ -1,32 +0,0 @@ -using UnityEngine; - -namespace AssetStoreTools.Previews.Generators.Custom.Screenshotters -{ - internal class MaterialScreenshotter : SceneScreenshotterBase - { - public MaterialScreenshotter(SceneScreenshotterSettings settings) : base(settings) { } - - public override void PositionCamera(GameObject target) - { - var renderers = target.GetComponentsInChildren(); - if (renderers == null || renderers.Length == 0) - return; - - var bounds = GetGlobalBounds(renderers); - - var materialSphereRadius = bounds.extents.y * 1.1f; - - var angle = Camera.fieldOfView / 2; - var sinAngle = Mathf.Sin(angle * Mathf.Deg2Rad); - var distance = materialSphereRadius / sinAngle; - - Camera.transform.position = new Vector3(bounds.center.x, bounds.center.y + distance, bounds.center.z); - Camera.transform.LookAt(bounds.center); - Camera.transform.RotateAround(bounds.center, Vector3.left, 60); - Camera.transform.RotateAround(bounds.center, Vector3.up, -45); - - Camera.nearClipPlane = 0.01f; - Camera.farClipPlane = 10000; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MaterialScreenshotter.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MaterialScreenshotter.cs.meta deleted file mode 100644 index 9c07505..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MaterialScreenshotter.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: c2bd7b01b0cebeb43a6fbc53377f0ea6 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MeshScreenshotter.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MeshScreenshotter.cs deleted file mode 100644 index 6ce5905..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MeshScreenshotter.cs +++ /dev/null @@ -1,33 +0,0 @@ -using UnityEngine; - -namespace AssetStoreTools.Previews.Generators.Custom.Screenshotters -{ - internal class MeshScreenshotter : SceneScreenshotterBase - { - public MeshScreenshotter(SceneScreenshotterSettings settings) : base(settings) { } - - public override void PositionCamera(GameObject target) - { - var renderers = target.GetComponentsInChildren(); - if (renderers == null || renderers.Length == 0) - return; - - var bounds = GetGlobalBounds(renderers); - - var encapsulatingSphereDiameter = (bounds.max - bounds.min).magnitude; - var encapsulatingSphereRadius = encapsulatingSphereDiameter / 2; - - var angle = Camera.fieldOfView / 2; - var sinAngle = Mathf.Sin(angle * Mathf.Deg2Rad); - var distance = encapsulatingSphereRadius / sinAngle; - - Camera.transform.position = new Vector3(bounds.center.x, bounds.center.y + distance, bounds.center.z); - Camera.transform.LookAt(bounds.center); - Camera.transform.RotateAround(bounds.center, Vector3.left, 65); - Camera.transform.RotateAround(bounds.center, Vector3.up, 235); - - Camera.nearClipPlane = 0.01f; - Camera.farClipPlane = 10000; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MeshScreenshotter.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MeshScreenshotter.cs.meta deleted file mode 100644 index 660fb06..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/MeshScreenshotter.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: f0339d22d91b7c94ebc18b1de6f1e287 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterBase.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterBase.cs deleted file mode 100644 index fb289f4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterBase.cs +++ /dev/null @@ -1,124 +0,0 @@ -using AssetStoreTools.Previews.Utility; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using UnityEngine; - -namespace AssetStoreTools.Previews.Generators.Custom.Screenshotters -{ - internal abstract class SceneScreenshotterBase : ISceneScreenshotter - { - public SceneScreenshotterSettings Settings { get; } - - protected Camera Camera => GetCamera(); - private Camera _camera; - - public SceneScreenshotterBase(SceneScreenshotterSettings settings) - { - Settings = settings; - } - - private Camera GetCamera() - { - if (_camera == null) - { -#if UNITY_2022_3_OR_NEWER - _camera = GameObject.FindFirstObjectByType(FindObjectsInactive.Include); -#else - _camera = GameObject.FindObjectOfType(); -#endif - } - - return _camera; - } - - public virtual void ValidateSettings() - { - if (Settings.Width <= 0) - throw new ArgumentException("Width should be larger than 0"); - - if (Settings.Height <= 0) - throw new ArgumentException("Height should be larger than 0"); - - if (Settings.Depth <= 0) - throw new ArgumentException("Depth should be larger than 0"); - - if (Settings.NativeWidth <= 0) - throw new ArgumentException("Native width should be larger than 0"); - - if (Settings.NativeHeight <= 0) - throw new ArgumentException("Native height should be larger than 0"); - } - - public abstract void PositionCamera(GameObject target); - - public string Screenshot(string outputPath) - { - ValidateSettings(); - - var texture = GraphicsUtility.GetTextureFromCamera(Camera, Settings.NativeWidth, Settings.NativeHeight, Settings.Depth); - - if (Settings.Width < Settings.NativeWidth || Settings.Height < Settings.NativeHeight) - texture = GraphicsUtility.ResizeTexture(texture, Settings.Width, Settings.Height); - - var extension = PreviewConvertUtility.ConvertExtension(Settings.Format); - var writtenPath = $"{outputPath}.{extension}"; - var bytes = PreviewConvertUtility.ConvertTexture(texture, Settings.Format); - File.WriteAllBytes(writtenPath, bytes); - - return writtenPath; - } - - public string Screenshot(GameObject target, string outputPath) - { - PositionCamera(target); - PositionLighting(target); - return Screenshot(outputPath); - } - - private void PositionLighting(GameObject target) - { -#if UNITY_2022_3_OR_NEWER - var light = GameObject.FindFirstObjectByType(FindObjectsInactive.Include); -#else - var light = GameObject.FindObjectOfType(); -#endif - light.transform.position = Camera.transform.position; - light.transform.LookAt(target.transform); - light.transform.RotateAround(target.transform.position, Vector3.forward, 60f); - } - - protected Bounds GetGlobalBounds(IEnumerable renderers) - { - var center = Vector3.zero; - - foreach (var renderer in renderers) - { - center += renderer.bounds.center; - } - center /= renderers.Count(); - - var globalBounds = new Bounds(center, Vector3.zero); - - foreach (var renderer in renderers) - { - globalBounds.Encapsulate(renderer.bounds); - } - - return globalBounds; - } - - protected Bounds GetNormalizedBounds(Bounds bounds) - { - var largestExtent = Mathf.Max(bounds.extents.x, bounds.extents.y, bounds.extents.z); - var normalizedBounds = new Bounds() - { - center = bounds.center, - extents = new Vector3(largestExtent, largestExtent, largestExtent) - }; - - return normalizedBounds; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterBase.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterBase.cs.meta deleted file mode 100644 index adab09f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterBase.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: ce77aefdce8a37f498d17d73da53d0a4 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterSettings.cs deleted file mode 100644 index 82e0ec1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterSettings.cs +++ /dev/null @@ -1,16 +0,0 @@ -using AssetStoreTools.Previews.Data; - -namespace AssetStoreTools.Previews.Generators.Custom.Screenshotters -{ - internal class SceneScreenshotterSettings - { - public int Width; - public int Height; - public int Depth; - - public int NativeWidth; - public int NativeHeight; - - public PreviewFormat Format; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterSettings.cs.meta deleted file mode 100644 index c152cef..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/Screenshotters/SceneScreenshotterSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: aa34806e243bad949892d06dd47295e2 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators.meta deleted file mode 100644 index e13d726..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: b4bb2dd0960418d4a8d4efd34b92a418 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypeGeneratorSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypeGeneratorSettings.cs deleted file mode 100644 index 36a6b21..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypeGeneratorSettings.cs +++ /dev/null @@ -1,15 +0,0 @@ -using AssetStoreTools.Previews.Data; -using UnityEngine; - -namespace AssetStoreTools.Previews.Generators.Custom.TypeGenerators -{ - internal class AudioTypeGeneratorSettings : TypeGeneratorSettings - { - public int Width; - public int Height; - - public Color SampleColor; - public Color BackgroundColor; - public PreviewFormat Format; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypeGeneratorSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypeGeneratorSettings.cs.meta deleted file mode 100644 index 22aa253..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypeGeneratorSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 5b7ab1b072d95be4daf221ee23af1c80 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypePreviewGenerator.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypePreviewGenerator.cs deleted file mode 100644 index a0f1545..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypePreviewGenerator.cs +++ /dev/null @@ -1,207 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.Utility; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Threading.Tasks; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Previews.Generators.Custom.TypeGenerators -{ - internal class AudioTypePreviewGenerator : TypePreviewGeneratorBase - { - private AudioTypeGeneratorSettings _settings; - private Texture2D _texture; - - public override event Action OnAssetProcessed; - - public AudioTypePreviewGenerator(AudioTypeGeneratorSettings settings) : base(settings) - { - _settings = settings; - } - - public override void ValidateSettings() - { - base.ValidateSettings(); - - if (_settings.Width <= 0) - throw new ArgumentException("Width must be larger than 0"); - - if (_settings.Height <= 0) - throw new ArgumentException("Height must be larger than 0"); - } - - protected override IEnumerable CollectAssets() - { - var assets = new List(); - var materialGuids = AssetDatabase.FindAssets("t:audioclip", Settings.InputPaths); - foreach (var guid in materialGuids) - { - var audioClip = AssetDatabase.LoadAssetAtPath(AssetDatabase.GUIDToAssetPath(guid)); - - // Skip nested audio clips - if (!AssetDatabase.IsMainAsset(audioClip)) - continue; - - // Skip materials with an error shader - if (!IsLoadTypeSupported(audioClip)) - { - Debug.LogWarning($"Audio clip '{audioClip}' is using a load type which cannot retrieve sample data. Preview will not be generated."); - continue; - } - - assets.Add(audioClip); - } - - return assets; - } - - private bool IsLoadTypeSupported(AudioClip audioClip) - { - if (audioClip.loadType == AudioClipLoadType.DecompressOnLoad) - return true; - - return false; - } - - protected override async Task> GenerateImpl(IEnumerable assets) - { - var generatedPreviews = new List(); - var audioClips = assets.ToList(); - for (int i = 0; i < audioClips.Count; i++) - { - var audioClip = audioClips[i] as AudioClip; - if (audioClip != null) - { - var texture = GenerateAudioClipTexture(audioClip); - - var outputPath = GenerateOutputPathWithExtension(audioClip, _settings.PreviewFileNamingFormat, _settings.Format); - var bytes = PreviewConvertUtility.ConvertTexture(texture, _settings.Format); - File.WriteAllBytes(outputPath, bytes); - generatedPreviews.Add(ObjectToMetadata(audioClip, outputPath)); - } - - OnAssetProcessed?.Invoke(i, audioClips.Count); - await Task.Yield(); - } - - return generatedPreviews; - } - - private Texture2D GenerateAudioClipTexture(AudioClip audioClip) - { - if (!audioClip.LoadAudioData()) - throw new Exception("Could not load audio data"); - - try - { - if (_texture == null) - _texture = new Texture2D(_settings.Width, _settings.Height); - else -#if UNITY_2021_3_OR_NEWER || UNITY_2022_1_OR_NEWER || UNITY_2021_2_OR_NEWER - _texture.Reinitialize(_settings.Width, _settings.Height); -#else - _texture.Resize(_settings.Width, _settings.Height); -#endif - - FillTextureBackground(); - FillTextureForeground(audioClip); - - _texture.Apply(); - return _texture; - } - finally - { - audioClip.UnloadAudioData(); - } - } - - private void FillTextureBackground() - { - for (int i = 0; i < _texture.width; i++) - { - for (int j = 0; j < _texture.height; j++) - { - _texture.SetPixel(i, j, _settings.BackgroundColor); - } - } - } - - private void FillTextureForeground(AudioClip audioClip) - { - var channels = CreateChannels(audioClip); - - for (int i = 0; i < channels.Count; i++) - { - DrawChannel(channels[i]); - } - } - - private List CreateChannels(AudioClip audioClip) - { - var channelSamples = GetChannelSamples(audioClip); - var sectionSize = _texture.height / audioClip.channels; - - var channels = new List(); - - for (int i = 0; i < audioClip.channels; i++) - { - var channelMaxY = (_texture.height - 1) - i * sectionSize; - var channelMinY = _texture.height - (i + 1) * sectionSize; - var channel = new AudioChannel(channelMinY, channelMaxY, channelSamples[i]); - channels.Add(channel); - } - - return channels; - } - - private List> GetChannelSamples(AudioClip audioClip) - { - var channelSamples = new List>(); - var allSamples = new float[audioClip.samples * audioClip.channels]; - - if (!audioClip.GetData(allSamples, 0)) - throw new Exception("Could not retrieve audio samples"); - - for (int i = 0; i < audioClip.channels; i++) - { - var samples = new List(); - var sampleIndex = i; - while (sampleIndex < allSamples.Length) - { - samples.Add(allSamples[sampleIndex]); - sampleIndex += audioClip.channels; - } - - channelSamples.Add(samples); - } - - return channelSamples; - } - - private void DrawChannel(AudioChannel channel) - { - var sectionData = channel.GetCoordinateData(_texture.width); - - foreach (var data in sectionData) - { - DrawVerticalColumn(data.X, data.YBaseline, data.YAboveBaseline, data.YBelowBaseline, _settings.SampleColor); - } - } - - private void DrawVerticalColumn(int x, int yBaseline, int y1, int y2, Color color) - { - _texture.SetPixel(x, yBaseline, color); - - var startIndex = y1 < y2 ? y1 : y2; - var endIndex = y1 < y2 ? y2 : y1; - - for (int i = startIndex; i < endIndex; i++) - { - _texture.SetPixel(x, i, color); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypePreviewGenerator.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypePreviewGenerator.cs.meta deleted file mode 100644 index 0511663..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/AudioTypePreviewGenerator.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 9ddf69bb2dca51a42aff247b3a471bb3 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ITypePreviewGenerator.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ITypePreviewGenerator.cs deleted file mode 100644 index bdd5056..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ITypePreviewGenerator.cs +++ /dev/null @@ -1,16 +0,0 @@ -using AssetStoreTools.Previews.Data; -using System; -using System.Collections.Generic; -using System.Threading.Tasks; - -namespace AssetStoreTools.Previews.Generators.Custom.TypeGenerators -{ - internal interface ITypePreviewGenerator - { - TypeGeneratorSettings Settings { get; } - - event Action OnAssetProcessed; - - Task> Generate(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ITypePreviewGenerator.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ITypePreviewGenerator.cs.meta deleted file mode 100644 index a42ecd1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ITypePreviewGenerator.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 7d9cd368dc73a23478390ee1332cb0be -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/MaterialTypePreviewGenerator.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/MaterialTypePreviewGenerator.cs deleted file mode 100644 index 13b44ec..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/MaterialTypePreviewGenerator.cs +++ /dev/null @@ -1,85 +0,0 @@ -using AssetStoreTools.Previews.Data; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Previews.Generators.Custom.TypeGenerators -{ - internal class MaterialTypePreviewGenerator : TypePreviewGeneratorFromScene - { - public override event Action OnAssetProcessed; - - public MaterialTypePreviewGenerator(TypePreviewGeneratorFromSceneSettings settings) : base(settings) { } - - protected override IEnumerable CollectAssets() - { - var assets = new List(); - var materialGuids = AssetDatabase.FindAssets("t:material", Settings.InputPaths); - foreach (var guid in materialGuids) - { - var mat = AssetDatabase.LoadAssetAtPath(AssetDatabase.GUIDToAssetPath(guid)); - - // Skip nested materials - if (!AssetDatabase.IsMainAsset(mat)) - continue; - - // Skip materials with an error shader - if (IsShaderInvalid(mat.shader)) - { - Debug.LogWarning($"Material '{mat}' is using an erroring shader. Preview will not be generated."); - continue; - } - - assets.Add(mat); - } - - return assets; - } - - protected override async Task> GeneratePreviewsInScene(IEnumerable assets) - { - var generatedPreviews = new List(); - var materials = assets.ToList(); - var sphere = GameObject.CreatePrimitive(PrimitiveType.Sphere); - - var hasMeshRenderer = sphere.TryGetComponent(out var meshRenderer); - if (!hasMeshRenderer) - throw new Exception($"Could not find a MeshRenderer for {sphere}"); - - for (int i = 0; i < materials.Count; i++) - { - ThrowIfSceneChanged(); - - var material = materials[i] as Material; - - if (material != null) - { - meshRenderer.sharedMaterial = material; - var previewPath = Settings.Screenshotter.Screenshot(sphere, GenerateOutputPathWithoutExtension(material, Settings.PreviewFileNamingFormat)); - if (!string.IsNullOrEmpty(previewPath)) - generatedPreviews.Add(ObjectToMetadata(material, previewPath)); - } - - OnAssetProcessed?.Invoke(i, materials.Count); - await Task.Yield(); - } - - UnityEngine.Object.DestroyImmediate(sphere); - return generatedPreviews; - } - - private bool IsShaderInvalid(Shader shader) - { - if (ShaderUtil.ShaderHasError(shader)) - return true; - - if (!shader.isSupported) - return true; - - return false; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/MaterialTypePreviewGenerator.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/MaterialTypePreviewGenerator.cs.meta deleted file mode 100644 index c692df7..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/MaterialTypePreviewGenerator.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a4e121bae63a199458e53a523dd18c8c -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ModelTypePreviewGenerator.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ModelTypePreviewGenerator.cs deleted file mode 100644 index 7d97607..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ModelTypePreviewGenerator.cs +++ /dev/null @@ -1,86 +0,0 @@ -using AssetStoreTools.Previews.Data; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Previews.Generators.Custom.TypeGenerators -{ - internal class ModelTypePreviewGenerator : TypePreviewGeneratorFromScene - { - public override event Action OnAssetProcessed; - - public ModelTypePreviewGenerator(TypePreviewGeneratorFromSceneSettings settings) : base(settings) { } - - protected override IEnumerable CollectAssets() - { - var models = new List(); - var modelGuids = AssetDatabase.FindAssets("t:model", Settings.InputPaths); - - foreach (var guid in modelGuids) - { - var model = AssetDatabase.LoadAssetAtPath(AssetDatabase.GUIDToAssetPath(guid)); - - // Skip nested models - if (!AssetDatabase.IsMainAsset(model)) - continue; - - // Skip models without renderers - if (model.GetComponentsInChildren().Length == 0) - continue; - - models.Add(model); - } - - return models; - } - - protected override async Task> GeneratePreviewsInScene(IEnumerable assets) - { - var generatedPreviews = new List(); - var models = assets.ToList(); - var referenceShader = GetDefaultObjectShader(); - - for (int i = 0; i < models.Count; i++) - { - ThrowIfSceneChanged(); - - var model = models[i] as GameObject; - - if (model != null) - { - var go = UnityEngine.Object.Instantiate(model, Vector3.zero, Quaternion.Euler(0, 0, 0)); - ReplaceShaders(go, referenceShader); - - var previewPath = Settings.Screenshotter.Screenshot(go, GenerateOutputPathWithoutExtension(model, Settings.PreviewFileNamingFormat)); - if (!string.IsNullOrEmpty(previewPath)) - generatedPreviews.Add(ObjectToMetadata(model, previewPath)); - - UnityEngine.Object.DestroyImmediate(go); - } - - OnAssetProcessed?.Invoke(i, models.Count); - await Task.Yield(); - } - - return generatedPreviews; - } - - private void ReplaceShaders(GameObject go, Shader shader) - { - var meshRenderers = go.GetComponentsInChildren(); - foreach (var mr in meshRenderers) - { - var materialArray = mr.sharedMaterials; - for (int i = 0; i < materialArray.Length; i++) - { - materialArray[i] = new Material(shader) { color = new Color(0.7f, 0.7f, 0.7f) }; - } - - mr.sharedMaterials = materialArray; - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ModelTypePreviewGenerator.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ModelTypePreviewGenerator.cs.meta deleted file mode 100644 index 72c41d0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/ModelTypePreviewGenerator.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: fca8a1fa8a211874cb84d3d811a0158c -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/PrefabTypePreviewGenerator.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/PrefabTypePreviewGenerator.cs deleted file mode 100644 index f0eeb6b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/PrefabTypePreviewGenerator.cs +++ /dev/null @@ -1,113 +0,0 @@ -using AssetStoreTools.Previews.Data; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Previews.Generators.Custom.TypeGenerators -{ - internal class PrefabTypePreviewGenerator : TypePreviewGeneratorFromScene - { - public override event Action OnAssetProcessed; - - public PrefabTypePreviewGenerator(TypePreviewGeneratorFromSceneSettings settings) : base(settings) { } - - protected override IEnumerable CollectAssets() - { - var prefabs = new List(); - var prefabGuids = AssetDatabase.FindAssets("t:prefab", Settings.InputPaths); - - foreach (var guid in prefabGuids) - { - var prefab = AssetDatabase.LoadAssetAtPath(AssetDatabase.GUIDToAssetPath(guid)); - - // Skip nested prefabs - if (!AssetDatabase.IsMainAsset(prefab)) - continue; - - // Skip prefabs without renderers - if (prefab.GetComponentsInChildren().Length == 0) - continue; - - prefabs.Add(prefab); - } - - return prefabs; - } - - protected override async Task> GeneratePreviewsInScene(IEnumerable assets) - { - var generatedPreviews = new List(); - var prefabs = assets.ToList(); - var objectReferenceShader = GetDefaultObjectShader(); - var particleReferenceShader = GetDefaultParticleShader(); - - for (int i = 0; i < prefabs.Count; i++) - { - ThrowIfSceneChanged(); - - var prefab = prefabs[i] as GameObject; - if (prefab != null) - { - var go = UnityEngine.Object.Instantiate(prefab, Vector3.zero, Quaternion.Euler(0, 0, 0)); - - ReplaceMissingShaders(go, objectReferenceShader, particleReferenceShader); - - HandleParticleSystems(go); - - var previewPath = Settings.Screenshotter.Screenshot(go, GenerateOutputPathWithoutExtension(prefab, Settings.PreviewFileNamingFormat)); - if (!string.IsNullOrEmpty(previewPath)) - generatedPreviews.Add(ObjectToMetadata(prefab, previewPath)); - - UnityEngine.Object.DestroyImmediate(go); - } - - OnAssetProcessed?.Invoke(i, prefabs.Count); - await Task.Yield(); - } - - return generatedPreviews; - } - - private void ReplaceMissingShaders(GameObject go, Shader objectShader, Shader particleShader) - { - var meshRenderers = go.GetComponentsInChildren(); - foreach (var mr in meshRenderers) - { - var shaderToUse = mr is ParticleSystemRenderer ? particleShader : objectShader; - - var materialArray = mr.sharedMaterials; - for (int i = 0; i < materialArray.Length; i++) - { - if (materialArray[i] == null) - { - materialArray[i] = new Material(shaderToUse); - } - else if (!materialArray[i].shader.isSupported) - { - materialArray[i].shader = shaderToUse; - } - } - - mr.sharedMaterials = materialArray; - } - } - - private void HandleParticleSystems(GameObject go) - { - var particleSystems = go.GetComponentsInChildren(); - if (particleSystems.Length == 0) - return; - - foreach (var ps in particleSystems) - { - ps.Stop(); - ps.Clear(); - ps.randomSeed = 1; - ps.Simulate(10, false, true, false); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/PrefabTypePreviewGenerator.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/PrefabTypePreviewGenerator.cs.meta deleted file mode 100644 index 61b31c1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/PrefabTypePreviewGenerator.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 24b15b10bc361c84581f46cb6dd644cc -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypeGeneratorSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypeGeneratorSettings.cs deleted file mode 100644 index 666b32d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypeGeneratorSettings.cs +++ /dev/null @@ -1,11 +0,0 @@ -using AssetStoreTools.Previews.Data; - -namespace AssetStoreTools.Previews.Generators.Custom.TypeGenerators -{ - internal class TextureTypeGeneratorSettings : TypeGeneratorSettings - { - public int MaxWidth; - public int MaxHeight; - public PreviewFormat Format; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypeGeneratorSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypeGeneratorSettings.cs.meta deleted file mode 100644 index 29385d1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypeGeneratorSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 058d746982619b04eb5e200363003899 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypePreviewGenerator.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypePreviewGenerator.cs deleted file mode 100644 index 24e1102..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypePreviewGenerator.cs +++ /dev/null @@ -1,116 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.Utility; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Threading.Tasks; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Previews.Generators.Custom.TypeGenerators -{ - internal class TextureTypePreviewGenerator : TypePreviewGeneratorBase - { - private TextureTypeGeneratorSettings _settings; - - public override event Action OnAssetProcessed; - - public TextureTypePreviewGenerator(TextureTypeGeneratorSettings settings) : base(settings) - { - _settings = settings; - } - - public override void ValidateSettings() - { - base.ValidateSettings(); - - if (_settings.MaxWidth <= 0) - throw new ArgumentException("Max width should be larger than 0"); - - if (_settings.MaxHeight <= 0) - throw new ArgumentException("Max height should be larger than 0"); - } - - protected override IEnumerable CollectAssets() - { - var textures = new List(); - var textureGuids = AssetDatabase.FindAssets("t:texture", Settings.InputPaths); - - foreach (var guid in textureGuids) - { - var texture = AssetDatabase.LoadAssetAtPath(AssetDatabase.GUIDToAssetPath(guid)); - - // Skip nested textures - if (!AssetDatabase.IsMainAsset(texture)) - continue; - - textures.Add(texture); - } - - return textures; - } - - protected override async Task> GenerateImpl(IEnumerable assets) - { - var generatedPreviews = new List(); - var textures = assets.ToList(); - - for (int i = 0; i < textures.Count; i++) - { - var texture = textures[i] as Texture2D; - - if (texture != null) - { - Texture2D resizedTexture; - CalculateTextureSize(texture, out var resizeWidth, out var resizeHeight); - - var importer = AssetImporter.GetAtPath(AssetDatabase.GetAssetPath(texture)) as TextureImporter; - if (importer != null && importer.textureType == TextureImporterType.NormalMap) - resizedTexture = GraphicsUtility.ResizeTextureNormalMap(texture, resizeWidth, resizeHeight); - else - resizedTexture = GraphicsUtility.ResizeTexture(texture, resizeWidth, resizeHeight); - - var previewPath = GenerateOutputPathWithExtension(texture, _settings.PreviewFileNamingFormat, _settings.Format); - - // Some textures may be transparent and need to be encoded as PNG to look correctly - var targetFormat = texture.alphaIsTransparency ? PreviewFormat.PNG : _settings.Format; - var bytes = PreviewConvertUtility.ConvertTexture(resizedTexture, targetFormat); - - File.WriteAllBytes(previewPath, bytes); - generatedPreviews.Add(ObjectToMetadata(texture, previewPath)); - } - - OnAssetProcessed?.Invoke(i, textures.Count); - await Task.Yield(); - } - - return generatedPreviews; - } - - private void CalculateTextureSize(Texture2D texture, out int width, out int height) - { - if (texture.width <= _settings.MaxWidth && texture.height <= _settings.MaxHeight) - { - width = texture.width; - height = texture.height; - return; - } - - var widthLongerThanHeight = texture.width > texture.height; - - if (widthLongerThanHeight) - { - var ratio = (float)texture.width / texture.height; - width = _settings.MaxWidth; - height = Mathf.RoundToInt(width / ratio); - } - else - { - var ratio = (float)texture.height / texture.width; - height = _settings.MaxHeight; - width = Mathf.RoundToInt(height / ratio); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypePreviewGenerator.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypePreviewGenerator.cs.meta deleted file mode 100644 index cbe7491..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TextureTypePreviewGenerator.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: b04f55867ee575c489803356220feb31 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypeGeneratorSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypeGeneratorSettings.cs deleted file mode 100644 index 1aaaa42..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypeGeneratorSettings.cs +++ /dev/null @@ -1,12 +0,0 @@ -using AssetStoreTools.Previews.Data; - -namespace AssetStoreTools.Previews.Generators.Custom.TypeGenerators -{ - internal abstract class TypeGeneratorSettings - { - public string[] InputPaths; - public string[] IgnoredGuids; - public string OutputPath; - public FileNameFormat PreviewFileNamingFormat; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypeGeneratorSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypeGeneratorSettings.cs.meta deleted file mode 100644 index 4c24cf5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypeGeneratorSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a224a4b41a8c7cf4cb53dd77d6f2518b -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorBase.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorBase.cs deleted file mode 100644 index a49d968..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorBase.cs +++ /dev/null @@ -1,126 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.Utility; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Threading.Tasks; -using UnityEditor; - -namespace AssetStoreTools.Previews.Generators.Custom.TypeGenerators -{ - internal abstract class TypePreviewGeneratorBase : ITypePreviewGenerator - { - public TypeGeneratorSettings Settings { get; } - - public abstract event Action OnAssetProcessed; - - public TypePreviewGeneratorBase(TypeGeneratorSettings settings) - { - Settings = settings; - } - - public virtual void ValidateSettings() - { - if (Settings.InputPaths == null || Settings.InputPaths.Length == 0) - throw new ArgumentException("Input path cannot be null"); - - foreach (var path in Settings.InputPaths) - { - var inputPath = path.EndsWith("/") ? path.Remove(path.Length - 1) : path; - if (!AssetDatabase.IsValidFolder(inputPath)) - throw new ArgumentException($"Input path '{inputPath}' is not a valid ADB folder"); - } - - if (string.IsNullOrEmpty(Settings.OutputPath)) - throw new ArgumentException("Output path cannot be null"); - } - - public async Task> Generate() - { - var generatedPreviews = new List(); - ValidateSettings(); - - var assets = CollectAssets(); - assets = FilterIgnoredAssets(assets); - - if (assets.Count() == 0) - return generatedPreviews; - - return await GenerateImpl(assets); - } - - protected abstract IEnumerable CollectAssets(); - - private IEnumerable FilterIgnoredAssets(IEnumerable assets) - { - if (Settings.IgnoredGuids == null || Settings.IgnoredGuids.Length == 0) - return assets; - - var filteredAssets = new List(); - foreach (var asset in assets) - { - if (!AssetDatabase.TryGetGUIDAndLocalFileIdentifier(asset, out var guid, out long _)) - continue; - - if (Settings.IgnoredGuids.Any(x => x == guid)) - continue; - - filteredAssets.Add(asset); - } - - return filteredAssets; - } - - protected abstract Task> GenerateImpl(IEnumerable assets); - - protected PreviewMetadata ObjectToMetadata(UnityEngine.Object obj, string previewPath) - { - if (!AssetDatabase.TryGetGUIDAndLocalFileIdentifier(obj, out var guid, out long _)) - throw new Exception($"Could not retrieve guid for object {obj}"); - - return new PreviewMetadata() - { - Type = GenerationType.Custom, - Guid = guid, - Name = obj.name, - Path = previewPath - }; - } - - protected string GenerateOutputPathWithoutExtension(UnityEngine.Object asset, FileNameFormat fileNameFormat) - { - PrepareOutputFolder(Settings.OutputPath, false); - var directoryPath = Settings.OutputPath; - var fileName = PreviewConvertUtility.ConvertFilename(asset, fileNameFormat); - var fullPath = $"{directoryPath}/{fileName}"; - - return fullPath; - } - - protected string GenerateOutputPathWithExtension(UnityEngine.Object asset, FileNameFormat fileNameFormat, PreviewFormat previewFormat) - { - var partialOutputPath = GenerateOutputPathWithoutExtension(asset, fileNameFormat); - var extension = PreviewConvertUtility.ConvertExtension(previewFormat); - - return $"{partialOutputPath}.{extension}"; - } - - private void PrepareOutputFolder(string outputPath, bool cleanup) - { - var dir = new DirectoryInfo(outputPath); - - if (!dir.Exists) - { - dir.Create(); - return; - } - - if (!cleanup) - return; - - dir.Delete(true); - dir.Create(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorBase.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorBase.cs.meta deleted file mode 100644 index 7e751c2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorBase.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: c6fb2d639232bce4698338a252f47f3c -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromScene.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromScene.cs deleted file mode 100644 index f9fe453..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromScene.cs +++ /dev/null @@ -1,111 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.Utility; -using System; -using System.Collections.Generic; -using System.Threading; -using System.Threading.Tasks; -using UnityEditor.SceneManagement; -using UnityEngine; -using UnityEngine.SceneManagement; - -namespace AssetStoreTools.Previews.Generators.Custom.TypeGenerators -{ - internal abstract class TypePreviewGeneratorFromScene : TypePreviewGeneratorBase - { - protected new TypePreviewGeneratorFromSceneSettings Settings; - - private CancellationTokenSource _cancellationTokenSource; - - public TypePreviewGeneratorFromScene(TypePreviewGeneratorFromSceneSettings settings) : base(settings) - { - Settings = settings; - } - - public override void ValidateSettings() - { - base.ValidateSettings(); - - if (Settings.Screenshotter == null) - throw new ArgumentException("Screenshotter cannot be null"); - } - - protected sealed override async Task> GenerateImpl(IEnumerable assets) - { - var originalScenePath = EditorSceneManager.GetActiveScene().path; - await PreviewSceneUtility.OpenPreviewSceneForCurrentPipeline(); - - try - { - _cancellationTokenSource = new CancellationTokenSource(); - EditorSceneManager.sceneOpened += SceneOpenedDuringGeneration; - return await GeneratePreviewsInScene(assets); - } - finally - { - EditorSceneManager.sceneOpened -= SceneOpenedDuringGeneration; - _cancellationTokenSource.Dispose(); - if (!string.IsNullOrEmpty(originalScenePath)) - EditorSceneManager.OpenScene(originalScenePath); - } - } - - protected abstract Task> GeneratePreviewsInScene(IEnumerable assets); - - private void SceneOpenedDuringGeneration(Scene _, OpenSceneMode __) - { - if (!_cancellationTokenSource.IsCancellationRequested) - _cancellationTokenSource.Cancel(); - } - - protected void ThrowIfSceneChanged() - { - if (_cancellationTokenSource.Token.IsCancellationRequested) - throw new Exception("Preview generation was aborted due to a change of the scene"); - } - - protected Shader GetDefaultObjectShader() - { - switch (RenderPipelineUtility.GetCurrentPipeline()) - { - case RenderPipeline.BiRP: - return Shader.Find("Standard"); - case RenderPipeline.URP: - return Shader.Find("Universal Render Pipeline/Lit"); - case RenderPipeline.HDRP: - return Shader.Find("HDRP/Lit"); - default: - throw new NotImplementedException("Undefined Render Pipeline"); - } - } - - protected Shader GetDefaultParticleShader() - { - switch (RenderPipelineUtility.GetCurrentPipeline()) - { - case RenderPipeline.BiRP: - return Shader.Find("Particles/Standard Unlit"); - case RenderPipeline.URP: - return Shader.Find("Universal Render Pipeline/Particles/Unlit"); - case RenderPipeline.HDRP: - return Shader.Find("HDRP/Unlit"); - default: - throw new NotImplementedException("Undefined Render Pipeline"); - } - } - - protected Shader GetDefaultTextureShader() - { - switch (RenderPipelineUtility.GetCurrentPipeline()) - { - case RenderPipeline.BiRP: - return Shader.Find("Unlit/Texture"); - case RenderPipeline.URP: - return Shader.Find("Universal Render Pipeline/Unlit"); - case RenderPipeline.HDRP: - return Shader.Find("HDRP/Unlit"); - default: - throw new NotImplementedException("Undefined Render Pipeline"); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromScene.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromScene.cs.meta deleted file mode 100644 index fcc5e57..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromScene.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 1bf0eb8d7ef65f340be785dae96e4b73 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromSceneSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromSceneSettings.cs deleted file mode 100644 index 36a2e6e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromSceneSettings.cs +++ /dev/null @@ -1,9 +0,0 @@ -using AssetStoreTools.Previews.Generators.Custom.Screenshotters; - -namespace AssetStoreTools.Previews.Generators.Custom.TypeGenerators -{ - internal class TypePreviewGeneratorFromSceneSettings : TypeGeneratorSettings - { - public ISceneScreenshotter Screenshotter; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromSceneSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromSceneSettings.cs.meta deleted file mode 100644 index ead93bd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/Custom/TypeGenerators/TypePreviewGeneratorFromSceneSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a6b871798f99ad44d9fca46789239ec1 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/CustomPreviewGenerator.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/CustomPreviewGenerator.cs deleted file mode 100644 index 7a1ffeb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/CustomPreviewGenerator.cs +++ /dev/null @@ -1,213 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.Generators; -using AssetStoreTools.Previews.Generators.Custom.Screenshotters; -using AssetStoreTools.Previews.Generators.Custom.TypeGenerators; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; -using UnityEditor; - -namespace AssetStoreTools.Previews -{ - internal class CustomPreviewGenerator : PreviewGeneratorBase - { - private CustomPreviewGenerationSettings _customSettings; - - public override event Action OnProgressChanged; - - public CustomPreviewGenerator(CustomPreviewGenerationSettings settings) - : base(settings) - { - _customSettings = settings; - } - - protected override void Validate() - { - base.Validate(); - - if (_customSettings.Width <= 0) - throw new ArgumentException("Width should be larger than 0"); - - if (_customSettings.Height <= 0) - throw new ArgumentException("Height should be larger than 0"); - - if (_customSettings.Depth <= 0) - throw new ArgumentException("Depth should be larger than 0"); - - if (_customSettings.NativeWidth <= 0) - throw new ArgumentException("Native width should be larger than 0"); - - if (_customSettings.NativeHeight <= 0) - throw new ArgumentException("Native height should be larger than 0"); - } - - protected override async Task GenerateImpl() - { - var result = new PreviewGenerationResult() - { - GenerationType = _customSettings.GenerationType - }; - - OnProgressChanged?.Invoke(0f); - - var generatedPreviews = new List(); - var existingPreviews = GetExistingPreviews(); - var generators = CreateGenerators(existingPreviews); - - var currentGenerator = 0; - Action generatorProgressCallback = null; - generatorProgressCallback = (currentAsset, totalAssets) => ReportProgress(currentGenerator, generators.Count(), currentAsset, totalAssets); - - try - { - foreach (var generator in generators) - { - generator.OnAssetProcessed += generatorProgressCallback; - var typeGeneratorPreviews = await generator.Generate(); - generatedPreviews.AddRange(typeGeneratorPreviews); - currentGenerator++; - } - - AssetDatabase.Refresh(); - - var allPreviews = new List(); - allPreviews.AddRange(generatedPreviews); - allPreviews.AddRange(existingPreviews); - - result.Success = true; - result.GeneratedPreviews = generatedPreviews; - result.Previews = allPreviews; - } - catch (Exception e) - { - result.Success = false; - result.Exception = e; - } - finally - { - foreach (var generator in generators) - generator.OnAssetProcessed -= generatorProgressCallback; - } - - return result; - } - - private IEnumerable GetExistingPreviews() - { - var existingPreviews = new List(); - - if (Settings.OverwriteExisting || !CachingService.GetCachedMetadata(out var database)) - return existingPreviews; - - var inputGuids = AssetDatabase.FindAssets("", _customSettings.InputPaths); - existingPreviews = database.Previews.Where(x => x.Type == GenerationType.Custom && x.Exists() && inputGuids.Any(y => y.Equals(x.Guid))).ToList(); - return existingPreviews; - } - - private IEnumerable CreateGenerators(IEnumerable existingPreviews) - { - var ignoredGuids = existingPreviews.Select(x => x.Guid).ToArray(); - - var generators = new ITypePreviewGenerator[] - { - CreateAudioPreviewGenerator(ignoredGuids), - CreateMaterialPreviewGenerator(ignoredGuids), - CreateModelPreviewGenerator(ignoredGuids), - CreatePrefabPreviewGenerator(ignoredGuids), - CreateTexturePreviewGenerator(ignoredGuids) - }; - - return generators; - } - - private ITypePreviewGenerator CreateAudioPreviewGenerator(string[] ignoredGuids) - { - var settings = new AudioTypeGeneratorSettings() - { - Width = _customSettings.Width, - Height = _customSettings.Height, - InputPaths = _customSettings.InputPaths, - OutputPath = _customSettings.OutputPath, - PreviewFileNamingFormat = _customSettings.PreviewFileNamingFormat, - Format = _customSettings.Format, - SampleColor = _customSettings.AudioSampleColor, - BackgroundColor = _customSettings.AudioBackgroundColor, - IgnoredGuids = ignoredGuids - }; - - return new AudioTypePreviewGenerator(settings); - } - - private ITypePreviewGenerator CreateMaterialPreviewGenerator(string[] ignoredGuids) - { - var settings = CreateSceneGeneratorSettings(new MaterialScreenshotter(CreateScreenshotterSettings()), ignoredGuids); - return new MaterialTypePreviewGenerator(settings); - } - - private ITypePreviewGenerator CreateModelPreviewGenerator(string[] ignoredGuids) - { - var settings = CreateSceneGeneratorSettings(new MeshScreenshotter(CreateScreenshotterSettings()), ignoredGuids); - return new ModelTypePreviewGenerator(settings); - } - - private ITypePreviewGenerator CreatePrefabPreviewGenerator(string[] ignoredGuids) - { - var settings = CreateSceneGeneratorSettings(new MeshScreenshotter(CreateScreenshotterSettings()), ignoredGuids); - return new PrefabTypePreviewGenerator(settings); - } - - private ITypePreviewGenerator CreateTexturePreviewGenerator(string[] ignoredGuids) - { - var settings = new TextureTypeGeneratorSettings() - { - MaxWidth = _customSettings.Width, - MaxHeight = _customSettings.Height, - InputPaths = _customSettings.InputPaths, - OutputPath = _customSettings.OutputPath, - Format = _customSettings.Format, - PreviewFileNamingFormat = _customSettings.PreviewFileNamingFormat, - IgnoredGuids = ignoredGuids - }; - - return new TextureTypePreviewGenerator(settings); - } - - private TypePreviewGeneratorFromSceneSettings CreateSceneGeneratorSettings(ISceneScreenshotter screenshotter, string[] ignoredGuids) - { - var settings = new TypePreviewGeneratorFromSceneSettings() - { - InputPaths = _customSettings.InputPaths, - OutputPath = _customSettings.OutputPath, - PreviewFileNamingFormat = _customSettings.PreviewFileNamingFormat, - Screenshotter = screenshotter, - IgnoredGuids = ignoredGuids - }; - - return settings; - } - - private SceneScreenshotterSettings CreateScreenshotterSettings() - { - var settings = new SceneScreenshotterSettings() - { - Width = _customSettings.Width, - Height = _customSettings.Height, - Depth = _customSettings.Depth, - Format = _customSettings.Format, - NativeWidth = _customSettings.NativeWidth, - NativeHeight = _customSettings.NativeHeight, - }; - - return settings; - } - - private void ReportProgress(int currentGenerator, int totalGenerators, int currentGeneratorAsset, int totalCurrentGeneratorAssets) - { - var completedGeneratorProgress = (float)currentGenerator / totalGenerators; - var currentGeneratorProgress = ((float)currentGeneratorAsset / totalCurrentGeneratorAssets) / totalGenerators; - var progressToReport = completedGeneratorProgress + currentGeneratorProgress; - OnProgressChanged?.Invoke(progressToReport); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/CustomPreviewGenerator.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/CustomPreviewGenerator.cs.meta deleted file mode 100644 index e10c56c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/CustomPreviewGenerator.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: e5906f8cb3e4eec489a2f7a82844bb3f -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/IPreviewGenerator.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/IPreviewGenerator.cs deleted file mode 100644 index b548baf..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/IPreviewGenerator.cs +++ /dev/null @@ -1,15 +0,0 @@ -using AssetStoreTools.Previews.Data; -using System; -using System.Threading.Tasks; - -namespace AssetStoreTools.Previews.Generators -{ - internal interface IPreviewGenerator - { - PreviewGenerationSettings Settings { get; } - - event Action OnProgressChanged; - - Task Generate(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/IPreviewGenerator.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/IPreviewGenerator.cs.meta deleted file mode 100644 index e379870..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/IPreviewGenerator.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: ebddaccb94ca6e34aa36b535d0a47249 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/NativePreviewGenerator.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/NativePreviewGenerator.cs deleted file mode 100644 index 760e2d1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/NativePreviewGenerator.cs +++ /dev/null @@ -1,362 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.Utility; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Reflection; -using System.Threading.Tasks; -using UnityEditor; -using UnityEngine; -using UnityEngine.Tilemaps; - -namespace AssetStoreTools.Previews.Generators -{ - internal class NativePreviewGenerator : PreviewGeneratorBase - { - private const double InitialPreviewLoadingTimeoutSeconds = 10; - - private NativePreviewGenerationSettings _nativeSettings; - - private RenderTexture _renderTexture; - - private int _generatedPreviewsCount; - private int _totalPreviewsCount; - - public override event Action OnProgressChanged; - - public NativePreviewGenerator(NativePreviewGenerationSettings settings) - : base(settings) - { - _nativeSettings = settings; - } - - protected override void Validate() - { - base.Validate(); - - if (_nativeSettings.ChunkSize <= 0) - throw new ArgumentException("Chunk size must be larger than 0"); - } - - protected override async Task GenerateImpl() - { - var result = new PreviewGenerationResult() - { - GenerationType = _nativeSettings.GenerationType - }; - - OnProgressChanged?.Invoke(0f); - - try - { - var objects = GetObjectsRequiringPreviews(_nativeSettings.InputPaths); - var filteredObjects = new List(); - var reusedPreviews = new List(); - FilterObjects(objects, filteredObjects, reusedPreviews); - - _generatedPreviewsCount = 0; - _totalPreviewsCount = objects.Count; - - Directory.CreateDirectory(_nativeSettings.OutputPath); - - var generatedPreviews = new List(); - if (!_nativeSettings.WaitForPreviews) - { - WritePreviewsWithoutWaiting(filteredObjects, out generatedPreviews); - } - else - { - if (_nativeSettings.ChunkedPreviewLoading) - { - await WaitAndWritePreviewsChunked(filteredObjects, generatedPreviews); - } - else - { - await WaitAndWritePreviews(filteredObjects, generatedPreviews); - } - } - - var allPreviews = new List(); - allPreviews.AddRange(generatedPreviews); - allPreviews.AddRange(reusedPreviews); - - result.Success = true; - result.GeneratedPreviews = generatedPreviews; - result.Previews = allPreviews; - } - catch (Exception e) - { - result.Success = false; - result.Exception = e; - } - - return result; - } - - private List GetObjectsRequiringPreviews(string[] inputPaths) - { - var objects = new List(); - var guids = AssetDatabase.FindAssets("", inputPaths); - - foreach (var guid in guids) - { - if (objects.Any(x => x.Guid == guid)) - continue; - - var assetPath = AssetDatabase.GUIDToAssetPath(guid); - var obj = AssetDatabase.LoadAssetAtPath(assetPath); - if (!ShouldHavePreview(obj)) - continue; - - objects.Add(new PreviewMetadata() { Type = GenerationType.Native, Guid = guid }); - } - - return objects; - } - - private void FilterObjects(List objects, List filteredObjects, List reusedPreviews) - { - if (Settings.OverwriteExisting || !CachingService.GetCachedMetadata(out var database)) - { - filteredObjects.AddRange(objects); - return; - } - - foreach (var obj in objects) - { - var matchingEntry = database.Previews.FirstOrDefault(x => - x.Guid == obj.Guid - && x.Type == GenerationType.Native - && x.Exists()); - - if (matchingEntry == null) - { - filteredObjects.Add(obj); - } - else - { - reusedPreviews.Add(matchingEntry); - } - } - } - - private bool ShouldHavePreview(UnityEngine.Object asset) - { - if (asset == null) - return false; - - if (!AssetDatabase.IsMainAsset(asset)) - return false; - - switch (asset) - { - case AudioClip _: - case Material _: - case Mesh _: - case TerrainLayer _: - case Texture _: - case Tile _: - return true; - case GameObject go: - var renderers = go.GetComponentsInChildren(); - return renderers != null && renderers.Length > 0; - default: - return false; - } - } - - private PreviewMetadata WritePreviewToDisk(PreviewMetadata metadata, Texture2D texture) - { - var asset = AssetDatabase.LoadAssetAtPath(AssetDatabase.GUIDToAssetPath(metadata.Guid)); - var width = Mathf.Min(texture.width, 128); - var height = Mathf.Min(texture.height, 128); - var readableTexture = GraphicsUtility.ResizeTexture(texture, width, height); - var fileName = PreviewConvertUtility.ConvertFilenameWithExtension(asset, _nativeSettings.PreviewFileNamingFormat, _nativeSettings.Format); - var filePath = $"{_nativeSettings.OutputPath}/{fileName}"; - var bytes = PreviewConvertUtility.ConvertTexture(readableTexture, _nativeSettings.Format); - - File.WriteAllBytes(filePath, bytes); - - metadata.Type = GenerationType.Native; - metadata.Name = asset.name; - metadata.Path = filePath; - - return metadata; - } - - private void WritePreviewsWithoutWaiting(List objects, out List generatedPreviews) - { - generatedPreviews = new List(); - - foreach (var obj in objects) - { - var texture = GetAssetPreviewFromGuid(obj.Guid); - if (texture == null) - continue; - - var generatedPreview = WritePreviewToDisk(obj, texture); - generatedPreviews.Add(generatedPreview); - } - } - - private Texture2D GetAssetPreviewFromGuid(string guid) - { - var method = typeof(AssetPreview).GetMethod("GetAssetPreviewFromGUID", BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Static, null, new[] { typeof(string) }, null); - var args = new object[] { guid }; - - return method?.Invoke(null, args) as Texture2D; - } - - private async Task WaitAndWritePreviewsChunked(List objects, List generatedPreviews) - { - var chunks = objects.Count / _nativeSettings.ChunkSize; - var remainder = objects.Count % _nativeSettings.ChunkSize; - if (remainder != 0) - chunks += 1; - - for (int i = 0; i < chunks; i++) - { - var chunkObjects = new List(); - - for (int j = 0; j < _nativeSettings.ChunkSize; j++) - { - var index = i * _nativeSettings.ChunkSize + j; - if (index == objects.Count) - break; - - chunkObjects.Add(objects[index]); - } - - var generatedPreviewsChunk = new List(); - await WaitAndWritePreviews(chunkObjects, generatedPreviewsChunk); - generatedPreviews.AddRange(generatedPreviewsChunk); - } - } - - private async Task WaitAndWritePreviews(List objects, List generatedPreviews) - { - var initialObjectCount = objects.Count(); - if (initialObjectCount == 0) - return; - - await WaitAndWritePreviewIteration(objects, generatedPreviews); - var remainingObjectCount = objects.Count; - - // First iteration may take longer to start loading objects - var firstIterationStartTime = EditorApplication.timeSinceStartup; - while (true) - { - if (remainingObjectCount < initialObjectCount) - break; - - if (EditorApplication.timeSinceStartup - firstIterationStartTime > InitialPreviewLoadingTimeoutSeconds) - throw new Exception("Preview loading timed out."); - - await WaitAndWritePreviewIteration(objects, generatedPreviews); - remainingObjectCount = objects.Count; - } - - if (remainingObjectCount == 0) - return; - - while (true) - { - await WaitForEndOfFrame(1); - await WaitAndWritePreviewIteration(objects, generatedPreviews); - - // If no more previews are being loaded, try one more time before quitting - if (objects.Count == remainingObjectCount) - { - await WaitForEndOfFrame(1); - await WaitAndWritePreviewIteration(objects, generatedPreviews); - - if (objects.Count == remainingObjectCount) - { - var missingObjects = string.Join("\n", objects.Select(x => AssetDatabase.GUIDToAssetPath(x.Guid))); - Debug.LogWarning($"Unity Editor failed to fetch previews for {objects.Count} objects:\n{missingObjects}"); - break; - } - } - - remainingObjectCount = objects.Count; - - // Exit when all previews are loaded - if (remainingObjectCount == 0) - break; - } - } - - private async Task WaitAndWritePreviewIteration(List objects, List generatedPreviews) - { - var cacheSize = Mathf.Max(_nativeSettings.ChunkSize * 2, objects.Count() + _nativeSettings.ChunkSize); - AssetPreview.SetPreviewTextureCacheSize(cacheSize); - - // Initial queueing - foreach (var obj in objects) - { - var asset = AssetDatabase.LoadAssetAtPath(AssetDatabase.GUIDToAssetPath(obj.Guid)); - AssetPreview.GetAssetPreview(asset); - } - - await WaitForEndOfFrame(); - - // Waiting (NOTE: works inconsistently across Unity streams) - foreach (var obj in objects) - { - var asset = AssetDatabase.LoadAssetAtPath(AssetDatabase.GUIDToAssetPath(obj.Guid)); - if (AssetPreview.IsLoadingAssetPreview(asset.GetInstanceID())) - { - await WaitForEndOfFrame(); - } - } - - // Writing - for (int i = 0; i < objects.Count; i++) - { - var obj = objects[i]; - - var asset = AssetDatabase.LoadAssetAtPath(AssetDatabase.GUIDToAssetPath(obj.Guid)); - var texture = AssetPreview.GetAssetPreview(asset); - if (texture == null) - continue; - - WritePreviewToDisk(obj, texture); - generatedPreviews.Add(obj); - _generatedPreviewsCount++; - OnProgressChanged?.Invoke((float)_generatedPreviewsCount / _totalPreviewsCount); - } - - // Removing written objects from the list - for (int i = objects.Count - 1; i >= 0; i--) - { - if (objects[i].Exists()) - objects.RemoveAt(i); - } - } - - private async Task WaitForEndOfFrame(double atLeastSeconds) - { - var startTime = EditorApplication.timeSinceStartup; - while (EditorApplication.timeSinceStartup - startTime <= atLeastSeconds) - { - await WaitForEndOfFrame(); - } - } - - private async Task WaitForEndOfFrame() - { - var isNextFrame = false; - EditorApplication.CallbackFunction callback = null; - callback = () => - { - EditorApplication.update -= callback; - isNextFrame = true; - }; - - EditorApplication.update += callback; - while (!isNextFrame) - await Task.Yield(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/NativePreviewGenerator.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/NativePreviewGenerator.cs.meta deleted file mode 100644 index 5a59e84..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/NativePreviewGenerator.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: dd6eeb2f97a2ed34db51ab5ac0b3ffa1 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/PreviewGeneratorBase.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/PreviewGeneratorBase.cs deleted file mode 100644 index 02d779d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/PreviewGeneratorBase.cs +++ /dev/null @@ -1,45 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.Services; -using System; -using System.Threading.Tasks; - -namespace AssetStoreTools.Previews.Generators -{ - internal abstract class PreviewGeneratorBase : IPreviewGenerator - { - public PreviewGenerationSettings Settings { get; } - protected ICachingService CachingService; - - public abstract event Action OnProgressChanged; - - public PreviewGeneratorBase(PreviewGenerationSettings settings) - { - Settings = settings; - CachingService = PreviewServiceProvider.Instance.GetService(); - } - - public async Task Generate() - { - Validate(); - - var result = await GenerateImpl(); - if (result.Success) - { - CachingService.CacheMetadata(result.GeneratedPreviews); - } - - return result; - } - - protected virtual void Validate() - { - if (Settings.InputPaths == null || Settings.InputPaths.Length == 0) - throw new ArgumentException("Input paths cannot be null"); - - if (string.IsNullOrEmpty(Settings.OutputPath)) - throw new ArgumentException("Output path cannot be null"); - } - - protected abstract Task GenerateImpl(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/PreviewGeneratorBase.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/PreviewGeneratorBase.cs.meta deleted file mode 100644 index 0369b2b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Generators/PreviewGeneratorBase.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: cedf01448e0edcc4fb55f19f2e92b740 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services.meta deleted file mode 100644 index 55ebe0c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: aa18c820f185bfc4d8cd59e3418e2c4e -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching.meta deleted file mode 100644 index 449835a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: eb61a60f2ff91a448a7808ef2a25f871 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/CachingService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/CachingService.cs deleted file mode 100644 index 10bb448..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/CachingService.cs +++ /dev/null @@ -1,87 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Utility; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Text; - -namespace AssetStoreTools.Previews.Services -{ - internal class CachingService : ICachingService - { - public void CacheMetadata(IEnumerable previews) - { - var updatedDatabase = UpdatePreviewDatabase(previews); - - var serializerSettings = new JsonSerializerSettings() - { - ContractResolver = PreviewDatabaseContractResolver.Instance, - Converters = new List() { new StringEnumConverter() }, - Formatting = Formatting.Indented - }; - - CacheUtil.CreateFileInTempCache(Constants.Previews.PreviewDatabaseFile, JsonConvert.SerializeObject(updatedDatabase, serializerSettings), true); - } - - public bool GetCachedMetadata(out PreviewDatabase previewDatabase) - { - previewDatabase = null; - if (!CacheUtil.GetFileFromTempCache(Constants.Previews.PreviewDatabaseFile, out string filePath)) - return false; - - try - { - var serializerSettings = new JsonSerializerSettings() - { - ContractResolver = PreviewDatabaseContractResolver.Instance, - Converters = new List() { new StringEnumConverter() } - }; - - previewDatabase = JsonConvert.DeserializeObject(File.ReadAllText(filePath, Encoding.UTF8), serializerSettings); - return true; - } - catch - { - return false; - } - } - - private PreviewDatabase UpdatePreviewDatabase(IEnumerable previews) - { - PreviewDatabase database; - if (!GetCachedMetadata(out database)) - database = new PreviewDatabase(); - - // Delete missing previews - for (int i = database.Previews.Count - 1; i >= 0; i--) - { - if (database.Previews[i].Exists()) - continue; - - database.Previews.RemoveAt(i); - } - - // Append new previews & Replace existing previews - foreach (var preview in previews) - { - var matchingPreviews = database.Previews.Where(x => x.Guid == preview.Guid).ToList(); - foreach (var matchingPreview in matchingPreviews) - { - // Delete previously generated preview of the same type - if (matchingPreview.Type == preview.Type) - database.Previews.Remove(matchingPreview); - // Delete previously generated preview of a different type if the path matches - else if (matchingPreview.Path.Equals(preview.Path)) - database.Previews.Remove(matchingPreview); - } - - database.Previews.Add(preview); - } - - database.Previews = database.Previews.OrderBy(x => x.Guid).ThenBy(x => x.Type).ToList(); - return database; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/CachingService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/CachingService.cs.meta deleted file mode 100644 index 02a153e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/CachingService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: e0b6cf909c8798b4590744959571a21f -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/ICachingService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/ICachingService.cs deleted file mode 100644 index 6713000..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/ICachingService.cs +++ /dev/null @@ -1,11 +0,0 @@ -using AssetStoreTools.Previews.Data; -using System.Collections.Generic; - -namespace AssetStoreTools.Previews.Services -{ - internal interface ICachingService : IPreviewService - { - void CacheMetadata(IEnumerable previews); - bool GetCachedMetadata(out PreviewDatabase previewDatabase); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/ICachingService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/ICachingService.cs.meta deleted file mode 100644 index 7dd1195..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/Caching/ICachingService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: eeaeae010299dcd489adb00dbf51b274 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/IPreviewService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/IPreviewService.cs deleted file mode 100644 index 0bc56ae..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/IPreviewService.cs +++ /dev/null @@ -1,4 +0,0 @@ -namespace AssetStoreTools.Previews.Services -{ - public interface IPreviewService { } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/IPreviewService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/IPreviewService.cs.meta deleted file mode 100644 index 4780114..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/IPreviewService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 8c2761fe05638644d8e3a265865beef8 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/PreviewServiceProvider.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/PreviewServiceProvider.cs deleted file mode 100644 index 7b2754b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/PreviewServiceProvider.cs +++ /dev/null @@ -1,17 +0,0 @@ -using AssetStoreTools.Utility; - -namespace AssetStoreTools.Previews.Services -{ - internal class PreviewServiceProvider : ServiceProvider - { - public static PreviewServiceProvider Instance => _instance ?? (_instance = new PreviewServiceProvider()); - private static PreviewServiceProvider _instance; - - private PreviewServiceProvider() { } - - protected override void RegisterServices() - { - Register(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/PreviewServiceProvider.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/PreviewServiceProvider.cs.meta deleted file mode 100644 index 3dd4631..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Services/PreviewServiceProvider.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a19bf5a4e3e441047bbc1b894e2a1149 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI.meta deleted file mode 100644 index 67d04e3..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 4738f3648c8368244a968bc840c1152b -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data.meta deleted file mode 100644 index b302df5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 23a2f4eadd444194a91ff4ce509e4798 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreview.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreview.cs deleted file mode 100644 index 1b2fee9..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreview.cs +++ /dev/null @@ -1,56 +0,0 @@ -using AssetStoreTools.Previews.Data; -using System; -using System.IO; -using System.Threading.Tasks; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Previews.UI.Data -{ - internal class AssetPreview : IAssetPreview - { - private PreviewMetadata _metadata; - - private UnityEngine.Object _cachedAsset; - private string _cachedAssetPath; - private Texture2D _cachedTexture; - - public UnityEngine.Object Asset => _cachedAsset ?? (_cachedAsset = AssetDatabase.LoadAssetAtPath(AssetPath)); - public string AssetPath => _cachedAssetPath ?? (_cachedAssetPath = AssetDatabase.GUIDToAssetPath(_metadata.Guid)); - - public AssetPreview(PreviewMetadata metadata) - { - _metadata = metadata; - } - - public string GetAssetPath() - { - var assetPath = AssetDatabase.GUIDToAssetPath(_metadata.Guid); - return assetPath; - } - - public async Task LoadImage(Action onSuccess) - { - if (_cachedTexture == null) - { - if (!_metadata.Exists()) - return; - - await Task.Yield(); - - try - { - _cachedTexture = new Texture2D(1, 1); - _cachedTexture.LoadImage(File.ReadAllBytes(_metadata.Path)); - } - catch (Exception e) - { - Debug.LogException(e); - return; - } - } - - onSuccess?.Invoke(_cachedTexture); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreview.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreview.cs.meta deleted file mode 100644 index 580a1b1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreview.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 739cf05c689204f4089fd0a6bddb8c3b -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreviewCollection.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreviewCollection.cs deleted file mode 100644 index 40db2b6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreviewCollection.cs +++ /dev/null @@ -1,46 +0,0 @@ -using AssetStoreTools.Previews.Data; -using System; -using System.Collections.Generic; - -namespace AssetStoreTools.Previews.UI.Data -{ - internal class AssetPreviewCollection : IAssetPreviewCollection - { - private GenerationType _generationType; - private List _images; - - public event Action OnCollectionChanged; - - public AssetPreviewCollection() - { - _images = new List(); - } - - public GenerationType GetGenerationType() - { - return _generationType; - } - - public IEnumerable GetPreviews() - { - return _images; - } - - public void Refresh(GenerationType generationType, IEnumerable previews) - { - _images.Clear(); - - _generationType = generationType; - - foreach (var entry in previews) - { - if (!entry.Exists()) - continue; - - _images.Add(new AssetPreview(entry)); - } - - OnCollectionChanged?.Invoke(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreviewCollection.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreviewCollection.cs.meta deleted file mode 100644 index 6977abd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/AssetPreviewCollection.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 9b1a0db8710933048b49dcca463fb8fd -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreview.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreview.cs deleted file mode 100644 index f7fc750..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreview.cs +++ /dev/null @@ -1,13 +0,0 @@ -using System; -using System.Threading.Tasks; -using UnityEngine; - -namespace AssetStoreTools.Previews.UI.Data -{ - internal interface IAssetPreview - { - UnityEngine.Object Asset { get; } - string GetAssetPath(); - Task LoadImage(Action onSuccess); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreview.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreview.cs.meta deleted file mode 100644 index 280bf1c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreview.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 0f9373dfc16d0fa4794dac29b75204ec -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreviewCollection.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreviewCollection.cs deleted file mode 100644 index 6e614c6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreviewCollection.cs +++ /dev/null @@ -1,15 +0,0 @@ -using AssetStoreTools.Previews.Data; -using System; -using System.Collections.Generic; - -namespace AssetStoreTools.Previews.UI.Data -{ - internal interface IAssetPreviewCollection - { - event Action OnCollectionChanged; - - GenerationType GetGenerationType(); - IEnumerable GetPreviews(); - void Refresh(GenerationType generationType, IEnumerable previews); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreviewCollection.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreviewCollection.cs.meta deleted file mode 100644 index d7c7c04..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IAssetPreviewCollection.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: fc9d9abd80c070f44ac49d5ce23d2fc0 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IPreviewGeneratorSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IPreviewGeneratorSettings.cs deleted file mode 100644 index 51f626c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IPreviewGeneratorSettings.cs +++ /dev/null @@ -1,27 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.Generators; -using System; -using System.Collections.Generic; - -namespace AssetStoreTools.Previews.UI.Data -{ - internal interface IPreviewGeneratorSettings - { - event Action OnGenerationTypeChanged; - event Action OnGenerationPathsChanged; - - void LoadSettings(PreviewGenerationSettings settings); - - GenerationType GetGenerationType(); - void SetGenerationType(GenerationType type); - List GetAvailableGenerationTypes(); - - List GetGenerationPaths(); - void AddGenerationPath(string path); - void RemoveGenerationPath(string path); - void ClearGenerationPaths(); - bool IsGenerationPathValid(string path, out string error); - - IPreviewGenerator CreateGenerator(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IPreviewGeneratorSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IPreviewGeneratorSettings.cs.meta deleted file mode 100644 index 4ba406e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/IPreviewGeneratorSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 55c9fcde15f06754588fd02fb8b99a60 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/PreviewGeneratorSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/PreviewGeneratorSettings.cs deleted file mode 100644 index 86962e4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/PreviewGeneratorSettings.cs +++ /dev/null @@ -1,212 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.Generators; -using AssetStoreTools.Utility; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using UnityEngine; - -namespace AssetStoreTools.Previews.UI.Data -{ - internal class PreviewGeneratorSettings : IPreviewGeneratorSettings - { - private readonly GenerationType[] _availableGenerationTypes = new GenerationType[] - { - GenerationType.Native, - GenerationType.Custom - }; - - private List _inputPaths; - private GenerationType _generationType; - - public event Action OnGenerationTypeChanged; - public event Action OnGenerationPathsChanged; - - public PreviewGeneratorSettings() - { - _inputPaths = new List(); - _generationType = GenerationType.Native; - } - - public void LoadSettings(PreviewGenerationSettings settings) - { - if (settings == null) - return; - - _inputPaths = settings.InputPaths.ToList(); - OnGenerationPathsChanged?.Invoke(); - - switch (settings) - { - case NativePreviewGenerationSettings _: - _generationType = GenerationType.Native; - break; - case CustomPreviewGenerationSettings _: - _generationType = GenerationType.Custom; - break; - default: - return; - } - - OnGenerationTypeChanged?.Invoke(); - } - - public GenerationType GetGenerationType() - { - return _generationType; - } - - public void SetGenerationType(GenerationType type) - { - _generationType = type; - OnGenerationTypeChanged?.Invoke(); - } - - public List GetAvailableGenerationTypes() - { - return _availableGenerationTypes.ToList(); - } - - public List GetGenerationPaths() - { - return _inputPaths; - } - - public void AddGenerationPath(string path) - { - if (string.IsNullOrEmpty(path)) - return; - - if (_inputPaths.Contains(path)) - return; - - // Prevent redundancy for new paths - var existingPath = _inputPaths.FirstOrDefault(x => path.StartsWith(x + "/")); - if (existingPath != null) - { - Debug.LogWarning($"Path '{path}' is already included with existing path: '{existingPath}'"); - return; - } - - // Prevent redundancy for already added paths - var redundantPaths = _inputPaths.Where(x => x.StartsWith(path + "/")).ToArray(); - foreach (var redundantPath in redundantPaths) - { - Debug.LogWarning($"Existing validation path '{redundantPath}' has been made redundant by the inclusion of new validation path: '{path}'"); - _inputPaths.Remove(redundantPath); - } - - _inputPaths.Add(path); - - OnGenerationPathsChanged?.Invoke(); - } - - public void RemoveGenerationPath(string path) - { - if (!_inputPaths.Contains(path)) - return; - - _inputPaths.Remove(path); - - OnGenerationPathsChanged?.Invoke(); - } - - public void ClearGenerationPaths() - { - if (_inputPaths.Count == 0) - return; - - _inputPaths.Clear(); - - OnGenerationPathsChanged?.Invoke(); - } - - public bool IsGenerationPathValid(string path, out string error) - { - error = string.Empty; - - if (string.IsNullOrEmpty(path)) - { - error = "Path cannot be empty"; - return false; - } - - var isAssetsPath = path.StartsWith("Assets/") - || path.Equals("Assets"); - var isPackagePath = PackageUtility.GetPackageByManifestPath($"{path}/package.json", out _); - - if (!isAssetsPath && !isPackagePath) - { - error = "Selected path must be within the Assets folder or point to a root path of a package"; - return false; - } - - if (!Directory.Exists(path)) - { - error = "Path does not exist"; - return false; - } - - if (path.Split('/').Any(x => x.StartsWith(".") || x.EndsWith("~"))) - { - error = $"Path '{path}' cannot be selected as it is a hidden folder and not part of the Asset Database"; - return false; - } - - return true; - } - - public IPreviewGenerator CreateGenerator() - { - switch (_generationType) - { - case GenerationType.Native: - return CreateNativeGenerator(); - case GenerationType.Custom: - return CreateCustomGenerator(); - default: - throw new NotImplementedException("Undefined generator type"); - } - } - - private IPreviewGenerator CreateNativeGenerator() - { - var settings = new NativePreviewGenerationSettings() - { - InputPaths = _inputPaths.ToArray(), - OutputPath = Constants.Previews.Native.DefaultOutputPath, - PreviewFileNamingFormat = Constants.Previews.DefaultFileNameFormat, - Format = Constants.Previews.Native.DefaultFormat, - WaitForPreviews = Constants.Previews.Native.DefaultWaitForPreviews, - ChunkedPreviewLoading = Constants.Previews.Native.DefaultChunkedPreviewLoading, - ChunkSize = Constants.Previews.Native.DefaultChunkSize, - OverwriteExisting = true - }; - - return new NativePreviewGenerator(settings); - } - - private IPreviewGenerator CreateCustomGenerator() - { - var settings = new CustomPreviewGenerationSettings() - { - InputPaths = _inputPaths.ToArray(), - OutputPath = Constants.Previews.Custom.DefaultOutputPath, - Width = Constants.Previews.Custom.DefaultWidth, - Height = Constants.Previews.Custom.DefaultHeight, - Depth = Constants.Previews.Custom.DefaultDepth, - NativeWidth = Constants.Previews.Custom.DefaultNativeWidth, - NativeHeight = Constants.Previews.Custom.DefaultNativeHeight, - PreviewFileNamingFormat = Constants.Previews.DefaultFileNameFormat, - Format = Constants.Previews.Custom.DefaultFormat, - AudioSampleColor = Constants.Previews.Custom.DefaultAudioSampleColor, - AudioBackgroundColor = Constants.Previews.Custom.DefaultAudioBackgroundColor, - OverwriteExisting = true - }; - - var generator = new CustomPreviewGenerator(settings); - return generator; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/PreviewGeneratorSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/PreviewGeneratorSettings.cs.meta deleted file mode 100644 index 1de481b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Data/PreviewGeneratorSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 9e6f754b1179d8d4cb40f62692619a63 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements.meta deleted file mode 100644 index d81acd5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 700ec0107b011824892281e880281bb1 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/AssetPreviewElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/AssetPreviewElement.cs deleted file mode 100644 index aee6fa8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/AssetPreviewElement.cs +++ /dev/null @@ -1,83 +0,0 @@ -using AssetStoreTools.Previews.UI.Data; -using System.Linq; -using UnityEditor; -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Previews.UI.Elements -{ - internal class AssetPreviewElement : VisualElement - { - // Data - private IAssetPreview _assetPreview; - - // UI - private Image _image; - private Label _label; - - public AssetPreviewElement() - { - AddToClassList("preview-list-image"); - - Create(); - - RegisterCallback(OnImageClicked); - } - - private void Create() - { - CreateFiller(); - CreateImage(); - CreateLabel(); - } - - private void CreateImage() - { - _image = new Image(); - Add(_image); - } - - private void CreateFiller() - { - var filler = new VisualElement() { name = "Filler" }; - Add(filler); - } - - private void CreateLabel() - { - _label = new Label(); - Add(_label); - } - - private void SetImage(Texture2D texture) - { - _image.style.width = texture.width < 128 ? texture.width : 128; - _image.style.height = texture.height < 128 ? texture.height : 128; - _image.style.backgroundImage = texture; - } - - private void OnImageClicked(MouseDownEvent _) - { - EditorGUIUtility.PingObject(_assetPreview.Asset); - } - - public void SetSource(IAssetPreview assetPreview) - { - _assetPreview = assetPreview; - _assetPreview.LoadImage(SetImage); - - var assetPath = _assetPreview.GetAssetPath(); - - if (string.IsNullOrEmpty(assetPath)) - { - _label.text = "[Missing]"; - tooltip = "This asset has been deleted"; - return; - } - - var assetNameWithExtension = assetPath.Split('/').Last(); - _label.text = assetNameWithExtension; - tooltip = assetPath; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/AssetPreviewElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/AssetPreviewElement.cs.meta deleted file mode 100644 index 56990b4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/AssetPreviewElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 28891b8cff841a44eb508494d62c190c -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/GridListElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/GridListElement.cs deleted file mode 100644 index a1bf53a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/GridListElement.cs +++ /dev/null @@ -1,140 +0,0 @@ -using System; -using System.Collections; -using System.Collections.Generic; -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Previews.UI.Elements -{ - internal class GridListElement : VisualElement - { - public int ElementWidth; - public int ElementHeight; - private int _visibilityHeadroom => ElementHeight; - - public IList ItemSource; - public Func MakeItem; - public Action BindItem; - - private ScrollView _scrollView; - - public GridListElement() - { - style.flexGrow = 1; - - Create(); - - _scrollView.contentViewport.RegisterCallback(OnGeometryChanged); - _scrollView.verticalScroller.valueChanged += OnVerticalScroll; -#if UNITY_2021_1_OR_NEWER - _scrollView.horizontalScrollerVisibility = ScrollerVisibility.Hidden; -#else - _scrollView.showHorizontal = false; -#endif - } - - private void Create() - { - _scrollView = new ScrollView(); - Add(_scrollView); - } - - private void OnGeometryChanged(GeometryChangedEvent evt) - { - Redraw(); - } - - private void OnVerticalScroll(float value) - { - Redraw(); - } - - public void Redraw() - { - if (ElementWidth == 0 - || ElementHeight == 0 - || ItemSource == null - || MakeItem == null - || BindItem == null) - return; - - _scrollView.Clear(); - - var rowCapacity = Mathf.FloorToInt(_scrollView.contentContainer.worldBound.width / ElementWidth); - if (rowCapacity == 0) - rowCapacity = 1; - - var totalRequiredRows = ItemSource.Count / rowCapacity; - if (ItemSource.Count % rowCapacity != 0) - totalRequiredRows++; - - _scrollView.contentContainer.style.height = totalRequiredRows * ElementHeight; - - var visibleRows = new List(); - for (int i = 0; i < totalRequiredRows; i++) - { - var visible = IsRowVisible(i); - if (!visible) - continue; - - var rowElement = CreateRow(i); - - for (int j = 0; j < rowCapacity; j++) - { - var elementIndex = i * rowCapacity + j; - if (elementIndex >= ItemSource.Count) - { - rowElement.Add(CreateFillerElement()); - continue; - } - - var element = MakeItem?.Invoke(); - BindItem?.Invoke(element, elementIndex); - - rowElement.Add(element); - } - - _scrollView.Add(rowElement); - } - } - - private bool IsRowVisible(int rowIndex) - { - var contentStartY = _scrollView.contentContainer.worldBound.yMin; - var visibleContentMinY = _scrollView.contentViewport.worldBound.yMin - _visibilityHeadroom; - var visibleContentMaxY = _scrollView.contentViewport.worldBound.yMax + _visibilityHeadroom; - if (_scrollView.contentViewport.worldBound.height == 0) - visibleContentMaxY = this.worldBound.yMax; - - var rowMinY = (rowIndex * ElementHeight) + contentStartY; - var rowMaxY = (rowIndex * ElementHeight) + ElementHeight + contentStartY; - - var fullyVisible = rowMinY >= visibleContentMinY && rowMaxY <= visibleContentMaxY; - var partiallyAbove = rowMinY < visibleContentMinY && rowMaxY > visibleContentMinY; - var partiallyBelow = rowMaxY > visibleContentMaxY && rowMinY < visibleContentMaxY; - - return fullyVisible || partiallyAbove || partiallyBelow; - } - - private VisualElement CreateRow(int rowIndex) - { - var rowElement = new VisualElement() { name = $"Row {rowIndex}" }; - rowElement.style.flexDirection = FlexDirection.Row; - rowElement.style.position = Position.Absolute; - rowElement.style.top = ElementHeight * rowIndex; - rowElement.style.width = _scrollView.contentViewport.worldBound.width; - rowElement.style.justifyContent = Justify.SpaceAround; - - return rowElement; - } - - private VisualElement CreateFillerElement() - { - var element = new VisualElement(); - element.style.width = ElementWidth; - element.style.height = ElementHeight; - - return element; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/GridListElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/GridListElement.cs.meta deleted file mode 100644 index bae1ff9..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/GridListElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 81d9f779e8c2a464cbdc1e39a4864803 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewCollectionElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewCollectionElement.cs deleted file mode 100644 index 28a35b1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewCollectionElement.cs +++ /dev/null @@ -1,116 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.UI.Data; -using System.Linq; -using UnityEditor.SceneManagement; -using UnityEngine; -using UnityEngine.Events; -using UnityEngine.SceneManagement; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Previews.UI.Elements -{ - internal class PreviewCollectionElement : VisualElement - { - // Data - private IAssetPreviewCollection _collection; - - // UI - private Label _previewCountLabel; - private GridListElement _gridListElement; - - public PreviewCollectionElement(IAssetPreviewCollection collection) - { - AddToClassList("preview-list"); - - _collection = collection; - _collection.OnCollectionChanged += RefreshList; - - Create(); - RefreshList(); - - SubscribeToSceneChanges(); - } - - private void Create() - { - CreateLabel(); - CreateGridListElement(); - } - - private void CreateLabel() - { - _previewCountLabel = new Label(); - _previewCountLabel.style.display = DisplayStyle.None; - Add(_previewCountLabel); - } - - private void CreateGridListElement() - { - _gridListElement = new GridListElement(); - _gridListElement.MakeItem = CreatePreview; - _gridListElement.BindItem = BindPreview; - _gridListElement.ElementWidth = 140 + 10; // Accounting for margin style - _gridListElement.ElementHeight = 160 + 10; // Accounting for margin style - Add(_gridListElement); - } - - private VisualElement CreatePreview() - { - var preview = new AssetPreviewElement(); - return preview; - } - - private void BindPreview(VisualElement element, int index) - { - var previewElement = (AssetPreviewElement)element; - var preview = _collection.GetPreviews().ToList()[index]; - previewElement.SetSource(preview); - } - - private void RefreshList() - { - var type = _collection.GetGenerationType(); - var items = _collection.GetPreviews().ToList(); - _previewCountLabel.text = $"Displaying {items.Count} {ConvertGenerationTypeName(type)} previews"; - _previewCountLabel.style.display = DisplayStyle.Flex; - _previewCountLabel.style.alignSelf = Align.Center; - _previewCountLabel.style.marginBottom = 10; - _previewCountLabel.style.unityFontStyleAndWeight = FontStyle.Bold; - - _gridListElement.ItemSource = items; - _gridListElement.Redraw(); - } - - private string ConvertGenerationTypeName(GenerationType type) - { - switch (type) - { - case GenerationType.Custom: - return "high resolution"; - default: - return type.ToString().ToLower(); - } - } - - private void SubscribeToSceneChanges() - { - var windowToSubscribeTo = Resources.FindObjectsOfTypeAll().FirstOrDefault(); - UnityAction sceneChanged = null; - sceneChanged = new UnityAction((_, __) => RefreshObjects(windowToSubscribeTo)); - EditorSceneManager.activeSceneChangedInEditMode += sceneChanged; - - void RefreshObjects(PreviewGeneratorWindow subscribedWindow) - { - // Remove callback if preview generator window instance changed - var activeWindow = Resources.FindObjectsOfTypeAll().FirstOrDefault(); - if (subscribedWindow == null || subscribedWindow != activeWindow) - { - EditorSceneManager.activeSceneChangedInEditMode -= sceneChanged; - return; - } - - RefreshList(); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewCollectionElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewCollectionElement.cs.meta deleted file mode 100644 index 3068d08..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewCollectionElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 842a11e046ca5284d9de9f4a05b1fa26 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGenerateButtonElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGenerateButtonElement.cs deleted file mode 100644 index 3d2f9a8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGenerateButtonElement.cs +++ /dev/null @@ -1,50 +0,0 @@ -using AssetStoreTools.Previews.UI.Data; -using System; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Previews.UI.Elements -{ - internal class PreviewGenerateButtonElement : VisualElement - { - // Data - private IPreviewGeneratorSettings _settings; - - // UI - private Button _generateButton; - - public event Action OnGenerate; - - public PreviewGenerateButtonElement(IPreviewGeneratorSettings settings) - { - _settings = settings; - _settings.OnGenerationPathsChanged += GenerationPathsChanged; - - Create(); - Deserialize(); - } - - private void Create() - { - _generateButton = new Button(Validate) { text = "Generate" }; - _generateButton.AddToClassList("preview-generate-button"); - - Add(_generateButton); - } - - private void Validate() - { - OnGenerate?.Invoke(); - } - - private void GenerationPathsChanged() - { - var inputPathsPresent = _settings.GetGenerationPaths().Count > 0; - _generateButton.SetEnabled(inputPathsPresent); - } - - private void Deserialize() - { - GenerationPathsChanged(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGenerateButtonElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGenerateButtonElement.cs.meta deleted file mode 100644 index 1f3a7b4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGenerateButtonElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 1c8fbb0b13ba7d3479c0867c440821e6 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorPathsElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorPathsElement.cs deleted file mode 100644 index cf72440..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorPathsElement.cs +++ /dev/null @@ -1,122 +0,0 @@ -using AssetStoreTools.Previews.UI.Data; -using AssetStoreTools.Utility; -using UnityEditor; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Validator.UI.Elements -{ - internal class PreviewGeneratorPathsElement : VisualElement - { - // Data - private IPreviewGeneratorSettings _settings; - - // UI - private ScrollView _pathBoxScrollView; - - public PreviewGeneratorPathsElement(IPreviewGeneratorSettings settings) - { - AddToClassList("preview-paths"); - - _settings = settings; - _settings.OnGenerationPathsChanged += InputPathsChanged; - - Create(); - Deserialize(); - } - - private void Create() - { - var pathSelectionRow = new VisualElement(); - pathSelectionRow.AddToClassList("preview-settings-selection-row"); - - VisualElement labelHelpRow = new VisualElement(); - labelHelpRow.AddToClassList("preview-settings-selection-label-help-row"); - labelHelpRow.style.alignSelf = Align.FlexStart; - - Label pathLabel = new Label { text = "Input paths" }; - Image pathLabelTooltip = new Image - { - tooltip = "Select the folder (or multiple folders) to generate asset previews for." - }; - - labelHelpRow.Add(pathLabel); - labelHelpRow.Add(pathLabelTooltip); - - var fullPathBox = new VisualElement() { name = "PreviewPaths" }; - fullPathBox.AddToClassList("preview-paths-box"); - - _pathBoxScrollView = new ScrollView { name = "PreviewPathsScrollView" }; - _pathBoxScrollView.AddToClassList("preview-paths-scroll-view"); - - VisualElement scrollViewBottomRow = new VisualElement(); - scrollViewBottomRow.AddToClassList("preview-paths-scroll-view-bottom-row"); - - var addExtraPathsButton = new Button(BrowsePath) { text = "Add a path" }; - addExtraPathsButton.AddToClassList("preview-paths-add-button"); - scrollViewBottomRow.Add(addExtraPathsButton); - - fullPathBox.Add(_pathBoxScrollView); - fullPathBox.Add(scrollViewBottomRow); - - pathSelectionRow.Add(labelHelpRow); - pathSelectionRow.Add(fullPathBox); - - Add(pathSelectionRow); - } - - private VisualElement CreateSinglePathElement(string path) - { - var validationPath = new VisualElement(); - validationPath.AddToClassList("preview-paths-path-row"); - - var folderPathLabel = new Label(path); - folderPathLabel.AddToClassList("preview-paths-path-row-input-field"); - - var removeButton = new Button(() => - { - _settings.RemoveGenerationPath(path); - }); - removeButton.text = "X"; - removeButton.AddToClassList("preview-paths-path-row-remove-button"); - - validationPath.Add(folderPathLabel); - validationPath.Add(removeButton); - - return validationPath; - } - - private void BrowsePath() - { - string absolutePath = EditorUtility.OpenFolderPanel("Select a directory", "Assets", ""); - - if (string.IsNullOrEmpty(absolutePath)) - return; - - var relativePath = FileUtility.AbsolutePathToRelativePath(absolutePath, ASToolsPreferences.Instance.EnableSymlinkSupport); - - if (!_settings.IsGenerationPathValid(relativePath, out var error)) - { - EditorUtility.DisplayDialog("Invalid path", error, "OK"); - return; - } - - _settings.AddGenerationPath(relativePath); - } - - private void InputPathsChanged() - { - var inputPaths = _settings.GetGenerationPaths(); - - _pathBoxScrollView.Clear(); - foreach (var path in inputPaths) - { - _pathBoxScrollView.Add(CreateSinglePathElement(path)); - } - } - - private void Deserialize() - { - InputPathsChanged(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorPathsElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorPathsElement.cs.meta deleted file mode 100644 index afdcc93..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorPathsElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: cd3e3f7fbfc5f1e46835438be2756746 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorSettingsElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorSettingsElement.cs deleted file mode 100644 index d5268f5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorSettingsElement.cs +++ /dev/null @@ -1,99 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.UI.Data; -using AssetStoreTools.Validator.UI.Elements; -using UnityEditor.UIElements; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Previews.UI.Elements -{ - internal class PreviewGeneratorSettingsElement : VisualElement - { - // Data - private IPreviewGeneratorSettings _settings; - - // UI - private PreviewGeneratorPathsElement _previewPathsElement; - private ToolbarMenu _generationTypeMenu; - - public PreviewGeneratorSettingsElement(IPreviewGeneratorSettings settings) - { - AddToClassList("preview-settings"); - - _settings = settings; - _settings.OnGenerationTypeChanged += GenerationTypeChanged; - - Create(); - Deserialize(); - } - - private void Create() - { - CreateGenerationType(); - CreateInputPathsElement(); - } - - private void CreateInputPathsElement() - { - _previewPathsElement = new PreviewGeneratorPathsElement(_settings); - Add(_previewPathsElement); - } - - private void CreateGenerationType() - { - var typeSelectionBox = new VisualElement(); - typeSelectionBox.AddToClassList("preview-settings-selection-row"); - - VisualElement labelHelpRow = new VisualElement(); - labelHelpRow.AddToClassList("preview-settings-selection-label-help-row"); - - Label generationTypeLabel = new Label { text = "Generation type" }; - Image categoryLabelTooltip = new Image - { - tooltip = "Choose the generation type for your previews.\n\n" + - "- Native: retrieve previews from the Asset Database which are generated by Unity Editor internally\n" + - "- High Resolution (experimental): generate previews using a custom implementation. Resulting previews are of higher resolution " + - "than those generated by Unity Editor. Note that they may look slightly different from native previews" - }; - - labelHelpRow.Add(generationTypeLabel); - labelHelpRow.Add(categoryLabelTooltip); - - _generationTypeMenu = new ToolbarMenu { name = "GenerationTypeMenu" }; - _generationTypeMenu.AddToClassList("preview-settings-selection-dropdown"); - - typeSelectionBox.Add(labelHelpRow); - typeSelectionBox.Add(_generationTypeMenu); - - // Append available categories - var types = _settings.GetAvailableGenerationTypes(); - foreach (var t in types) - { - _generationTypeMenu.menu.AppendAction(ConvertGenerationTypeName(t), _ => _settings.SetGenerationType(t)); - } - - Add(typeSelectionBox); - } - - private string ConvertGenerationTypeName(GenerationType type) - { - switch (type) - { - case GenerationType.Custom: - return "High Resolution (experimental)"; - default: - return type.ToString(); - } - } - - private void GenerationTypeChanged() - { - var t = _settings.GetGenerationType(); - _generationTypeMenu.text = ConvertGenerationTypeName(t); - } - - private void Deserialize() - { - GenerationTypeChanged(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorSettingsElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorSettingsElement.cs.meta deleted file mode 100644 index 6e1abfb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewGeneratorSettingsElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 6f38de8a438b8c94a81fe5f2cc45c110 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewWindowDescriptionElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewWindowDescriptionElement.cs deleted file mode 100644 index 1306f05..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewWindowDescriptionElement.cs +++ /dev/null @@ -1,87 +0,0 @@ -using UnityEngine.UIElements; - -namespace AssetStoreTools.Previews.UI.Elements -{ - internal class PreviewWindowDescriptionElement : VisualElement - { - private const string DescriptionFoldoutText = "Generate and inspect asset preview images to be displayed in your package listing page on the Asset Store."; - private const string DescriptionFoldoutContentText = "Images generated in this window will be reused when exporting a package. Any missing images generated during the package export process will also appear here.\n\n" + - "Preview images are displayed on the Asset Store under the 'Package Content' section of the package listing. " + - "They are also displayed in the package importer window that appears during the package import process. " + - "Note that these images will not replace the images used for the assets in the Project window after the package gets imported."; - - private VisualElement _descriptionSimpleContainer; - private Button _showMoreButton; - - private VisualElement _descriptionFullContainer; - private Button _showLessButton; - - public PreviewWindowDescriptionElement() - { - AddToClassList("asset-preview-description"); - Create(); - } - - private void Create() - { - CreateSimpleDescription(); - CreateFullDescription(); - } - - private void CreateSimpleDescription() - { - _descriptionSimpleContainer = new VisualElement(); - _descriptionSimpleContainer.AddToClassList("asset-preview-description-simple-container"); - - var simpleDescription = new Label(DescriptionFoldoutText); - simpleDescription.AddToClassList("asset-preview-description-simple-label"); - - _showMoreButton = new Button(ToggleFullDescription) { text = "Show more..." }; - _showMoreButton.AddToClassList("asset-preview-description-hyperlink-button"); - _showMoreButton.AddToClassList("asset-preview-description-show-button"); - - _descriptionSimpleContainer.Add(simpleDescription); - _descriptionSimpleContainer.Add(_showMoreButton); - - Add(_descriptionSimpleContainer); - } - - private void CreateFullDescription() - { - _descriptionFullContainer = new VisualElement(); - _descriptionFullContainer.AddToClassList("asset-preview-description-full-container"); - - var validatorDescription = new Label() - { - text = DescriptionFoldoutContentText - }; - validatorDescription.AddToClassList("asset-preview-description-full-label"); - - _showLessButton = new Button(ToggleFullDescription) { text = "Show less..." }; - _showLessButton.AddToClassList("asset-preview-description-hide-button"); - _showLessButton.AddToClassList("asset-preview-description-hyperlink-button"); - - _descriptionFullContainer.Add(validatorDescription); - _descriptionFullContainer.Add(_showLessButton); - - _descriptionFullContainer.style.display = DisplayStyle.None; - Add(_descriptionFullContainer); - } - - private void ToggleFullDescription() - { - var displayFullDescription = _descriptionFullContainer.style.display == DisplayStyle.None; - - if (displayFullDescription) - { - _showMoreButton.style.display = DisplayStyle.None; - _descriptionFullContainer.style.display = DisplayStyle.Flex; - } - else - { - _showMoreButton.style.display = DisplayStyle.Flex; - _descriptionFullContainer.style.display = DisplayStyle.None; - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewWindowDescriptionElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewWindowDescriptionElement.cs.meta deleted file mode 100644 index 20f5147..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Elements/PreviewWindowDescriptionElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 2cab289a87b0ba74f89cb458ff6d44f8 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/PreviewGeneratorWindow.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/PreviewGeneratorWindow.cs deleted file mode 100644 index 3a2d36f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/PreviewGeneratorWindow.cs +++ /dev/null @@ -1,51 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.Services; -using AssetStoreTools.Previews.UI.Views; -using AssetStoreTools.Utility; -using UnityEditor.UIElements; -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Previews.UI -{ - internal class PreviewGeneratorWindow : AssetStoreToolsWindow - { - protected override string WindowTitle => "Preview Generator"; - - private ICachingService _cachingService; - - private PreviewListView _previewListView; - - protected override void Init() - { - minSize = new Vector2(350, 350); - - this.SetAntiAliasing(4); - - VisualElement root = rootVisualElement; - - // Getting a reference to the USS Document and adding stylesheet to the root - root.styleSheets.Add(StyleSelector.PreviewGeneratorWindow.PreviewGeneratorWindowStyle); - root.styleSheets.Add(StyleSelector.PreviewGeneratorWindow.PreviewGeneratorWindowTheme); - - GetServices(); - ConstructWindow(); - } - - private void GetServices() - { - _cachingService = PreviewServiceProvider.Instance.GetService(); - } - - private void ConstructWindow() - { - _previewListView = new PreviewListView(_cachingService); - rootVisualElement.Add(_previewListView); - } - - public void Load(PreviewGenerationSettings settings) - { - _previewListView.LoadSettings(settings); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/PreviewGeneratorWindow.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/PreviewGeneratorWindow.cs.meta deleted file mode 100644 index c6f537e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/PreviewGeneratorWindow.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 4cad15de2de8cdc46b48a4b05eac5d78 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Views.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Views.meta deleted file mode 100644 index 598279e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Views.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 5e154861b0e2af64b93f6c831e6c0dc2 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Views/PreviewListView.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Views/PreviewListView.cs deleted file mode 100644 index 36f5264..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Views/PreviewListView.cs +++ /dev/null @@ -1,142 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.Services; -using AssetStoreTools.Previews.UI.Data; -using AssetStoreTools.Previews.UI.Elements; -using System.Collections.Generic; -using System.Linq; -using UnityEditor; -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Previews.UI.Views -{ - internal class PreviewListView : VisualElement - { - //Data - private PreviewDatabase _previewDatabase; - private IPreviewGeneratorSettings _previewGeneratorSettings; - private IAssetPreviewCollection _previewCollection; - - private ICachingService _cachingService; - - // UI - private PreviewWindowDescriptionElement _descriptionElement; - private PreviewGeneratorSettingsElement _settingsElement; - private PreviewGenerateButtonElement _generateButtonElement; - private PreviewCollectionElement _previewCollectionElement; - - public PreviewListView(ICachingService cachingService) - { - _cachingService = cachingService; - - _previewGeneratorSettings = new PreviewGeneratorSettings(); - _previewCollection = new AssetPreviewCollection(); - - _previewGeneratorSettings.OnGenerationTypeChanged += RefreshPreviewList; - _previewGeneratorSettings.OnGenerationPathsChanged += RefreshPreviewList; - - Create(); - RefreshPreviewList(); - } - - private void Create() - { - CreateDescription(); - CreateSettings(); - CreateGenerateButton(); - CreatePreviewList(); - } - - private void CreateDescription() - { - _descriptionElement = new PreviewWindowDescriptionElement(); - Add(_descriptionElement); - } - - private void CreateSettings() - { - _settingsElement = new PreviewGeneratorSettingsElement(_previewGeneratorSettings); - Add(_settingsElement); - } - - private void CreateGenerateButton() - { - _generateButtonElement = new PreviewGenerateButtonElement(_previewGeneratorSettings); - _generateButtonElement.OnGenerate += GeneratePreviews; - Add(_generateButtonElement); - } - - private void CreatePreviewList() - { - _previewCollectionElement = new PreviewCollectionElement(_previewCollection); - Add(_previewCollectionElement); - } - - private async void GeneratePreviews() - { - try - { - _settingsElement.SetEnabled(false); - _generateButtonElement.SetEnabled(false); - _previewCollectionElement.SetEnabled(false); - - var generator = _previewGeneratorSettings.CreateGenerator(); - generator.OnProgressChanged += DisplayProgress; - var result = await generator.Generate(); - generator.OnProgressChanged -= DisplayProgress; - - if (!result.Success) - { - EditorUtility.DisplayDialog("Error", result.Exception.Message, "OK"); - Debug.LogException(result.Exception); - return; - } - - RefreshPreviewList(); - } - finally - { - _settingsElement.SetEnabled(true); - _generateButtonElement.SetEnabled(true); - _previewCollectionElement.SetEnabled(true); - EditorUtility.ClearProgressBar(); - } - } - - private void DisplayProgress(float progress) - { - EditorUtility.DisplayProgressBar("Generating", "Generating previews...", progress); - } - - public void LoadSettings(PreviewGenerationSettings settings) - { - _previewGeneratorSettings.LoadSettings(settings); - } - - private void RefreshPreviewList() - { - if (!_cachingService.GetCachedMetadata(out _previewDatabase)) - _previewDatabase = new PreviewDatabase(); - - var paths = _previewGeneratorSettings.GetGenerationPaths(); - var guids = AssetDatabase.FindAssets("", paths.ToArray()); - var displayedPreviews = new List(); - - foreach (var entry in _previewDatabase.Previews) - { - if (!entry.Exists()) - continue; - - if (entry.Type != _previewGeneratorSettings.GetGenerationType()) - continue; - - if (!guids.Any(x => x == entry.Guid)) - continue; - - displayedPreviews.Add(entry); - } - - _previewCollection.Refresh(_previewGeneratorSettings.GetGenerationType(), displayedPreviews); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Views/PreviewListView.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Views/PreviewListView.cs.meta deleted file mode 100644 index 7ddbc60..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/UI/Views/PreviewListView.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 94d417240bb510d469acb8a11f15b277 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility.meta deleted file mode 100644 index 92fdd4f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 99cf24252c136f246bfa4b02a69fe992 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/GraphicsUtility.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/GraphicsUtility.cs deleted file mode 100644 index 1a304f0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/GraphicsUtility.cs +++ /dev/null @@ -1,96 +0,0 @@ -using UnityEngine; - -namespace AssetStoreTools.Previews.Utility -{ - internal static class GraphicsUtility - { - public static Texture2D GetTextureFromCamera(Camera camera, int desiredWidth, int desiredHeight, int desiredDepth) - { - var texture = new Texture2D(desiredWidth, desiredHeight); - var originalRenderTexture = RenderTexture.active; - var renderTexture = RenderTexture.GetTemporary(desiredWidth, desiredHeight, desiredDepth); - var cameraInitiallyEnabled = camera.enabled; - - try - { - if (cameraInitiallyEnabled) - camera.enabled = false; - - camera.targetTexture = renderTexture; - camera.Render(); - - RenderTexture.active = renderTexture; - texture.ReadPixels(new Rect(0, 0, texture.width, texture.height), 0, 0); - texture.Apply(); - } - finally - { - camera.targetTexture = null; - RenderTexture.active = originalRenderTexture; - RenderTexture.ReleaseTemporary(renderTexture); - camera.enabled = cameraInitiallyEnabled; - } - - return texture; - } - - public static Texture2D ResizeTexture(Texture2D source, int desiredWidth, int desiredHeight) - { - var texture = new Texture2D(desiredWidth, desiredHeight); - var originalRenderTexture = RenderTexture.active; - var renderTexture = RenderTexture.GetTemporary(desiredWidth, desiredHeight, 32); - - try - { - RenderTexture.active = renderTexture; - Graphics.Blit(source, renderTexture); - - texture.ReadPixels(new Rect(0, 0, renderTexture.width, renderTexture.height), 0, 0); - texture.Apply(); - } - finally - { - RenderTexture.active = originalRenderTexture; - RenderTexture.ReleaseTemporary(renderTexture); - } - - return texture; - } - - public static Texture2D ResizeTextureNormalMap(Texture2D source, int desiredWidth, int desiredHeight) - { - var texture = new Texture2D(desiredWidth, desiredHeight); - var originalRenderTexture = RenderTexture.active; - var renderTexture = RenderTexture.GetTemporary(desiredWidth, desiredHeight, 32, RenderTextureFormat.Default, RenderTextureReadWrite.Linear); - - try - { - RenderTexture.active = renderTexture; - Graphics.Blit(source, renderTexture); - - texture.ReadPixels(new Rect(0, 0, renderTexture.width, renderTexture.height), 0, 0); - - for (int i = 0; i < texture.width; i++) - { - for (int j = 0; j < texture.height; j++) - { - var color = texture.GetPixel(i, j); - color.b = color.r; - color.r = color.a; - color.a = 1; - texture.SetPixel(i, j, color); - } - } - - texture.Apply(); - } - finally - { - RenderTexture.active = originalRenderTexture; - RenderTexture.ReleaseTemporary(renderTexture); - } - - return texture; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/GraphicsUtility.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/GraphicsUtility.cs.meta deleted file mode 100644 index 04602e6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/GraphicsUtility.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: f0a4fc8f266b4dd41a59693dd581e232 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewConvertUtility.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewConvertUtility.cs deleted file mode 100644 index ab93f97..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewConvertUtility.cs +++ /dev/null @@ -1,72 +0,0 @@ -using AssetStoreTools.Previews.Data; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Previews.Utility -{ - internal static class PreviewConvertUtility - { - public static string ConvertFilename(Object asset, FileNameFormat format) - { - string fileName = string.Empty; - - switch (format) - { - case FileNameFormat.Guid: - AssetDatabase.TryGetGUIDAndLocalFileIdentifier(asset, out var guid, out long _); - fileName = guid; - break; - case FileNameFormat.FullAssetPath: - var assetPath = AssetDatabase.GetAssetPath(asset); - - if (assetPath.StartsWith("Assets/")) - fileName = assetPath.Substring("Assets/".Length); - else if (assetPath.StartsWith("Packages/")) - fileName = assetPath.Substring("Packages/".Length); - - fileName = fileName.Replace("/", "_"); - break; - case FileNameFormat.AssetName: - fileName = asset.name; - break; - default: - throw new System.Exception("Undefined format"); - } - - return fileName; - } - - public static string ConvertExtension(PreviewFormat format) - { - switch (format) - { - case PreviewFormat.JPG: - return "jpg"; - case PreviewFormat.PNG: - return "png"; - default: - throw new System.Exception("Undefined format"); - } - } - - public static string ConvertFilenameWithExtension(Object asset, FileNameFormat nameFormat, PreviewFormat imageFormat) - { - var filename = ConvertFilename(asset, nameFormat); - var extension = ConvertExtension(imageFormat); - return $"{filename}.{extension}"; - } - - public static byte[] ConvertTexture(Texture2D texture, PreviewFormat format) - { - switch (format) - { - case PreviewFormat.JPG: - return texture.EncodeToJPG(); - case PreviewFormat.PNG: - return texture.EncodeToPNG(); - default: - throw new System.Exception("Undefined format"); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewConvertUtility.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewConvertUtility.cs.meta deleted file mode 100644 index 241997d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewConvertUtility.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 700eaf82299628d44853599774664bea -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewSceneUtility.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewSceneUtility.cs deleted file mode 100644 index 8ca2b3a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewSceneUtility.cs +++ /dev/null @@ -1,196 +0,0 @@ -using System; -using System.Threading.Tasks; -using UnityEditor; -using UnityEditor.SceneManagement; -using UnityEngine; -#if AST_URP_AVAILABLE -using UnityEngine.Rendering.Universal; -#endif -#if AST_HDRP_AVAILABLE -using UnityEngine.Rendering; -using UnityEngine.Rendering.HighDefinition; -#endif - -namespace AssetStoreTools.Previews.Utility -{ - internal static class PreviewSceneUtility - { - private const string PreviewSceneName = "Preview Generation In Progress"; - private static readonly Color BackgroundColor = new Color(82f / 255, 82f / 255, 82f / 255); - private static readonly Color BackgroundColorHDRP = new Color(38f / 255, 38f / 255, 38f / 255); - - public static async Task OpenPreviewSceneForCurrentPipeline() - { - // Wait for an Editor frame to avoid recursive player loop internal errors - await WaitForEditorUpdate(); - - switch (RenderPipelineUtility.GetCurrentPipeline()) - { - case RenderPipeline.BiRP: - await OpenPreviewSceneBiRP(); - break; -#if AST_URP_AVAILABLE - case RenderPipeline.URP: - await OpenPreviewSceneURP(); - break; -#endif -#if AST_HDRP_AVAILABLE - case RenderPipeline.HDRP: - await OpenPreviewSceneHDRP(); - break; -#endif - default: - throw new NotImplementedException("Undefined Render Pipeline"); - } - } - - private static async Task WaitForEditorUpdate() - { - var updateCalled = false; - var delayCalled = false; - - void Update() - { - EditorApplication.update -= Update; - updateCalled = true; - } - - EditorApplication.update += Update; - while (!updateCalled) - await Task.Delay(10); - - void DelayCall() - { - EditorApplication.delayCall -= DelayCall; - delayCalled = true; - } - - EditorApplication.delayCall += DelayCall; - while (!delayCalled) - await Task.Delay(10); - } - - public static async Task OpenPreviewSceneBiRP() - { - OpenNewScene(); - - CreateSceneCamera(); - CreateSceneLighting(); - - await WaitForLighting(); - } - - private static void OpenNewScene() - { - EditorSceneManager.SaveCurrentModifiedScenesIfUserWantsTo(); - var scene = EditorSceneManager.NewScene(NewSceneSetup.EmptyScene, NewSceneMode.Single); - scene.name = PreviewSceneName; - } - - private static Camera CreateSceneCamera() - { - var cameraGO = new GameObject() { name = "Camera" }; - var camera = cameraGO.AddComponent(); - camera.enabled = false; - camera.tag = "MainCamera"; - - camera.nearClipPlane = 0.01f; - camera.farClipPlane = 100000; - camera.clearFlags = CameraClearFlags.SolidColor; - camera.backgroundColor = BackgroundColor; - - return camera; - } - - private static Light CreateSceneLighting() - { - var lightGO = new GameObject() { name = "Lights" }; - lightGO.transform.rotation = Quaternion.Euler(45, 225, 0); - var light = lightGO.AddComponent(); - light.intensity = 0.75f; - light.type = LightType.Directional; - light.shadows = LightShadows.None; - - return light; - } - - private static async Task WaitForLighting() - { - while (!DynamicGI.isConverged) - await Task.Delay(100); - - await Task.Yield(); - } - -#if AST_URP_AVAILABLE - public static async Task OpenPreviewSceneURP() - { - OpenNewScene(); - - var camera = CreateSceneCamera(); - camera.gameObject.AddComponent(); - - var lighting = CreateSceneLighting(); - lighting.intensity = 0.5f; - lighting.gameObject.AddComponent(); - - await WaitForLighting(); - } -#endif - -#if AST_HDRP_AVAILABLE - public static async Task OpenPreviewSceneHDRP() - { - OpenNewScene(); - - var camera = CreateSceneCamera(); - var cameraData = camera.gameObject.AddComponent(); - cameraData.clearColorMode = HDAdditionalCameraData.ClearColorMode.Color; - cameraData.backgroundColorHDR = BackgroundColorHDRP; - - var light = CreateSceneLighting(); - var lightData = light.gameObject.AddComponent(); - lightData.SetIntensity(5000, LightUnit.Lux); - - CreateHDRPVolumeProfile(); - - await WaitForLighting(); - } - - private static Volume CreateHDRPVolumeProfile() - { - var volumeGO = new GameObject() { name = "Volume" }; - var volume = volumeGO.gameObject.AddComponent(); - - var profile = VolumeProfile.CreateInstance(); - volume.profile = profile; - volume.isGlobal = true; - - var exposure = profile.Add(); - exposure.active = true; - - exposure.mode.overrideState = true; - exposure.mode.value = ExposureMode.Fixed; - - exposure.fixedExposure.overrideState = true; - exposure.fixedExposure.value = 11; - - var fog = profile.Add(); - fog.active = true; - - fog.enabled.overrideState = true; - fog.enabled.value = false; - -#if AST_HDRP_AVAILABLE_V12 - var volumetricClouds = profile.Add(); - volumetricClouds.active = true; - - volumetricClouds.enable.overrideState = true; - volumetricClouds.enable.value = false; -#endif - - return volume; - } -#endif - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewSceneUtility.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewSceneUtility.cs.meta deleted file mode 100644 index 9f0056a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/PreviewSceneUtility.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 63fa5650920e7914dae6fe76badac249 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipeline.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipeline.cs deleted file mode 100644 index 028f96d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipeline.cs +++ /dev/null @@ -1,10 +0,0 @@ -namespace AssetStoreTools.Previews.Utility -{ - internal enum RenderPipeline - { - Unknown = 0, - BiRP = 1, - URP = 2, - HDRP = 3 - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipeline.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipeline.cs.meta deleted file mode 100644 index 1d40470..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipeline.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: c43c7ce2b9090ab49bb8944bc6bdb3c7 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipelineUtility.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipelineUtility.cs deleted file mode 100644 index c8e79d5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipelineUtility.cs +++ /dev/null @@ -1,32 +0,0 @@ -using UnityEngine.Rendering; -#if AST_URP_AVAILABLE -using UnityEngine.Rendering.Universal; -#endif -#if AST_HDRP_AVAILABLE -using UnityEngine.Rendering.HighDefinition; -#endif - -namespace AssetStoreTools.Previews.Utility -{ - internal static class RenderPipelineUtility - { - public static RenderPipeline GetCurrentPipeline() - { - var currentPipelineAsset = GraphicsSettings.currentRenderPipeline; - if (currentPipelineAsset == null) - return RenderPipeline.BiRP; - -#if AST_URP_AVAILABLE - if (currentPipelineAsset is UniversalRenderPipelineAsset) - return RenderPipeline.URP; -#endif - -#if AST_HDRP_AVAILABLE - if (currentPipelineAsset is HDRenderPipelineAsset) - return RenderPipeline.HDRP; -#endif - - return RenderPipeline.Unknown; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipelineUtility.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipelineUtility.cs.meta deleted file mode 100644 index 4148f8a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Scripts/Utility/RenderPipelineUtility.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 5e42bdf53cd8b51429b10a6742ec5272 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles.meta deleted file mode 100644 index 50a0018..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 70d30555bce30014a9143c3d003105bf -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/Style.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/Style.uss deleted file mode 100644 index c363a3d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/Style.uss +++ /dev/null @@ -1,210 +0,0 @@ -/* Asset Preview Description */ - -.asset-preview-description { - flex-direction: column; - flex-shrink: 0; - - margin: 10px 5px 2px 5px; - padding: 2px 4px; -} - -.asset-preview-description-simple-container { - flex-direction: column; - flex-wrap: wrap; -} - -.asset-preview-description-simple-label { - white-space: normal; -} - -.asset-preview-description-hyperlink-button { - margin: 0; - padding: 0; - - align-self: flex-start; - cursor: link; -} - -.asset-preview-description-show-button { - margin-top: 12px; -} - -.asset-preview-description-hide-button { - margin-top: 12px; -} - -.asset-preview-description-full-container { - margin-top: 12px; -} - -.asset-preview-description-full-label { - white-space: normal; -} - -/* Asset Preview Settings */ - -.preview-settings { - flex-direction: column; - flex-shrink: 0; - - margin: 0px 5px 2px 5px; - padding: 2px 4px; -} - -.preview-settings-selection-row { - flex-direction: row; - flex-grow: 1; - - margin-top: 10px; - padding: 0 3px 0 2px; -} - -.preview-settings-selection-label-help-row { - flex-direction: row; - flex-shrink: 1; - flex-grow: 0; - - align-self: center; - align-items: center; - justify-content: flex-start; - - width: 120px; -} - -.preview-settings-selection-label-help-row > Label { - -unity-font-style: bold; -} - -.preview-settings-selection-label-help-row > Image { - height: 16px; - width: 16px; -} - -.preview-settings-selection-dropdown { - flex-grow: 1; - flex-shrink: 1; - - align-self: stretch; - - margin-right: 0; - margin-left: 3px; - padding: 1px 4px; -} - -/* Preview Paths */ - -.preview-paths { - flex-direction: column; - flex-grow: 1; - flex-shrink: 0; - - margin-bottom: 10px; - padding: 0; -} - -.preview-paths-box { - flex-grow: 1; - flex-direction: column; -} - -.preview-paths-scroll-view { - flex-grow: 1; - height: 100px; - margin-left: 3px; -} - -.preview-paths-scroll-view > .unity-scroll-view__content-viewport -{ - margin-left: 1px; -} - -.preview-paths-scroll-view > * > .unity-scroll-view__content-container -{ - padding: 0 0 0 0; -} - -.preview-paths-scroll-view > * > .unity-scroll-view__vertical-scroller -{ - margin: -1px 0; -} - -.preview-paths-scroll-view-bottom-row { - flex-direction: row-reverse; - margin: -1px 0 0 3px; -} - -.preview-paths-add-button { - margin: 3px 0 0 0; - align-self: center; -} - -.preview-paths-path-row { - flex-direction: row; - flex-grow: 1; - - margin-top: 2px; - padding: 0 5px 0 2px; -} - -.preview-paths-path-row-input-field { - flex-grow: 1; - flex-shrink: 1; - - padding-left: 5px; - - white-space: normal; - -unity-text-align: middle-left; -} - -.preview-paths-path-row-remove-button { - width: 20px; - height: 20px; - margin-left: 2px; - margin-right: 1px; - padding: 1px 0 0 0; -} - -/* Generate Button */ - -.preview-generate-button { - align-self: stretch; - - height: 25px; - margin-left: 2px; -} - -/* Asset Preview List Element */ - -.preview-list { - margin-top: 10px; - flex-grow: 1; -} - -.preview-list-image { - width: 140px; - height: 160px; - margin: 5px; - padding: 5px; - justify-content: space-between; -} - -.preview-list-image:hover{ - background-color: #444444; -} - -.preview-list-image > Image { - flex-shrink: 0; - max-width: 100%; - max-height: 100%; - -unity-background-scale-mode: scale-to-fit; - align-self: center; -} - -.preview-list-image > Label { - align-self: center; - overflow: hidden; - text-overflow: ellipsis; - margin-top: 2px; - padding: 0; - -unity-text-align: middle-center; -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/Style.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/Style.uss.meta deleted file mode 100644 index 4b97f84..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/Style.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 095b74bd60b187c418dcc4cd47aa696d -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeDark.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeDark.uss deleted file mode 100644 index 6dff0dd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeDark.uss +++ /dev/null @@ -1,67 +0,0 @@ -.primary-colors { - /* Light - lighter */ - background-color: rgb(220, 220, 220); - /* Light - middle */ - background-color: rgb(200, 200, 200); - /* Light - darker */ - background-color: rgb(180, 180, 180); - - /* Dark - lighter */ - background-color: rgb(78, 78, 78); - /* Dark - middle */ - background-color: rgb(68, 68, 68); - /* Dark - darker */ - background-color: rgb(58, 58, 58); - - /* Border color - light */ - border-color: rgb(200, 200, 200); - /* Border color - dark */ - border-color: rgb(33, 33, 33); -} - -/* Asset Preview Description */ - -.asset-preview-description-hyperlink-button { - color: rgb(68, 113, 229); - border-width: 0; - background-color: rgba(0, 0, 0, 0); -} - -.asset-preview-description-hyperlink-button:hover { - color: rgb(68, 133, 229); -} - -.asset-preview-description-hyperlink-button:active { - color: rgb(68, 93, 229); -} - -/* Asset Preview Settings */ - -.preview-settings-selection-label-help-row > Image { - --unity-image: resource("d__Help@2x"); -} - -.preview-settings-selection-dropdown { - color: rgb(238, 238, 238); - background-color: rgb(88, 88, 88); - - border-width: 1px; - border-radius: 3px; - border-color: rgb(36, 36, 36); -} - -/* Preview Paths */ - -.preview-paths-scroll-view { - border-width: 1px; - border-color: rgb(33, 33, 33); - background-color: rgb(58, 58, 58); -} - -.preview-paths-scroll-view > * > .unity-scroll-view__vertical-scroller { - border-right-width: 0; -} - -.preview-paths-path-row-input-field:hover { - background-color: rgb(78, 78, 78); -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeDark.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeDark.uss.meta deleted file mode 100644 index cbc87a7..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeDark.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 1c04ee69303d45644bb3971a4e8ce952 -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeLight.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeLight.uss deleted file mode 100644 index b98e1cd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeLight.uss +++ /dev/null @@ -1,67 +0,0 @@ -.primary-colors { - /* Light - lighter */ - background-color: rgb(220, 220, 220); - /* Light - middle */ - background-color: rgb(200, 200, 200); - /* Light - darker */ - background-color: rgb(180, 180, 180); - - /* Dark - lighter */ - background-color: rgb(50, 50, 50); - /* Dark - middle */ - background-color: rgb(28, 28, 28); - /* Dark - darker */ - background-color: rgb(0, 0, 0); - - /* Border color - light */ - border-color: rgb(200, 200, 200); - /* Border color - dark */ - border-color: rgb(33, 33, 33); -} - -/* Asset Preview Description */ - -.asset-preview-description-hyperlink-button { - color: rgb(68, 113, 229); - border-width: 0; - background-color: rgba(0, 0, 0, 0); -} - -.asset-preview-description-hyperlink-button:hover { - color: rgb(68, 133, 229); -} - -.asset-preview-description-hyperlink-button:active { - color: rgb(68, 93, 229); -} - -/* Asset Preview Settings */ - -.preview-settings-selection-label-help-row > Image { - --unity-image: resource("_Help@2x"); -} - -.preview-settings-selection-dropdown { - color: rgb(9, 9, 9); - background-color: rgb(228, 228, 228); - - border-width: 1px; - border-radius: 3px; - border-color: rgb(178, 178, 178); -} - -/* Preview Paths */ - -.preview-paths-scroll-view { - border-width: 1px; - border-color: rgb(33, 33, 33); - background-color: rgb(180, 180, 180); -} - -.preview-paths-scroll-view > * > .unity-scroll-view__vertical-scroller { - border-right-width: 0; -} - -.preview-paths-path-row-input-field:hover { - background-color: rgb(200, 200, 200); -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeLight.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeLight.uss.meta deleted file mode 100644 index cbafb32..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Previews/Styles/ThemeLight.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 38ae9e6ef965cae43902ba22967938ee -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Unity.AssetStoreTools.Editor.asmdef b/Installer/Packages/com.unity.asset-store-tools/Editor/Unity.AssetStoreTools.Editor.asmdef deleted file mode 100644 index b0ba405..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Unity.AssetStoreTools.Editor.asmdef +++ /dev/null @@ -1,36 +0,0 @@ -{ - "name": "asset-store-tools-editor", - "rootNamespace": "", - "references": [ - "Unity.RenderPipelines.Universal.Runtime", - "Unity.RenderPipelines.Core.Runtime", - "Unity.RenderPipelines.HighDefinition.Runtime" - ], - "includePlatforms": [ - "Editor" - ], - "excludePlatforms": [], - "allowUnsafeCode": false, - "overrideReferences": false, - "precompiledReferences": [], - "autoReferenced": true, - "defineConstraints": [], - "versionDefines": [ - { - "name": "com.unity.render-pipelines.universal", - "expression": "1.0.0", - "define": "AST_URP_AVAILABLE" - }, - { - "name": "com.unity.render-pipelines.high-definition", - "expression": "1.0.0", - "define": "AST_HDRP_AVAILABLE" - }, - { - "name": "com.unity.render-pipelines.high-definition", - "expression": "12.0.0", - "define": "AST_HDRP_AVAILABLE_V12" - } - ], - "noEngineReferences": false -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Unity.AssetStoreTools.Editor.asmdef.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Unity.AssetStoreTools.Editor.asmdef.meta deleted file mode 100644 index 2f67bb9..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Unity.AssetStoreTools.Editor.asmdef.meta +++ /dev/null @@ -1,7 +0,0 @@ -fileFormatVersion: 2 -guid: c183be512f4485d40a3437fabd6c81cf -AssemblyDefinitionImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader.meta deleted file mode 100644 index b4b8661..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 9722d52df16aab742b26fe301782c74c -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons.meta deleted file mode 100644 index 7026063..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: ab9d0e254817f4f4589a6a378d77babc -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/account-dark.png b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/account-dark.png deleted file mode 100644 index f54f1a23228b4a5640825aee9ba25ccdc9aa5509..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 337 zcmV-X0j~auP)yr?k zO-rI1&>Ozw+QP}}WryCTG>oXY^4AV&3 z!QgoAO@>Z`NklCE2Zjf{gG~B@U4QS}`4czm~6Rg&l93aum zu2xUdTdlN0{IzJ?0>Ut~ce`CWO;Z3LEs|Q(w5%wK@5Q|BcLYh2IKwa;;dW$5E48w_ zu6wSkigBUKfLU#lzsj zUK5<)2(a31r-6yhglfV_);%~AfSWL-+n5L=$@9ELRdX{DlP#za1|MA4tqsFSV83{t zCz__23CT}m^L_sV#{*W2(Y_H*qAhCKH)URd(ht1KCfcxnJ@1Zy$>>iYDMj+0Fls2& hx$pZ7&m-c0BtNsViP-ATJE{Nx002ovPDHLkV1kx_uMGeI diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/account-light.png.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/account-light.png.meta deleted file mode 100644 index 0ff13ea..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/account-light.png.meta +++ /dev/null @@ -1,123 +0,0 @@ -fileFormatVersion: 2 -guid: 7c0661b9a6385a3488c075711f368cf4 -TextureImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 12 - mipmaps: - mipMapMode: 0 - enableMipMap: 0 - sRGBTexture: 1 - linearTexture: 0 - fadeOut: 0 - borderMipMap: 0 - mipMapsPreserveCoverage: 0 - alphaTestReferenceValue: 0.5 - mipMapFadeDistanceStart: 1 - mipMapFadeDistanceEnd: 3 - bumpmap: - convertToNormalMap: 0 - externalNormalMap: 0 - heightScale: 0.25 - normalMapFilter: 0 - isReadable: 0 - streamingMipmaps: 0 - streamingMipmapsPriority: 0 - vTOnly: 0 - ignoreMasterTextureLimit: 0 - grayScaleToAlpha: 0 - generateCubemap: 6 - cubemapConvolution: 0 - seamlessCubemap: 0 - textureFormat: 1 - maxTextureSize: 2048 - textureSettings: - serializedVersion: 2 - filterMode: 1 - aniso: 1 - mipBias: 0 - wrapU: 1 - wrapV: 1 - wrapW: 0 - nPOTScale: 0 - lightmap: 0 - compressionQuality: 50 - spriteMode: 1 - spriteExtrude: 1 - spriteMeshType: 1 - alignment: 0 - spritePivot: {x: 0.5, y: 0.5} - spritePixelsToUnits: 100 - spriteBorder: {x: 0, y: 0, z: 0, w: 0} - spriteGenerateFallbackPhysicsShape: 1 - alphaUsage: 1 - alphaIsTransparency: 1 - spriteTessellationDetail: -1 - textureType: 8 - textureShape: 1 - singleChannelComponent: 0 - flipbookRows: 1 - flipbookColumns: 1 - maxTextureSizeSet: 0 - compressionQualitySet: 0 - textureFormatSet: 0 - ignorePngGamma: 0 - applyGammaDecoding: 0 - cookieLightType: 0 - platformSettings: - - serializedVersion: 3 - buildTarget: DefaultTexturePlatform - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 1 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Standalone - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 1 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Android - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 1 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - spriteSheet: - serializedVersion: 2 - sprites: [] - outline: [] - physicsShape: [] - bones: [] - spriteID: 5e97eb03825dee720800000000000000 - internalID: 0 - vertices: [] - indices: - edges: [] - weights: [] - secondaryTextures: [] - nameFileIdTable: {} - spritePackingTag: - pSDRemoveMatte: 0 - pSDShowRemoveMatteOption: 0 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/open-in-browser.png b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/open-in-browser.png deleted file mode 100644 index 245875b4df64816f61a939405c6b33a38d121bab..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 878 zcmeAS@N?(olHy`uVBq!ia0vp^4nXY4!3HD~O&3)IDb50q$YKTtZeb8+WSBKa0w~B> z9OUlAu@o*EE*xDJt>D=)@v-`? z9Y(&&JQ_@AxD2nH)ky#UaHWxQugvjBt2DIceN>rwcRS?X2=EMfWO!$(fz{ExnyPo1A`$Daa~mnlJ9xN%rAp~Qd7K7uYU@)D zZ+Ntil;O+8?1D2vov_A4k3n(7!7Cw;>@zo%dHMA?eCi3?2jq!RN=}X=-t@zfT zB58HRc-wy7v=>6>Bk~*kKK5K?dm(l{BHKask)$^73U8a_xs1DxD4*S{qraNxLd+*& zzxpB_&J#i<;nj6_kJ-BIaPQgU^u+Y}{D)x@0pYX7U#kC?H@?U6>dl7~3DW~xDvqsS zTz1s>7|($}%Kpu*n~F<2(|yXCE=fKwKGMB%uYbktvuU%d_udPcdMtwXK+c7=GfJx# zF@5ALtL(~es8O>JTYX8=xZ!x}ywXMW+4Y+L)Y8L#iyNOdcoa1C#EbU~ie)aM3>%k< z6-pT@E}DFep=b^o^xpZthuS!u##^EyIIjyd?>ic4%eUhs7up8WW(0!P}3 z8O_tY>W{|@?>Y3xxr}L7+NvY-Is^jaZkSZe)a_ctzv^|($F1My+>`g5*S*Pa!sE{> z@&cwaqo?dEN}X|%=Ygq}VA!Of!;Nh#Id+^mx_N=-zZ6%NfSNPHB^kntK1|x9TJIud uuF-aYkv%w}+Oh0&$F1Eu!j*^qu))-?O^PXer>b~ylzTf}*JfBw|%lyvu*uKYdp1*EcoHpLfC&ssK-MY;u zOpGkot=ouQw{E=_?*{M$dJ*~*{MzVcVvAX~4zid1z25(sp6|MKf;R4F&tuP(*)O`Fp`#kO-`lGs4Z?Q%8Edge)!P?y4hgqh_XP=4FVu7wN-t*0xc?GFVLpb%KNlt0SD69e_vkzSq`3jSt4R*;rj?t(??NFQY{ zD0SYBjgZoSD9XDiDk@58XhB@z&TtoJ=fhIUipoj~imD1qs`848P!%nxs;boL zmo!+;+w~&U(&+f=V&IdG^d&6T3#y>t=jR9UQ-Pqp-4v9xw6qiyl@*kgTz>NReRT)hD=d826bgs7d02S%i4G&w2KehOxWXBkiZq~0_OP5JE)qotFxM` z64gdgm77*R&i?~Lmlp);4>f^f&bedUojnldz6ftG_Eb93 z$Kf6r#J_Yo>kaqBc)`69o-P6Z>~-1#s1(?;lC%`iQz+P-tB(r;*yIY1S^yaIaCi2G zdk07}TGqfupM&-}vCkzdLQ;D%OHjp}T%uroPOI=-F8KT67N1)PJ zcdQ3u6>E=rU|0Y0aAzAH)C2AbEZkpyjgPw4PN&drXs5HvP8L4S9`2Y+2yY9tHx};U zWN_^4Q721xmrDj7z_B=)dZJyB0B5xo*pTbt4(46{Yh?+AKNbdR2Ncl=;qC5=a6Rsg zMoBHhA=Ld}R8v_Ku8dGt1F8vhR9;m}6)vx-qNOUY;;iMYUf}tzg3g1 z+O9y4{=bYz|DP-43IRaO|Ei1%fEO!7o48{D>;|mz+zN5!Z|*OnIu!20R%RV(3>@%= zO&Ease`SoOvZ98Xx|XuMx~n2wUR4o5j;0H+UPUz*O=X0NmYVBD)wS_{mk?me6_ip2 zJ;I=>aOx?T3XKP8d?Y~7Z+glD+~Tf&~MoN z6CnRng8myw{^ta_pgn>8WB-;CFmpHvi4fkvrZ2L!8t&!g;qC%w3sk`ijlr%2B~nWZ045^iwq?V^z_WY~8*kQYl zv?ANtE)QLH)o_qk{0lSKv7|8+v%II3*^NQ)gTSoLhh3h^!qVLEn3dJqv*mb0Nl_6* z1njTX$Ef940C@b>&)#e}R#wqi{pjY6Saty`ag#CB*~5n&I;j6?Q2%W&mO6@3#^BpP zXKj`L+YPPFv$~zNk1M-TT;9w-p4l+*m zOuuto@Zop13|zX7v^U6wO|}c!uUm(?e!}SJS^w724%o|GCn{uq+FgrF-G6E0>aSu> z`J*q1sI z6?Bk^+t(Ve4u@}PL1{&dt3|VF2kOWa?oaA=zlUa8^1{E8XC`#b`tT(IKf84D5ifjx z4?Q$Zv}q5oR*Tj%oO(|tqiY(?4T3|~JRKk?>bSpB4UM@pi*)>=cV=$JG$Pi*t`{ zf(u|GXB$7S4b}f;z?-yo{PIJ}%savq zJ#+lls9aYsWN?0(xbcal@Z1q~VLaK&J}&S#Azs8K`t6eYH^4}g&|LCD!56yj+O$8- zac_r&zJaactiIur6Ow-mWIN4qff9!?F&CZ-(%2X>NZ8#HxPNWf+2=vEPWA$OV1Uf7 zeTy9>zP7{9)*3B}#_~f@KWPzhvh z*ww8*#BpTJ!My)WcVZ3NdE z`JV>i9PNG6AZC3~)S;|;oc#bnX06dbd`rc1JkD_oRqTypA|Gw~8-6@NZqr(`V``9@ zqkUbPqgmfP>JXug;FJSHtTj%Ajph5Jw74FBq_=1GpqU=sFW0R6>Jbv<=f<5Iv1YD+ z=ywCn5l@M`;}ES+34`R)#MdTzu*2YdLH|C}eGReqG4|&Or`H-@ZZ&vRh)_5J8eSPv z%waie4cp|x6lvFu9Ek@SV(*|RXjs|rmi=L`#+=+D^ldyz>w2oJ`BxkCXAF32mgqjb z*nYyMeGpjl+5p!Kd|A)w4JN5s`apkS{lA~532uV*g>aEhqSGNo)Z09(4N@ln*s$!N zT%^lixkV_1khK91zLtd$J*CF~A`Bsali<B!qGA7Z5N(pIYTmLo(s*Xm3^F9TJzhj?pp!1xD*N>FPmeBcx>{6}2ONTj~V z*C!>kFPGM2_x3s)OY*%=(Hi1D@S@6Wnoqo;w^M&Nrx@_&E!{G6Bx*9P63^`|EX&A! z25*B!9N)XT;?>Up|8e(k4mmiJohK8R`l;yokXK5F)>b~78T8DFMbdblZ`%Lq6f>r^ z;IXTBhj3%u@q=qK@J**BC4KqQC-CBiZ)?4p$c$-4IdW6_n!@X+ktp*4Ih}nZiakMP zNWqlYd&(f@vsL>V_e8H=I4uMz-hgSXFWt(ujq5ivVoRa*SyLNEOdXqttdrKdJERMC zc_5r*{0_+nH-@By-@hQ_TO7f)w&9mQ>HeQe9k0Or_3Q&8-NcBKs>5q-`!a)s&a#XS zJa5+7i8^)Z6X;!gy)!VbOJnQZdZT{MH)JA35;CN7ejdXv6q)jp3Ae+10uApJ}iEBz#|a zI4fCdaHIDcIS9TzUlz7(Z5*z^ZqoVn0p~}g?fdFC7`SiUy1hgmvHc$Nl5QQ_kS8r| zvjo4Ab5t5H)zjCZiV356XB;FQU!HhdbbcE8SyNCyA4!udugNCkA6sd^3K92+Dqw9Y zEBBnw5YORvAr4n}9J}%@R;G}S1+MtG1JA^?pu!B3gx@b-`4Kt2=Wz2yp;4{(jf;Z$ zIQ84K%E-rDckeW7+8VFFz??6vCsXs*DetWJ8yeh3%Tn1UsT<7eL=LfzZB$FGy$a`f z5P7u+8#31)KQY!(@+_HG@#A~{1by2}o24cvAJ9T9-q19JfRBqNn1wo{N!TOxL; zZ4?#R{n5^Ny+zx6KAExc%4U`L?`8fHSF|N6>-AXTAq%4#)|!N*6HafAB3d#GcYdml zlB{eiL|3xromg3Nre#}FA4RG~*y|7X?yp>&4;I#TkB1Y%3K*+U$jMa_+Vk!`rkz>$ zuqb4d;aexz&RKG}>T`K*8C`vx=GhqWZXD*M8>CRM3ET0IG2Rtno}!y@n-rYi*%~L~q@cvKv?YVb`;Lew=_ji1?Q7FjNz-&{cK& z$WcfrYNQA3G1B66O8Z(Ro!kzF;wbFp8fiy)n5w>eY z^zf8?887y|eloSD{cP%;2lHO(GV6P#6?lCUsyXgA&*ul(H6cF)6?^Z_|4MsH z+F&_)y?dN!+wPw8b^d)v#$P$CnTX_FRMJ7#5`$bxAv&48JN4ycu?eZK*OtO8QE(~` z4l?N4bj^VSwyqzQZJWvgq;YEM4I!bkTA1=&Kfd^dzQ{9r_i;0hs$<#dZ%N0^EbSym z#?MqZG}7;UNGkohSfV%aP2a}mbVg$#g*cg%^XYtn$ccC;YV4_G)(nkEzEOzoaugmA zqH-KSy3}%P2V8O$>mbhT2$YI)_y-*U&+>e>ou{M{fLR%9o97+V^bw-BOyyAWsVa zhwseZnV4@a_$5K&#uYK)gLLe}PXz9|gK#`tGr}XlQ)WuAo+cwE}5TU?^?r!IR zaexK=Z&`>S>T7D#QBb#q9|s76ZGs!_-r+|*)41lddH!cuC}GOX|3K+4>pS(|d4^{M z8TCH~1K>LH<8$LgC^E2Wu(e~p_l^nf>74y+(8pzYTFs6YcAZSVAkVL1y*Ycz(h$a) ztH)OWP>SFOO5a~{eg{>ET5*0)1JKdpd-1$JXJ$&V1hX*@+Gc|5n;~Q7XYk@sAmSyk#tnc>vFgRjCKRor zv6I8^SKWr^RoGgmPe=@;zqChSHmJbMdR{hC9y={M-zM?SoHBDI&S2_b2>?5b3tQqKfs0- zL-m4O{JL06?-}-8Wq9Ke*}}YoQAm}cy_vu&zr z>L!IoP{#*xF^-?!PI*sVO04@4^4qt(w=s=;T7RgMe8rS@~; zp9jr1&B>gl-wlNFJFsksqn_M9JtMxI+dJ|C^%oDx)3I{4yE0;ePNN9PoZD1sX3dG* zN_1H4k9Vp_)IeA9Vt^cq{~?F#_X3#bAKGh8?~nDVIahDA0(l$@%aG@MhL(wQre!82 zZ=@4|_EnEuhjsRsylt3R(62FGYM*&A9&MMJRez_wi1{=Z_P+d=%}>v}YdDA|Gvk8P z2b|YC)uxi_biU9hd#fjAM%!}P0Me@v$4!z*QRH2d&9Ca3Js<_C&Q1|j>s~OECxv%a9(}-lt3yjzJe2$Xs?y_BWXVI*qB_#8BSmn z%mqd_qYGcJ^WCQ)_x#8OQt4Dt=}7R>qE=}T!*hgf|Fgg@2-ULu957KiE)o|hb#c-% zl{N&m3)gepi{BYgrrl_mMd2>&!J5;FUj79g#25eNO15Ero?n^2)a%5LE#c?Eudophx#dexE$2Qjk_|k3Ezz|sNywk%ZV=>FJz}zvU)ry3^t(c5+J}r}e zlXigU7{t3K(5j>e)47~19xzkSW4|uUY{a9$Y zprmdXhsXZGyyW{Dd!{IIOY<~hcWt7ERRl1dDz@q9=)$+GS#5t*JO_*tRqT?D-x27Z z{|~_bFibf^i*7kH@b<#!Rb5e)1~vZ+!`ut{3mM943Yi&|oAi3sfOW_sU}Fiw?T?J9 zazk7s&y$R^X*K(4+O=kny-=E;t67Wnth;kHw-4xsEQ&5oM&X}s=@X)g;d2i+_%Oqc zt{KlmB}YCi%*ij$o-CtMzppu`$VtU2h_4ejK?=s&IVw3q=fE=PZU?pkwhGQd~05rP> z{pzj?)MsW`%`Rl^LdSmqytp#}=_s3R!RPrum8jo3f06`v^J^T>IugvBS7ThD=vM7* z@wXmK>5zEp-NY?XBHOzESKzTwg1bl!2Q125l#8Tzju#-?(YfAd`V>Wa(M^9*cwSze z?*0aZ=jFqxZ&qOKQt+F595gYt6JxlEl2;Z_0FLa%drmc_+?nLcT^h%^ry@0)m#lZJ zL`Z02jGVr3vcJfIbp8isqJzwVuZwJz7;P(jv4O1;PKWKqb^oanmCcARl{dpX?O=Ez zsz;rI_7jfQ5{j~W-u&21borr|Y5XOS1g zCouv*8u+EDlCR!KnLs&qsBoMY+tHb4Yy6$ZPIuDHd?y#FrEqC+FUHLDgxM#BtU9xEY@Jv|^!DqplIm~4r7vUrqTaR*bRG>^nj4%Ls7-9I zV52GIzoDsVC_$4>ic)+}X!fwi{c|f%oOkD+$-4l%t}D8yAz$*B@gs9?(mc;(Hd-fO z_#NJFSl@VgGnKSld2}yT8js4{8mU$oKGLYo*WrVXb<=T0gv?1cdp-Qo@^>Be+Ok%ytJ`*h#9Jue*DvsybuXX9s+@ zkLB+TNq`O6jBw`gyv!KjPMItYCA7I&Pq{6Ywe3mC4nRV#EY09Qg0iDkCmAoPi<^HK z^eW4Al%35<>^rUHcdb4}FT!uUvtRu8cIMfz`eLRZrRR7GR50bn)zI10r@9`=>qJE&qv~I@MY6+7{bAh1Y2G>Q9^Hne7iGy@9598zo)*&- zD*b&|{!&|4Y|sj_PXHtbLW)2~nf2~Z3X~X9Do7uiM^Pd+@q+j#k_`MVDWpQGfqMu> z=77Cba{;xTQc~n3?N{vMoaZcFtSx)_H@}z9>6&^=%gndqrio3zOI!Gvq>@0FV-al0 zB3N`lcUQju$T-PrKw&m0h2Hgku_Wb8ga+njO-ksPB?t(K@WqL4!`XQ{a_k);={++K zij4^}Wc{j9V8i?V@HKevz*lagUehKz{pLn)K-Rgep(7lymRted137|;vg@jj_4b|x zLBPsZc!4bR21-9>oa)poVAK&$va^yD{F0UfB>sMJ4N~&cIWIRy_8}}L1907K*P||W_^N{>y*2fgHM&G-y&*-*Y*B2Il14bRMNi;YL&HY6zPJUa}LP_ zy%6&G_JBuUf0gK2c>nFeVJ1^2k6dA7O~C3R8Ot90o}Bh?4?a$pYv7)9{4M20Xy+pl zrS4J({Ib7T1A`O0iEKBu!JB%$d%;G*x5WR+< zW#JUGG`F0_wq{6vhMZ5_C%XCdzG`H*e8DIxPOs(zzAnL-5NauAabyPk4)H%Ogo z;f%{~ZtL!CK=6C9oz1GsWMsQx4!#0W^W9FK@r^#)S*dB!3vU;bLtX_<>%C;7#S%yj zB8X1p0f~{}Z_!gWQsMlsv`(Uo<(r!9d2Yo}E^GlJ$08!kqGKY1s zjipo5E{P5GG2^B^SZI-{82l-Ua*5;7+B| zh`;LbODZ7aJ_y1Wt@!FrdeZC@41&cVvo?=+mI?O=Q6FE<9kCc)x^fH{Wa)2xy)qnt z$VU7XFsJ-&Fpv_Eg+Fg7&#BPC;S|EzB z3~Hp%_d6f)6c2XtNg6%=oeUXHj&={KALA;KJd|Zg*c(b18F+7-lRnno<{Xt4Z_g+W zcZ{#~CnY;;=M#1Y6W);MoMBdBb6>m9;cd5BqJPleEs;EvbI)lV==wajlRo{r404n} zj>j`;PF;>E@x}3eH?Hu^8P>(N(W8Klp6~}II1EhCrtcW|Av9WCK1i{Timf8Pd5uD^ zLTc87>o<>(CrS&x@O2pBP-TaO##Cz7>osPl*pJD!rhl4g<~oRmGI(x$f^lwDZ>Z*r z)7J2Ro%u>ogOkxVYBU-!#zN8h7sg*CnjG!AJhoHoZf#-fe5(|~Z#Qb>jJ!WH$ZCPzU=f(m^|k{P2IA4JEcU^e+}br+wE z!Q9mPI*C=st_%DtSMK1g8S>eRu`343grPlSS2T!C?HkMoNCy`bryF71g%S!d|G~np zkQ%10S3;m=hr(S2Et{Uz!YFqE7s=8NL~O?#_ie&P`kLgbd@@emROCIfh5E8js^ZDv zVP+mEWRT}dHw}H3G1=3gb{SSLq$gVYTF-nZm9HLu>{C+&oF;kbL3e(f^{!{C>I}>S z(W&*J5L)KpmNQ$)6i8n2?W-d+y&CCrCFZKY#p#4Zj;lCCWji!(J8_8?u$+#v!L>`U z&PDJdyvX?c=>c}O(NW@e&5i?h5E6&dH*(yUAxh=LGrh5&U(37pPH*{!)0tF%I*GhC zdNV~QHgft5P2nkn7Aq4osoREheG8?ke^d7xc9vY4r`KmcD2~;)+0V0;118vVN1wvP z)S@o#s;_y!kf3j~2(8;Q9fP8}zSOt*IL<@Ju$UG6##hvGysN9;$75_zT8RPYCS|9; zK5u+%R=1evvVc|xO=ze2U~Zev)KtDR2W(GS#-|+`HbT^%Llt%ka)VP^!E?X%Z&QTZ z8cEzA*fZsq={wq;Q6VX(#y^%~B5eo6j;C7=zpr$UbW z=zjXX-F{AVWlCIV} zr2b6NY76zY*106UtZ(}UPaaLZgXDEDD_yAvM+j}m8*NAoFBC|4JyWAV4%0w)^15xr zJ}W<8uzqVmw03I$)h?wPeH$4-!QsB^`Zh|Ns@>|6Eb~79l#awrA8A=eEITn;5EE=myqKc6;rst{2a#hhM=IwTErAN zK#B!jJ4C+otMVdP2ddb<8Nb*oX<*9%QwvkQT{_1TO6Z$Ebt7V12kr_g+rRl5`Fpre z_PnWAcd2P`w)wO2x{bI&jQ@N*wqv&7fS0Fr?QzeenC!|h08Ot@F9osTddXoJh=;(} z$OV%Z!HEt>Ln{_A={!G)e20qJB@cI%C-gxfe20v zM-04H{P|#0_rqbP=UFd z%Fa0{CnrD8^k1k;=TR@*?$|ZBZQ#wa9=UF|sT;&BhuNI1OU1ixq+K;u3Yq)W-xkvn z_KJ&ih~Ir%z?2{d?9+6Dfxtl$_el1yT!U2P(|Oa0b(a#Tnq-sAdpq_9cXe=1(SNA0 z78XKK@%?EIefOiT-@Gy?$pIV6H;V(?G(I46OX&zN_F3So#B`r3Tv32)X^H5a2lgsY z*-rkals^Gl zo@u)JqGbKH+@F~Bmgp`a+|cCOjMvVkVF$;xwqwU7v722Bpr5~&C%wvv=Podd4JF*4 zi>e_!iXwPG2g!RR!iovW_4~e=KmOc?{l)o8#KA58Gcgyod3_ic0h}ArG6$Qc?!UW* z>#MhGl-rTweX>8<=9B-ShV4B(qzXwmgfjac(<;^QK`rc6&%?17p!$nD1h;4lTe<~f zUg+xhUay6J0r6stbsTvo2dZcU4)oH|ROByRD{6NuHD*z&!TNSQ7ir)YZU*yLZ}6e1 zhFadl!|@SIwIQcFwJln@>xBIl$m7}rep{%AJOzRhNXb@-G2jY-2$jz#yx7y;{CoX_ z4s0F5Q2Qz4_UOxb%*`#JWy3USuJ7=qq6q%GS^JJN)dNPYc0iGawdld0(~>LSo4dW1 zbYL!%v4M0=kpj!O&q%ao*Bl@2VVeTEtR-p)2Wpdxpu)gm!>-eFcP(Dmr#!_ypQy~Q zd9<=~!vUW{6OX&*2dCAe7GWBGOJ&UMI0UYK!>AvRHwR2WT81=pjy;%CU~4jdE6%z- z5zMirH`DOjM!^%6Z$k-T42h~&=F=fXNr9sbeJ%6Z1Yh9-<2SilPlelsfe8nmzUpj} zXp+(xvspNScvd@^4;xMmB{YUPjV^xFcKog@6VSV`q`I*qKrK+;a@$mjW#>9c20PHga3aB;cbIlVyDF zId^F}rXt@5eCwVO>$_dAMfPEi8$V`vX6J0BT9&WH_63s0(T@7hu+1JRHw~a;)OnqdejddkPwzGBcG|o`_z2MW7 z`SK#s36=TRrPBILL5=PuinHL?8*TC8A>l(6M+*fD-EOt>RL_2`E+@-ezc`JLmxR>!mq0yG3~ffwgItQ&G)7=Rq4_Q<>)wipp`RQ<#9AaQXwr>wqHh*tp#8| zAE%z0>eb~)&#)4UzwPhwdt`4PqkS}MvPKV__Dl>l${Ih}%3KTh2}0CExLglT>CSgw z8{#-as-JSegby!Sy&_y%;fL=nTtt9$??QGQbR%By6Ct^%E-tEFc5Gq$z>x2O)T=?P z`{G9L$up;g3+b=lsvpvA*go{OyB*E1z%yTdCnRt2$*_2OliA>VJ^Q;8^^qN-Ja?FW z=Z(kOvQEu=3Ex-AXX_~x`o6(+d+a=e4;oZuS%lKkd_5Dt17)SEMHp&mJ+{v@4a{Q9iVd9i%of45I zJAhM~AA<}cAD`qsZ)USZC*s4w0jcJ&xP?s$IOU760HK&XI}Dl>xObyKeBy|VFm+ht zuEO?CPsm;_s6g>O!K10Pe0rhD$Po{ron2M|LO(@`_N7Pa>e+noTPo~u!A;b$B>0LL zB0h=<7nlOL(NP&s8X^>RHZT>bcHwG|@^RjaVTN;GtFwWh{ML$+l;LYWYZDO zG^3US>D*z*#UlPHYzte^t3BH#@7*TvU4{H>G4#uO9v4 z)*hD0FL7nOrKjlN#_X7g1aF5UMzaLNt|JNuM}#BvLf$G)ixxEToOpbpdHQ#eDQj=N z&HU;q6W2>{qsZ=X+f`9NL-SPHcqqZ@LtzqbKREQFaP=acDJ=)1Cv{>sXVmg`?v^E@%{KS9?}i!_4tDVgA34`ICH0a z(=aZQ<5KaBkjG#4-(3t#GA_5d8}LK@y6%%^Q7lp%YP{%KYs6G+i9rbLNs`@G&1-RQ zhmokahlIQ2NJA8=b}zzjFlZyz);Kbt>j(dI@x|!DjD;7~Uza4dPL<<7zf$P9n~`W# zZ52xBCJ)LOl++2$hvbD4r;>C{zJ%E>e%U zIEegpLc2(uACBk?Q(x*fzbX$SI|h-8UJLq~Z-KR?7u*xOB2g+z&HF%-d}3vfq*L6p z%bubxQif~&18=D&dlE*|aYxjOo85X`8XEKt|BzXPMTj>J%u9Vbv~P=#XU$9bngUf+ zao;>_waD5xJGE06za-vS78D;e>rUZLZGC;Y=0s}NZSEv}n~+TxLm?9F*_juBaX*%6 zP%|9~%9fRAv$@q&>Hc*5$k|k+?`T)bk20rJImeD-xoq zO4RoThlCR1@r1^!xPWNtY|IyAfUrZlgXN~6Fn^+=Q`DkP!PeG8pOA;Y!4Yn;XV$?# z>bHg59d{g($oDz>MC)zpLe!qlDE^r}X|jy=Jn{~tz^l(xI~{%p!G-(onfVX&ZDMHJ z=$-(}bioJN92E{Qf28l=k=nM`^>aZ<^=?FX@LOd>z5%etyhS&ANS(aEJfr1>35It|Vf1n(K3 z=jartN^mOdEpWsqG^g1RSHSEN3x%-HLp=oVagm0xkYKhTAr1K_M@qiPh_}_>YI+y^ zSJ01{TQrZkw>mxO#5>*N=J+-duW=EoSovv@XhPaC4t5q%#zh(vSKim@m}>xw_?Tj! zN<*Z$CmEIq%;Fd?B>AI?j%$S*rC183;qQ^o@m7*`56l&iG6Zh$`>5?~*LW!?;o5Y( z<&2)uW;6K>vmS=^dL`qnFVf)X zbH(Q4u=f{Ecqd~0${GE)F0>ei5=wT7)(SK3o2_R6jqKKV=X_Tu!>BdT_Cn%DEW&rQ zF~5)e-jItxS#i%{W-cvnk0w6BE5?}VALyIoBf}z5+lwUzZgpumHkQw1RHOFNGX1AY zrq-pPs2Mk420g@=xTg?sDs^rrEK6Yw|12_NI~S>r6V^L*k~kizYx3YSFP7egX<`0& zLZ&T8hn}xwQuOcwdP}n|W9u_u4Csf!X>gf~Ew96Dd41om4bB72c2QepreQO}k+c_0 z?*e7cuzxfQD;vMjf*6sWugUc zlSODBcHGx$etRQtcsFNz+s72Yk3lC3j)vLOm716?@w2$zm*wXx#AGXVhL7Wp+Z(G9 z7agV)7p*Ge5(=9e(g>I@SKKNlu{J&acHWO<_!$KeGQBf88Jz_jFo$Px`jnjUBj}nv zgX4>99s@=kHEa-niW9YIoDZ}%BE#E1_ zEvOIbHx|p=nE7*&4ui9~*HBF%s&uP?4TufpzRo*DYCq2qx@6ivrkFKy@~LmV%*j5@_nCsB_*>pk=E`qPh?Ve2ZF28%tV z_djXcesNIXXKcHNt8l@5P5WFilZk{Ge^@+o%8l{4USm2q*#7*&D33(M#qhfsaxP8< zp#;;>-T*xaxy34Q z?>pF<_5~E+1rViBUp=p~FMETJhZ3R}LZ0ISk}vDsD?0weO?QdExaIuu`MZYUb*J^V zU3?p&V?LX=5!0V*4C{qn-Wjl)K8(ctRM*}1{e~eq#6SLBz8%xw?lN1)(jO$K-z!1y zYxrP&SrAM2QAE~21_Ni8k8st(wT5*W=6cMBK{wsI;%pQ^-FaCenrw;8Uo!?0q1A0@ z+#fxTc`===l{itZj!$I@MuoqgXAuH^lI2Hj^4a$un4=FDEO?U9m zASR^3Z5vgraNJ3GtlqG;t7YdGIfY`$z;Jl7vzN>E?y1c?HRZ$iM9g?_cGGrCg1!7>DmIvff1gyEX6)fS#Q~GK%K@`x#~xd8oc3&rPA83>92wjz z0YQ`{Y+ag-?U;*>Y&OKBFU^;GzjRNBrP5v^vvwXl5GYW2BZ>QJPwi$5KNgkW>kpR- zC5YgX&0hMbSvpA!Z_Fy;S~$_v@FNUWVD2Na{YH@Y$y`k7ddlrQenRnymgh5>Iq5Rz zjmw~l+FlEueCRgRXXL}^s>b|Wg#~?zquy*DY2!i z6wjsAV~|=V{r2^)b}rH>QEt)$Js=$Cho8#9O({we6!!3YeadXzi_**9NgtV``Q}!n zhk-x$G|>OL;wn;w>*+f5jxCk~wGAXk+{akzp6>n43t%Lb(syub!OSE_Ksx(O9e1Q& z;doKfdkr9&6c zA(ly|cfkX?q|;br;(YA`Ok{V`dv;EYoi{o}sSJ2J8JzNwk+k1GCFqly?@)F71HoKz zew|LI=cJS|VH61XDf*G21fR6tA2Q8I3viT5e;hRR%4Z8a@-^hr$j;%PEX9dIXhN4x z3BmV8&Xn}{Ce8P!h><7ljpgST<__K+zyI-(#mM|nD0J5^9av(PsPi9GT~Y=R;mc0Uey zQ2K4|qpadVo8YcvCNv*Rx;T`58|9d8A1>zuZ|~gx(D7pP*$}_Hcfmy&gwxETVu;p9 zpDf5qeeuhyk+$H(x0=ECzB0s3jFNT@Y@bNB zNdQxVp^v=Za9Pq(6ET4k36I};Mj@%MTO$8_>1@GnhuffX~z-48$(Ey_{#!P zXr5?+gojo`j0zJF1x<)$$~WXgf={(QKM%?|G1JW05N#?n@FTssZjbLY?NVkwe9CbD zhRc3*nAT zDtV@ukTs2$k`FozisZ!|Qg{D&z+-R2cKT8R01tsNM8=-`$5^`DRX&G&9tr?qG8qFO!T1 zUK0}h$I1?7MmjN}S8(_Hc(E{Rx4f~g+Tu=jQo%mGKcG^-TJ}|9SbQsxPdC4`YCGD% zc1S%o{7NF>w<1W7E7&IUrmD!=0EbI{x4|wpB6E9PPNviswF|&mmTtJrheaLQNxAWu z$5CkER6ej;zJBYVhI2JO{a#b=>Xn;>Eq!C@lWA4S$0~xvkm+F>kf8yP`p$(ICTLeyubQu3T3Y%B#r}vP_j+| z_nqL|s3(5`w|8xQu>3Ok+n%@0Z$1kUuMuOPU+Cd_r1oJLPEV<6QTEZvtM(~5i zD*DVY^b};9NVi?iMObVb>0%G&0pciXaac!anX{WMBWensc;{3$4sFu~wYitky%Z<> zW^`xiC#^87XHDNGTqr~s_}xAM5HC8GOFfBdYRS7_Wfkm=^;HZW6pc{_>&8B zTaYiToGA`pDaks+!zdol#I>AaV24L&x@3u}|#uz|FrWmB#T9qu7&@t2}1MgEYjsR{K;rMtRaZO%3x* za=n!UcGKpw8imdk6E32Y%^DoAGvg^*T%>ccktoAjZpJe-R91}Ix>>sg(moke{5)=0 z_HrsR)8@|EWfKd!Fzb#3wKE;61qO1~8~2VQ}g9m+`Y7L*umebCf*EVU-=OsZV*b#U_hUgMN- z>2ofU@_1XqU7rl2`D&T&%_eD~fdl7G^=kXReS0*xX~At6gks??Z8FbD!qmqjQWlwV zxjyOhw?LeEh`;#do0NLX7vxZe>df)n%OI%R(x0sRv%R;kRdm|D_|AKR^{CvbbR0M7 zW3;}_o4};P{`;7YCE$nzzzZl$&oJsW$Bvj%W$<3up5}&V{rHU_;mHCQaFC?hn?Hf0kNdE2h$uD%Z#KogNrn3 zkr#V>^)k-xT-#}$u1Uf*TR6i6DCu}-{mry~#cp8*P)k_eX^!0Pt{Wr@al`Cka8Zlp zka5%HN-QPpddzE@EI;E-=k@YrBTe+j{EjaN&ea0IZJG{B-(*vrs;Aj5>zh-TpQ8m& z8--G%QdZQ{PDcY&K#RaS~k-D<^-z$El;A6t|=;%@ZJ2Z4ue%S!Xy4< zn}r^yql#HS4tL+j$AIxFW^49Koy)XLTB~=aezt5J%Q|COD;x3yTV4-@g%=F{L41g6k`6Q?~(EXDG8X8{Y(35@CngWoYHjNaYP- zs*Zczr|`1;p!R#uTL(4m&q*f*O$9$KaCoNdc6dZ==Vb{E^FBMe(Y$1sJ0G$JksXwvYvK*k z$`?~0cm;-8bFlgXTMGf}q+&oV`AUxPC5G+E?UvucO98PnkNhB+_2a^`htvyyl`>RH zJw1Mey-%L+xvw$IROtr@)H8{S{TzHcRW568v|O@sP)`x7=iX%A1g1k?z~Npkj6=g` z_#Kt(+a!E8(lWo|x2XIKPQQXMDn1@}EBIdIx$VynUP=4Rn4ES>> z!R$kCn{@0PIJ0g}L8(uQ4+hKqw5DqtgVGOh^15hG?eAsjCsNI~Yx(6F!$zQ&t@Z6m zojoH~V&=60{pO9P~tu8hy)(G^ImEWO1~vz_(y)65&+U;YJRVgJn!C8%~{y<8;k&Mkts z$|TB(#OEvrOpp?|Y2aYYNkEoDJc@!MWC=S(0<;yAzCbU(y;}Jtb}K@l(6rAk326;~ ze5&Y6}%|`z;4Ax2{}k`;vQtqUFj zJ@7W|QDp!qy)x=uIbl^rs*btR4fNr9O;gwMsRs+6mt^|-?Lh1fZh|yr^%XLi88gar zt>59#bcVlxi|!6BXI_Ne8`0RO2Tn$c^~`JsrzR-Eg}w*53&D#Y;P&3@(buPk)b8Hm zCP7d?9)2HN(Jyy)iq`LU;IU=da+J`oH1q5gZzpW-hsefYU!wh+cXo?Ma|%GF4V-Ml zIM2e@3KBTra8Q50pk@AzN5ou{&Qz+gQRBlt!|mQ*Q2)+p;8|2HI|UmFXMK`G?j0*^ zR-~v6cAxe_O5O-+eWM?*dsE-$8%l*%o}y3jLr~&uU!Wijhzjt=@fYcH;C9b|V_1O* zcsb^!Rztp7>TumoJlMyV1yF{6mcwS_$uWi*UvHv55Ci_qJDmv6Nl2W*+GRCBCJh!ftLr_xy%)i%dk%^!ELAB*?0rR%L^6t+U7r1f;ya+ zKlZBpe%X$KZ3`OLXU z;^ziRKn$)1J2I9X^ZI+1!!7_V%9)AQde0q{Q^*dEM+(82%{_gaf>Cv3O#%3CAj;*Z z#M-P^;*|tWLH64w?4{bP$hOkBi^;ZnPLGmY@u0B#t%U>Dzkzgao_T?mSShE+zO}2a zYrTbEt873~B|7BWHtm*EyQ$J(Q{BIh<0n!^ zp=5{BkYuEA+d>-l&Nw6_j(r?i$4C;9N+RnVSy@L}acoL9StnaI$4DFp$M`+ZQN8c` z`}sXQ9{zBg*YkQ^dp@t^?2fN}{O2B*IzKYktiG|E?b$~GV}0?H$feHWtTK6;{cvCU zCwV@L{L}1qWaykuNP?Yz-wCP*0#~B>mv*S2pq8F9q=eHWw}^ql`}RsvFP!GU%heOO z5+&mS+{+<@0>)ypAVfy77N=fGD)o(N`|RW>XNY=8v{5(p-R7L+%1)x#bVF6{C3?VV zir@xN3J1VJB4M8cY>z~Ix2xleT50F^Q~R}JfmSyo`^7Os%Ru!GFfTJ1OU4{5$9g8% zm9Te%_onqY-Dw*&uyN<1tW0-UxpBY7P(y=0!Mm{UfikD|1lB}5*SZM!E5HhdKdAQx zg&xC2C&B+ic+A9I`on>Rc7E+pDiqxLzTRh0H~9C_!^}(p+YSm}c7jhs8|c3?kcGcV zlg>jrx7D9q4%qYb$Y6PxU+}gxGBPs;XLs!yMt@`Cu-IzcVlKtj-5Xd*^hK)+fgwgR z&wKoRV?)yYZdh*eigYGpviI;k>Hl%OI~mn}DiyN14_YK&@AP1H;Qq`nloajhd0_{! z%(DeIocwajd6MQn4_m{|J6liKrxW_~1>lx97EmnXTm`?8ts%<`hVVdjnWAw1$LyGi zF}Wazq5D5MrS6~mLQYB-6_bUa31GeD$;RR`cD5dxNfmr1lX+z>3%ID3H{A6>e}hor zD5z{TS5pqoaiknd83B!xVs7uR0Ggx2>hMtmP|UR@~|BDy_y-* zvz@K*E3e*7gNBuT0XI$^Wn!Cku-F74T=SfEf`76Xz5U?1@7nQ?NDV;IU+b&BufBC6 zdQsNo##A*Q)+j-j*!PCTGN+-t4u3^s4;`$c$Q#K!68`P~;enSDhNc!f(=5!#X0uZ* z4r15v2j=1PV?9$r9mQ`q;DGhL;h zN<$0*9ae%TPu+9GrWm|Z)VZ|~fWF+fyR7*Xrt2dMihnoI zIdPsRW-kUR8MCr9oTY}QZ--w_VUAET{(>{ILW1Vr<;!mKnN|`+zl=f>4>b`^!2viQ zj~>lj;R5Gnlg2b_@UNTw-0Of847KZnYCIR-2xE#2zxA6jQY;FmeV&z$-jzcHgl`~A ztP`0gCBGh@eFyI9_`{Rgabg&jqaMNxS)=NY5WZX+vh*H?I-*q2ErJq4Mm=kR93E!6Xe9CJ z|44_1gh!Dm+F1$!;QU_z9L6s~N474NhbgwSYJ8q94t_d62nvstCwOM(`?R-q)>gT} zZ7L6f5tE?Lo@{}Ko{*{HLmw{CI;*cyxNO5C;bfNFTAtd2*ReZlHjzcrufs1^BR?Hq z2UA`bfFE#q@j|B|BnabhK2i{SLMNZ3iZ9{Z@cm1Z8icQw)sd5~(I1<~#8X>ya)n!5 zK$J+(1C1w!ZYWf`c=fT_@wYn?(|-Oh$wtAsx+y>P=hyC2xif2m)^H0a8=e?7Ge*Kh zS@A%GUOqP&hH>kS$Rtm;S$^Gr@x|M#THYTlCarF5Ody!DOqsT!z}CKJ4-(nIqOtO8 zC@Z6`I~saBpr!#7Wem@(!^Nf57K3Rx6|@2^&-PMzTTpKJonYy(9w@F4;R)buPjI$j zUvh_$lfQ9(=7}Zs27O|tZKrBo~71;#dO)Q}G}{CzyiP`TWi ziRoru)*b7RxI!)HX>ksC!Z0R}b7h=ydK`iiB|P&Iq9i@i+oLNsq@_#B@A0oG7$^i2 zjVgJEr7+6K@NY!2&U9+Ar6&$h&4}MxxWc79jN-?zJX-`!ohSY!mlDwpPIW(0y)zhc z)w5Z-et=B;zFZ*26N*I{bu@;mfTdWk*tZk_0rafIP3T4I1SNK3Ot*GcYd5IpRzDxu z^S52f*XB$p96s~m`9(XZoPI*^NVHa%Ina%d=HX+~>*u~+sr_#KZr>gGqouFdn+u$r z9k9KF5>!mW8~h^nG69$0QH7X%AwG<>Hn33NP#jDP^kR$)TF78)D|g)&bvV1)u!(Fp zqL=EQ1qJvOCzb-$_{k8YXUim#6l@*aF_F2cUG^Q(JJHwha9JIsGfSCKWM)W@9mmf( zw{uaW|3!geLcCytok8sCi=W+P_YO{i<^u`?$msECOIYxp=gqOZ&v%^&<2D(pXZSjoGfwZK7wR(DM z%dQ|yZ=f|Xy;IVk5Ot6e&>Ct0B}CQ+*Fp+x(QnK>OJ6VFc9x)o%c|Q|=!upPrAC5ll1O`tCZjk@vuPUQRDU3eukG_r znqX;?9-YV0VvA!pJ2N>R0@dKKwQin%^waokqYuzzZt;~bD?$WROWN(7~nl&z(7u# zPjwXY?0`YvsHk9Xf|Bu?zyHMw#rzE39N+<#Hq?K}Pk^R&6Q|dtNAwjJ8N9%P6}&ZG{o}T+|s3 z0?-F|tC2Tg3_v3KE4;D(e2Pqq;L{J`28VyM%w^Gg@*T?ZM)$c5TQd)0ix4qRazDM2 zRnV{xu6l=@%DLZHiBS8W2SbR&6x$y=TjEouz}Z5<{Kk~(DhkTF50TI#BoT6C7PWLxc5HxiTwA1Y48*Gp(#eM?g&GAzV4DBkTJ03&;apqgOcavh!X zy=me_eiz4-YXy^es~RTrevL}x0yVhE1OdbjH)%bb3&?u$bqAge55@)nS#ME^q&phi zXPcdGWmuk3IYj7_aFh`M%*KgoFdNm_UX~iLON9B=;IlVK4M{$-M|CU*yOz0C`yUoO zznuvUO$>Iqm{WdsS-zpWU`CF`Vl;PDtU>7zOE^3M6CLh>C+Zc7i`0@w&cwe)?peuI&=> z#9r`MGlb-1bksVX1yI#gKvi#kE2t@Pa=#Nx=DkB8mNR=}I^RSlw7J=hXXLC`c!G_i z@`x5_c0E$$I`99os-r@yy-Y)6-?!u~zOcPpDEv?B6yh18E&U+YvBHQw?x|}>t6(Rq za*DPYXK8!3^v&C+Iwfq%^CEw^O?!c%O6Uaj9wdFX7;0%*{<=?>Q3(Im%0foH{;&i0etiLeq3sO^Ka%7e4>oi6+mJL7Jf zN+yJWjJdspSM%twA-mtKcvbmY%2=jch*bbGjw|0R7bXHSEZSyF#Z6VM6};i z78w>NRND9Y==@9gsiD-P&(>+8e#{6C-U3sRFu5Zn`hj;$m50m+7adAnm~BU_c);+c zm4z4bXqmILfDhUCdfzb?lO5IDCK(GC#a%VNb+xs($TkCE(E|dr7<+s!g%h7PHHheh zJAagWHUutgp$N+4qimrB4il5NPy>l5kQM{<#cDhDs;q-)!eH;0c-T*gFpzYIXP1$R zm5ej+k2r|0PE*rylfoy4&3KHAKJncJz{LO1ag}eY`=I^U9OoV-IrDb1up@Gi*w?~; zL<4C0Fq$%~PM3L(c`ty5)dBA`@&>d}uCqLUg?gozut>WDq=c;DZcBdfrVWsXy7E*7 z{2JTp+gqPO-2%iFaXqPUZc_q7yhG%aaAgc=`j5V@=l@Vs2&dh zbCW-lW2Po3FWuxPYnwNw6NY3ue-u&eC9A-`=;zQ=B<5O z^$>7oM6h>pSYbQR3@5;w+!a%OKdp+N?9&@?&6=|PBXUx_bni9W1&cUC1F29z)SODu z;)o8S9}%HN%sIA<$G4K!_(RKp-6&M}>RsbG#4hQ{WGL0L58CJamA0A*n_Jpx91eVw z$1nOAit3VMpDxFV6qS!NddeSnPWpA$xJD8mz>^ogE}2X_aXNKe19WD2QdZ*h);_3q zKo|YYWdNI4oDL#TpEFNZpbhbm-};0KddB5m%($bZ?$kEurp2s};5ZJ3yN>DTp@jy; zTml+Bxk^R$d)T^B*0Y_U7UAaG`0=i!o1&m+@{6t7u9~1G{sH$f#1N)LAw=qJDWeAd>{H zsO&V{x%bE|7u;qrKrpyK+(fk5$Pw` zx}Vxj5u6#!vp!q!)-!8(?*kL-I{0{fDpcxsZ{fXE|^Bfzy7=K>+%%QS&CzGs|2V~ePv4MtWT2#<}4Ktm11V@u*XzqkMnWm3slG6f^H zoda%Y0#S@64nTQ_!sm+5T$U$|jHEJ4p5Lyn zOo*Skuv0OaXf5{LD}Leo!?>TaN2K{=Y*6$fibykw8cemuUJUrvCxPm`LfWkO6QLw-k`vRbmBd8r0~{)tccnX zc+82}c*p0vk9_*ow%S*ZFe)%g_?6sT-N;pj9%D3X4=Yj!Qf$unM!6z$fKRWwfuHA| zWHB+Td8P*_f@1Fo!gVPTVV1p-oSUa#Ak}c$D_7gUe@dK{U2quGUnB-K(8I4E-7W_v zFAbu@E@GNJtUCw*wu9k)DIV7^ZizG}Dc#XO;0iNv3%JvJJeRJYR4?~0 zzg>isJXW=Q3zhA!CERIfnb2_tb0z*@_41|hC_xeHJc)?RVBC!7nE!{kG10ioegfH7F zkFK6vDHpjy_8wQ(k6ZB2E-w>T*>|NbZxPSeu3Vf($lXGgW|TDtrl1<|tO8DehcW8` zyB&M>1Cphn#3o%kbm$cWqefYfNT=bAN(0{60oJP)lfauPUIHAlR0c{wNsGLAL1@5w zh}eiI#%`zjq4yVXWgWn*i#iQ$N4@l=N=a}$Z z3i(I-Q8`S?s?nF%+o^9>pVmX#<$}`^5_a^suQpMT&&wtd@AaPf`#Ckph(w#=AzISHptx~#^ruuM_WZ7r+FW7TAk0~T zx938*-PvuA$2QtP$vIdM1Ki4owu0`g=AvZw`wWI10K|DG(*4KYqmq4A&H;Bw@u!Su z6)mI3cN}U+n=fD~&i=(*DK71Y9t@^6Tmr}46>nHDar7h;14jKnlWIofv2nWr z^mF!@4c>%fm|^GV;!)q(T6RZEkF0smyliJB?m7sWMx>D0L*k4sR$5!TS6dw?u;az?C z-WBFuADOq_^8VS{GDd`JMpfIUcMr(@KKb!TSsY`%ffjMZna?? zD07lyvzUi`ahg}PrHK<`ZQG<;@8-M}I080;Odh*}s#DERxst4w)$K$FI-GG_GgTvf zxOM^OJkfi(Db)!x5hvHT;iGjRJQ6*!?g&4sia?bMYi8w#fjU7;5{}(-Z~4;1^0%TX zeo&yb(SHw%zdp^Mq5!5=uT}Q&&d%e<%xgAYTBC(N;Y8Zo7_(8_bRKimgF3P0+%cf% z?Ov7M_(w#|53RDao?XUQ1+*S*%0Ajkl|$X1m`*2UvL4|z1#txFuHfs{VDwo=E<%>W zbSD*5gLA&Q$;L`#!oEl*N#J`&yij$^y}IItVS+n6$8mYvB^C2hAdXuE+O0}xRq8lB z12G_~e%x)k_psVnznP^R)bLl7AlalnDb9e*&Ah;PCEOZ|7Pn!{rSH5C0)jB~^ViX^ zu1t&pNMYg?5-tzqLV`pt%00ewJ&yVu-|X$Xg)%YB?RD4m{JF=smezL6(K*|}=X`CW zO!4}vBOr<^NWR!>HD7pO!k*1~EN$Y!6ddh~W85h{-+5g+nf6!WU_t9fx$vO-#ZA^% zpQ=E&|L5e*@Vcb{OWSRpSSM+q%`X2iA7Fm&9Q$C9VL!tb&{uDShQ0C`wbQHSz5*I{ zXGygcugX?rx=vmI&g>qs?_`9DwpS#bN98V@9wFaxkz5Dz;}aggo2A(4k#x>=+4Xm< zZiM>IDc&v1Etae%ZwZ=C4Oa-hE^)ATJB#VC`1ibY(oW*LTHrG3a8WwpBysW$p_*v{ zKD|FeMn92OS0k!dw_f7JL_pF^Q^xLerRDM0;>XO-4K3{_6>tv`ZlDpNvR&$J&+?EX zK%6rnq^tfo{wW;o2x6Hc0um1@5IE59>^jlY|H^lJEKJE*{;+yobcgI@PbTv$KVhdg z%xNe!XLfl|4_v!O%o6ND_&6kAaev@47k@t6w@$X)+*0K`a%op0Jl6PetfzF9g&rE_ zw`iAKY)fih9^N6ESh(yEU4SZ&^Ky1HI?7&kQ~nfS${QeSjx=VMR@{=uDdG4-L&`ZJ z$N<*a@udyJ@d_^&@Kf?HI~mhj9?gloI>kzQQeEiju-H!HqTysXaD6n}yp zCauxf3(_EsPKnm;p12|^mf9SK3z`u6w; zyTvFu9d@%Ik%HJwJnO^DDjL%Al^SRvjBm0sYoW(pyBzNFIh^rLwtwiLVD@vac_Q@e z>XAXC-`O|6W9LENmgwb5=a+*>L-e!It%ggJq=Sieq26E$!&XMoYhKBI>Qq*;3dTQo zz_5gkuM)-JA$@0lIX3;tamK7g7wOzw=Qfb*^0XA(Y&%8j={OvbncBPBbKvLsx`*+s zu8S5=-X|PeFN?+4m!<~rjN7J(;T8+jB_INwtT))T9MrGqy}&!$KThSi`>ueVAkVwm zM0dAwqe3G$Q6jlG4Ki?$eduO^v#FH=oE)UO*>nv*bM;tzz( zcWjEwVB7?*OX6td5+QU4#$5k6o#B-PT_5NPs~PAha&EDGCx+9U+ubS7K^-`M>6t&3 z2OVPm5g-1=w;WbJdvH}BSwZ6a39q-hX=$+Iab<<@95Ao8^2$wks_ds>{sH#c+YT&M z->J_9VRZ4>p1a1M_%3%;FiFvjp2?B9LmwdLbbbc>@sI^x|7;N`02vyOHhE)SX})Oj zG98vn;r!t{^~(tL0RQBvFO53xYOgGB)av)3bfMeqm(0!^+@OL|+bgyd2xo=`n?F=1 zdcRSlK9pFxC`9X)M4}sb_hB7OvZ6uV6f>Z4+s&M1mTP1rDN&Y8^w_mnlSj1}V<#if zSWrx7xex@lOq@kn)I}AD=!53MB>~M^;@69SD}ArC{PK4Aa++|;coCUhhaZv2UQ#G( zy>PO;L%7jaF3&l+Gh(CCh;AwMA)mbh3&s!oqaq2(MHi06QEc&2Ch9vbhy(%f-b`_c(Gi>rx^XQiY5 zf?ZZXNzlwE(u*kM%>}xCYC<%kmiYNyeyUwx?Zt0*>&jeEWeV3HfwI$=Hb39)<(5oO ztq)C3+aTFG+~KmG$dq4^&$s0{yjI)TuR3Z!k7#H+X?OV>(ej9^BsO49zEeU|_xaa} zjDSk3#x#%G!v4nuaD#06`e<@-`mHfSxTyD0YofQE8a=k z`;$ijUN5|4waZM9W%pCrdBOcDdHte-PfEvFas54t{#WfF?v`de=jDVN6+T}#fc-31Rb^XgvL5 zb-6=}bo43Qa2IkZMmPA_`LqPHtd%VPe*Y>7E7QRqszV$TOAKvJTW-@Caz)H2b_=OO z1JpWthU&~PU*D(c>KP%XdoI%$p~LjIMrNFqFK6ET@g`y2GTV)ReQGmlWnO&TYOc*H zqF5SJ_+!01d-Ef|P8)|03v>Ss+NNZeozkvE?(y7&*iVnNM7;|P;4tTjt;c#E`NEDZ z3f%xK_xVTmXK3Yp5IAu z@miDdoi!~-3J+H$zi~MJ-s1>#Xf?HYk)c5wF9PAvC&t&6Tn#x`w)92>Eyz?FW028N#v3 z_2yFPB>%{7G>}rYJ%d*#7K<1us}z(}hw-!|-0>&jx7k4kITr+vhl>J;1;R6Rl$S=v zs&PZc%8vW@-m^;&+26jvKWm}*{SDOi8m2s*!9w^p80pA+-?qDE?NsJWRZl*0zE7sX`fspJ4*);72H`R{Z)&(3zuh$uaJG*c*gdueJosSc(X_UA^61 z7ib`xbJQjh{jmKVO@YSqmieVDUD#}ol-w^d1Pfbq&dxH}pTl4eHN^TPa2G>P@v$Dl zzA@#Y;A4yxi#xoYf9yoN4|I;ot&qJBX$X$!=osjtwLPkb^-1Kcg`7gh&|uq5_xHh! z-3B1_S4-+}z)HJlCL~241Upbc7g113E4k>SJHc--3OKbZkeg=UYIZma<(R-&8M0o! z#y@4IV7S9Q>wiCe9QN} zB@R%;wAjS$j>hkQRPp5F<@p0jG8gGQyk*!apw*}YA6gf?Wl6k-A#f~S2G?YF9WKQh z3xW9!wrp@;KV(-AxH5U^`;b{Q3bEsbKyB$nzWG52uP!jQ=$PLh{qT}&A9QE-IzFox zE*QE*XRjs&xv5VRgb6X)-wwl}v^QT}I2NrG`-%YS3lt>%2*TvC{r>p-ikIVn`>{aq zfP#yfX7|;^AU7>*LI1j0>kSI9kbD2|MirJUJVt}-btYS?gyCT4%48}St<=Ns^Qo$* z94|YF3smSl1e;<&g#|2aY1B>$!lP8qfj$yqWal}~ih>YPR9 z16>?Y2wDT&UsG{^e=*i61YoqjH);>SBfJs)#kThi4g|W}f@BTDZ!WQ!BqO|lJsG@; zg*jLZ#c>^i_TxN^l{DSou5?PD%&Tt-nL#P{myPr%TiYH;ppOm5EEsZ1`MpVq-c^nl z%tFwDGOJ*KP;ALni+oxLq3J>=!nwut**;}YOoM|43RvHRgLW^Km$XJQLUb~ZP(cr0 z+h1Z8NPm)y5XMJ_Ahd}kW1SlE-s~N?Bg71($zi7{hz)E8{{;4+QGvFwm`V$`#reY! znXrRcMr0sN`13yAYNWnSd;}Go&f6fk=qj?E278U1*G^}veC`_3e}lX%x)0Ep6$Lj* zA3(|{$aeHiS z5J-o<03%tnfT2Qi_EkIpBN-3~M7j(xFok(xrX=@Y3$B#Gm%86P>jYndfN2Mi?ECXZ zW30gO$Q3rL6$Y~+um7`Bi=z=3nxd&wHRn1BkK7$vx_bYt@qxVDClL7>e{HZ&Xwl)% z;{wT_00fa+iDlF6TmHTHi|lchERZ|j2HYRC3>p6U4ul1KLh0qtzBE&E>3Uc>?P zIFswz;qLY=YWaUQR|P%>Qe|Ss6@+=$0%%aVub}}3#KC@?8KA;FSPcP_|7-hM*1nLT zh4AkGS(&B`pananKwo-{x*1pHzM=yUqW6&FwR7sH_psFknR9&cA0q3NPOSXn(sB(g z)C68ZPjsIb!R|FO$Jzpph28?J^zSWjOI~u6Sq@F3_>$H&)jtm!O8^gowP>MXJq2Jl z;PPM0E+O{SlE-!7%#uq4$-iGP0d%6|m9GI-fmQz9Z07ZGUkib8dyzqK#NQQcV}{@x zzzzgqa+*_w;gx?E%yIMpx|U3Vm2bHK8+!SF>F^G)F#fegeH>6>U2h^S{;(+|f+E&k zO|j`tdWiWwM?*U#cQZ&O3#b@{C_cF;3S2h zB_W5f;Q27yKQDbsh{EhDr$PAyR3BOY{Jn7iyg~6)qCGmtw{qN6=r5qxrFo-(M&_i! z0&Exk5p{@88U@=TE9AC!c-|kXK@5N)5*cv6304a@wCLggJRV|5Mnp*>ShWHjDERhw z|CthDi!zy`0s0O~Y%~6X191k&0@hZe_uv^2H~!yqqJR+s6Pf(LDR45${`*>i?BMVC znTjVXZ^87R8CUVXJpsqNrjr3xUu_1{PQq7;>Ha_@7D(Z{-4HS&*c|?@#5?tf!q}Uj z9!)Ml{CzPo^55-SrnLSaL_^eo)dP$TO4(4eX@|f6KfbZ|+`*!5BH_V1@{zZ$YpG(C I?>_qf0QQ_UdH?_b diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/publisher-portal-dark.png.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/publisher-portal-dark.png.meta deleted file mode 100644 index a0f1369..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/publisher-portal-dark.png.meta +++ /dev/null @@ -1,128 +0,0 @@ -fileFormatVersion: 2 -guid: 003e2710f9b29d94c87632022a3c7c48 -TextureImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 11 - mipmaps: - mipMapMode: 0 - enableMipMap: 1 - sRGBTexture: 1 - linearTexture: 0 - fadeOut: 0 - borderMipMap: 0 - mipMapsPreserveCoverage: 0 - alphaTestReferenceValue: 0.5 - mipMapFadeDistanceStart: 1 - mipMapFadeDistanceEnd: 3 - bumpmap: - convertToNormalMap: 0 - externalNormalMap: 0 - heightScale: 0.25 - normalMapFilter: 0 - isReadable: 0 - streamingMipmaps: 0 - streamingMipmapsPriority: 0 - grayScaleToAlpha: 0 - generateCubemap: 6 - cubemapConvolution: 0 - seamlessCubemap: 0 - textureFormat: 1 - maxTextureSize: 2048 - textureSettings: - serializedVersion: 2 - filterMode: 1 - aniso: 1 - mipBias: 0 - wrapU: 1 - wrapV: 1 - wrapW: 0 - nPOTScale: 0 - lightmap: 0 - compressionQuality: 50 - spriteMode: 1 - spriteExtrude: 18 - spriteMeshType: 1 - alignment: 0 - spritePivot: {x: 0.5, y: 0.5} - spritePixelsToUnits: 100 - spriteBorder: {x: 0, y: 0, z: 0, w: 0} - spriteGenerateFallbackPhysicsShape: 1 - alphaUsage: 1 - alphaIsTransparency: 1 - spriteTessellationDetail: -1 - textureType: 8 - textureShape: 1 - singleChannelComponent: 0 - maxTextureSizeSet: 0 - compressionQualitySet: 0 - textureFormatSet: 0 - applyGammaDecoding: 0 - platformSettings: - - serializedVersion: 3 - buildTarget: DefaultTexturePlatform - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 2 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Standalone - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 2 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: iPhone - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 2 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Android - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 2 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - spriteSheet: - serializedVersion: 2 - sprites: [] - outline: [] - physicsShape: [] - bones: [] - spriteID: 5e97eb03825dee720800000000000000 - internalID: 0 - vertices: [] - indices: - edges: [] - weights: [] - secondaryTextures: [] - spritePackingTag: - pSDRemoveMatte: 0 - pSDShowRemoveMatteOption: 0 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/publisher-portal-light.png b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/publisher-portal-light.png deleted file mode 100644 index 621e906e33598c8bfdbe38dd5f6761ef5a98e07f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 33281 zcmce;2{_bk-!~qTB_(Z?HLa3;pKPVFl$}V1#u!VC5i|B7Z7N$uNwSp4IzqO=sFW!Z z6(&1Pn2a^XU@ZT0FkRi(eLeU8e&6RfUUO9DckbWi^WDy0x6DlRH}US~UAJ!CCPRZ0 z7VFmWpx3Qq)8O6!o8rcQu24DNwIOE@81-MzFV$17_jCET60ByCiT<&C}d5N_@UK|Tn} zAQLNikOy4DSyD$^LNfpYCO{(4Fo^)9r1aoln+8eO;%n8E-x=Hp{61040D3Pot%zHD9S4;$jK|qDJaXx%R`hjAj--TYd?}; zIUi>ih{cIhYm0$zT9R&Pv^PXf&fni()?Y~$<>M-+prN55C$A`{s3-$^$oK|&pY4=^>}wV1jgYfI z_@XdAa0KYSm$fHf^hrN(oHfGy7lTjwfph&H?(XS{@kRT<&?ujOp5%`Xe?Ov?nd?7~ zVUYtZ=k5B(DNnc~|8xJ?FJHhez{9@?um7Ki{^{{v5dH?JMr84htl`5<9{*zQP}D?-lO%ayr5Z-_AvePitEsujxHzk- z$S7;TRb({as){lyit;cxOj%w${qP)6>qOyk4 z@lz*`D=26vC?8W-(U3o(q@W_NuJ?Na3xt=mJ5$m1JYl}RT9ROL7{(I~knJy8KrGQP zA2i0>%m?M-?g{v1<^zcGuU*!tX^Cz~z@VqQlMl=% zP(ndPmMKhs(O3`ViSjW)RdG|5eo7^3}H?(%4%w=GV0DMYBJ8s$|?vY4Gm`(1!u{%@jwQDOC?jPoq-7b zpNvQS-^=0Z0RV^pQ4Zw*EmjY0;O+|$H*k&ImWWG#5q<^GAuu>ojsjEb|1GHblQ8v;zZ3Q&rmhn0dd zL>XX|8u)z$pjMahMY*8;ftVh11**-Gz<+@g6! z|JMgXsH;1xt0=3;AXF5cWt5%dm1HzjG!QZ{7~EMN?xc=zR#p3_1N}zaKe6$@JOT<7jAbt+6cuGv{%`sJzb6;d?*5PB<-Cd}ECKnG7r$4Q zSmDZFwEv3}|8eU7Use3?EaxhP|DQ5q1%FpTM(*$U1HLm2nK3MYX@M-=gAhPrfeQxl z*OF9Kk(X6aR!~&{R%!L28?aEy%CgGxYD%iW)~r6nc)0_ZFmn$;c>1nzW^GP0PvE|o z0A29?2b|N^3xs+7VI$Uzg)!I!@ZkTw;T*!#6XpN!&sXftACLcbR_59MWglyMv-F3d z;cogqD2(?%?rs&m{)`>KKz)cSa{%*5T9PMLoePQ8nIu-GS~2=-y_g=mmZUt>&aMny zvC=RQQv3rkm~Ny##CK&+tF!9^zX##FHXnLrDl-dHy_1%ftY<5(hJw62a0Zw^YmbpD zZU8X9Yu|mCaIB~V5OZz+h!qpC>N4p=oIEj1uR--sh5EO>SZK*h=z~AUwOFhCZ#Tr6 z$JJ+LJFKs(yOCen%-{H^5BZaRD~*3J2at5-(O=%iU((K$fWLA3e;N*gP3BC$!(8y? zcc2VRx|XC52!r=J#J8_o=VNVn;+R!H$7r`>&R+d1Izc+h3*~*Mf4**M(A_I9G=|*$ z7P+7}t>-lC?k4&JcO^yY>($#A55-2P{u0lG%G&=p7yck^zZ;L;m6d<+*#}~WW@i^# zKfI69N#%cAdnO_G+0FOwZ@w>3)SkWkv}I_BoSBzo!L{T+oaq^}oMOkd63BzU%AaZL zh?nfi#aeFG;>2%8o)cTf=Cc~tZ7L7Pop+(_^{KCgVlJ*0voFB9;>Bk zZ#n#G*$-P=Q;9Unz_6MxOTHvZX26#?rsH`Z>3$NpMu*dc+wHs31{ZY&quc&fgSx>Z=*^LaI`K zLxu$p8X8ZgC%a==vr6z1$y`ZAV}~T}+oe&TdOlM8EX-=Vd`u)(m~TszkxDbh{A>(t zJ*y$eIyJQ^sfd63Z6l3lj2jj4B!Shm?pW*4kaciX-yZL5j<8sK#Q2M&Z3zy)H;T>y z+$baRhy@+S^o?86XQ44{<%JHvr`9wAG{0DD$`Io)tKbAQ_+^_K^qU3~7nsD;Qk{_3 z1+$k0rHy0w>KbXXtkwG*hNq?sgU|HAUI9^vp}p!wb;cW^ey@&e6)Py;txmBr0%y%j zQfy}3qorW3Zyzuu!AwA1gND;kP@qHACq!wh-6!D!!+tlk$e4#ab|{#`E&UMkpJ{+ z9H-f#bm<28QR?XG^L6XC6wWV%^oTY2Z=v8zQil14-FoA%JMgob?`AhO<<6)R^bTZf zws*vw!eIC&tZ~1^QOFiB!>j&qy7xU@($4`Qig4v&*3b*(($N8**{l(9kDUZd4qOzy8tQAaku`F?MQW;P2b{K7zFkChD`mJqgwg)i`uB=9BC)TxDQ>0g&dL+1Xnf3#r| zlDJES)kNu<6spL~yN(7;TnWaO2TlpFn#4u}JReVh`MwyQ)40KUd^rwa%2ehE=Or-W zQ@u92lO>^d66Y7HF4mu&J(YHv=d2%*`q7Q0>#w50_AUh$SGAwRPEEXn*O z?HlEHk0#K=oKbgxD7|^PE%RIxavbS-DSluQqP&|$_ME0m+`HI8?pg1CLnha@=VJ>Y8<}mqL5`@FX?;p+tF_Q3Hg=JD3U zdycV2Nvey%<7ZqZ>8o_AoALC@uQGe_D64b&Z0|M!+m z4bwZpez^7l{Gr!VeeLpb94-0K{FrU*`gLihHFG-4&(AJ3J(X(Ba56UJBMp|PFCmk6 z=?8y0>edkGo*F$e@11dgjqKD$Jw(=A_YRkDIxCw#v*d1asdm1wSgT`3Mn9%Ncu7WI zsrFm?{N&`Q&v~r-MA5V#FyKL5n(Bwj9vEA;jh=dQM*W6ZL1Rw3wtaTvp$^}#?*gnk zT=!OL+vgg-Dz`n;Zl}+7VR1gUNyojusM_?ATvx$Jr^Y*lSyf2(_ui_xUlU&$^ecyI zgL7X?HQ>wD~IY(>@4M{rSRCgIb>d7Ipl4BA(bTE@0 z`lBtvLxo33@V-ZzIb4hPvIwbQwCB^u~c)6Kwg}xXYK!D-fb8UyIkhhb;#2?Jfz=&qXEJ@hYa;r;@4%JpBtS zePo#?ccE39DDUS8fS6jecyt4$W1hr+^sr79Hh7k#v-BCPwDfx=v1^Qy3Yv6mg(@fh zqcJD`eLg?w;#PUt!*unY9tiJcXHo%jmU3~z?Pudsa_cw-rB#U?^M<=B8>ROjEvja~*=i8*61GW+uPrU7dI>I~8owowk*t zsJ4S5`Fxd8S(*~x5Mmp3EvO`N=hF_gOVA#{$8Hr87%Xj*TZ8cOgmE}7^4G$<$lC8o zsP*Seq^ab>Fub#7%xipR-gIL`f=z*=_|iaGO-cV|v$ncN5$APB$Qcowi=um+kPUh` z<8WDD%WzpAYHi7*^-+=adP72O=Iizqm5Mp?_~uvLmktPf2+f{)R}waX(Mnnd=|ztaWWlX$Le6hBvbBxQVTrzI@?f876vKd#wEL%xW{g08KyeA)mjL zeh7x^pMUqmXiLaKq|QXME~)UNOR6|wez@kkL+H5&MDhZgZLUnyRA{ zGCiHW$$y=&$IdJ!@whl@4c&y6hUBkCh{+GuhgA`(2T4g05g4Z@6r@tU+Ma^cLN$$f}`% z!OyD6af_bLq*XB6K|S;WXCC*XnJf0mcUcmIzl$s9Xx{VTN6UmMUDEwBSJ4JVGx3Ur zanI$saqU3Ka;HD}?;|XCRCKDN@K8ySdxQ49 zV4_9SiB%crW30%y(^+a3#+jORKZR!i2R6YNxk@C5h6xA_hk|VkG|7z5ixqO>JJdp< z3uOtt%B8&DY?jo#N&3LfXogLGpP(1im}oU)_~^E;1k>Dy0*7HZCP-=r&0Bfz?*;Ne z8r`-bTsCS4lR+ZT3>GfIAq*wPR@;;n$g}@xlMMk zc_Y!2f0@k0pe(BG1LIx0Zh!IhEF&vC$`&t}9U5xlUy&AzwtpfG1p9H6oG`ep`sKI3 zVWQI{H7n4RddT;}3qM_PzFm}IO?ld7Y#I%UN)OT1LW<4qG6gw~Dk+b!#>ai%$A!5l z(v$0fn=mCPw>c6;Fw|&R>dS?3l zJAhr-kbzyzgJQIo)q|9}2E?ydO|xkg4U-Nbol@%)hA#=G6}%M&n<-eHDXTRd?|m*d zVyA}i47jboA|#=-H6e){2skM`RxA5}6YrHOUoI8(6v#csq@Urzj1L* z#2NuLZn4$%TJ_aF&$_MJsuo6{+?(UDned$ROI_b_I)dLfIgR!*fMvdzwV1n)9ZFP8 z!iLTc=PsK7P8^{r7&t%NeYSHmBcAbP%{sg19g`IvTLk3TjQaZq{4u+J!QP%g$>4N& z(1}Sw6UTmU;M)|W-d-pVV2Iv&{7&e2d$(G1>r(sq*uznKnp?%PXYcr(;~bW*%wjqt za$$4yTL0d#)SxU6QhddeoG>C;u5;eBba{bf<0z`V^ds)uRr{U0z%KrQ3}rM89%TY< zy6yY?J>7(gY%Xz@n;acmmY06~8on(^n&~%e0HV-SoXGW!D`#xBxN|)_bn0|iXh=h9 zWk4i}KyJb>2g=?#4xns-RpaMZ+xQ#Jq?%i?$+GNG1w`YUcROTq#D7!en~3*X?$^My>cdQfcT9Ywir;T> z??*0?3iS%Qz~zebi_PL6!`r-cuC;ep{3*@egZYxWdLHMGPIFO0Mo zGhN+hI|qyUd&bukm&*PJl3dRwVJ<89;annz^_T&KSje68;;N?Wq9W^vd)mx5s%&fn zaLUFGrOJj~3$#h2&OXRhU8t&|_KHH9TSMD|dn00rl74e8jf3OomcAQ&+|IEkF$|L9 zbFtwLwRg^Cdd67Ujv(Vw#|5IGqXquew0lyhA=A@xjH@?H=fSmRCCaotQ`QLy zM#s{#JFhc=MRx={VZS;$VJf-i`)y)tJ*>m&6qjj z<6zV^k*csG1<8&Bz?QD~;ztN`2WVy_g49MRo%ARuv5Xey$shzR&QE;)`n-a(!n2%S z13aU7%pxy3yb-vFhdf5MP8Z_YSpX-Pz?L4_NrYB zM_^gHLu-AZx^|=jT|w{qZ+n_|5Ms*e&TV)MoW!Bx7+T-e7RHM}_6zpP+S<=zNTLNc z`WJVsAlme6>C}c!8e?2A?lj7XL36PEwCevIjsSVLW0{w3CC|=Qcft?FA#22Y2wEXC zBj?7}V3ZRd%4GPRF`9HU=VL`bZuIp6^7TLg4&e9*CVkp+nx&u-Et6dkUJ$}v2j`@` zgC~0A_sqX79P=;xlxxI|7H#mHnd=7ufF(ah^mKQ;Ige;Ske}+s8q^n}^wL@w9KUt2 z=mo_e$Qq3bczOk0;21937hkBCCLJPb3c%MOB$eg0HyN!W{crjNDseI=n_$~4~UjlN^A8tF+TMB@XUCIt>P z+RS{({(t4}G5i{hVOOhCgL-mZH#}N##BbQnzhDTi5cp+^zi3-A7j;FXUh+F^leati zOU)MAG`?dHa#)6?Wz8zE=5R-FXXtaOC4vuAN0+Eg4ix5eOeiq&&sTGy~qa*x~*8vrIN zX^ybvd8$YZEHCzTRtv;?Dp7EB$h356nH(v%SzHTi7qoWd$k!`J{`LcSNkw&=!*SDf zZb_+#>BJxG&{5ZvvPEnwu3MFq*FR&kRA$ZS{pg!a51zQ&g7H5RS!(JK-?#~Z9cXIo zTn>H8&#z|c7FG!DZVv4Xj?s^t85gQhgm@%;&hR_e;~iF>Z|{|x+G)^uZ?@b`6yvWY z2gw`4zM;v7{tyZ(pYA=G1={r=?Ktb4IQ*G>cPX;hiA{>?qo6i!-dpesErYCQQ z%}!hP%e=n-glRFu1wY^-K>{bnjbB*=Pw*InsdAIP%XKW>&9m&2b*d$gZDv~T7aU|3x1L)y>mc!w8CQvbC2B^A|}&@ta40W$1%-_lECj9{XzQ<$2l3pk%kskw?j^`xSoS8nUf9V^r> z6>W^j#hsR%dKUOfe9v})zB3wD>JuqO!vmK*)Ph1a@^=bjul zp^~KaFZR%{^X-qv459pYbm6Q2ie_6%Q1xkX!(@d!qeBKDb+?wP4F?>1$V@b>aI8nn zBJa#E0bn&nfYsy;+yXP%IlYvKNXzXGaX4A!XL7&*xV;|GSjjN?N6uklip{jkdyQ^{ z3aKuqN$@y$7?zlyf%_gkc&^=a6J8%Fx?>V@xQ}kPU)4t74tBvc@!Catc%3ZpHwz{) zSEzRrJsut5L3S6ga=WHl-%31;3a++Kej@_E2Uo_5cDXO|;NF(oma+*1+!Y~XF8xeM z*L#3CApAVZmY8=l^z)06$>MQIy9L_WFoC6@3=`)n)0y2rUu-@wT9EdDw7~B6fc)7< zt>vn&4G_LOYp*;(;3Et@YIv)flKY;KsB1F|G1)U6=SgwS(zU4!HO)3Is~D#uyz@sj z^Fo^Ko#8qq30fDaSvN`MYy{Kc@JGf*bi6^`*Gm*X(}g)Z)o>hl?}4Old&9KIIBpNE zynl6{_Asoc=&?yfCKV~60gRc6g0O}3%MT*aKU#r@xz$V>zlMfO>qY>`ts( z-Zy8(PbbfZAterGHdUEASH)%!9%zM)M{IB+acahIqa6Nm>{^LYa|H~ntJ?f%SZ^Ma z2eS{y_0f`iYO0aZDj)LrN&K_)0|Mg4+qy-{hCGl%yBipU&$z_1GnT>Km4z|414LUt z(}fPsmZmU1Ruiw==f>_b4W4@vg&l%%Ku2v$O2njsk;ZSYy%cj;%Tlj}+&|I96SH*D zSpPHCUaN(L*&nyKK8xLZOIYR4k>*zS_Xn>>e|6jWiyeBB6Msq|bnF~EzmrpTu3>C% z@Z`;i>d!aUL$Ux5j*FeJ&0U`?d_bIXas0W4rgH}|Kpd#o*@ARF@t9MAs8OZn9S!Ec zM62^X9)GCzc{~XziFx@+jblt}boBWQ!5_XNVsX`!?{%Nw)LDk(`f=lg&u$ zKhdkU2a#Ul%at=iMCY1iwcgO++3xYM@z=!>`}SW~W~K}0xwD@wcq5x5+}NS-IPorp zTIIJw@?sIiFpa)|7bs%(@FTDxj@Jt}qDdpiK@!XG`i=GY@5m%)!2N)-<>)PE3X?ub zdEG2qEPWX`8Twv99i1lq^@97CDdO>-%l;+FgZnpZ*-*6vqKx!;!VoHGp$qeb5fFK% zpfw`u`PFN)BS-0C-|Tk=V8@*ve&t19+8UlW2FfbAEGJ%Vz(M%N=;ZC(_?mHMj!`>! z<|Bt|IBu)nZe~*LN$lMu*I!$ZRRBKf#%WA-!iiqM0r)wg^8!RB~ExR@}SS@cRx?5b*mrT*B6-m#0an>e$3*nl`^8|q#|fyE)hzSgvRmA0zI&$aHwchsN+8RqQlP;=5$ zC?%-$tN`V(@<)}~r0Df{2;;GmFS&o-_olAR6SivT8I;Ve$?%tEHac+MeMlJ)fnk92 zoN3miSCjl9)O(Vgt!vY#n;>uFcd(e56q15ISP6eX^tl-|VnhgGX0voc=Cg(GgWMwX zW0R&GH&N%g+%r>+w(X$hd;) zL@ zbmg+t!_D^%L}M*xVTo$O4}vw%pE>5n`1G0ss&}Kpuk2%-YDPDa6TgLWySyrJYJllt zbLMV1oT?S!^?SB`mY zyaTQHR9fbF<>Q!8uIsKY1}FXv=@JS4)%jKFPKuFw^FX8Y2XQV3pS0X2u0u&Pp^jxJ z&fKv>#WPK^oy&f`Q?<$QZ8jK&KaI9CZd8T8$||4lh2zW5l8$INvknfu&s?7Emd=fsT|B=@MY`R0Ug5ZcVM|!w zRC%mRO0R1+;}<`R)wK1jsnzuEP1*k?g1R~ELUW*Q)~4??jm@nBT^vK<;udY#{D=-l z_kjUy)E&5Q-=tMq1LUxksDHbwzi3z~fn6(UOZYdBK`HFWNtemYuF_9_HHOL`_chb{ zsG2SOQCFZO|BsC0)7{qfB<1T{UhKxPl8Hyz@-{cD6on>!J{ObNh`wLMwEL^)oj+3v ztCI76+)3X;*+Mz2)~s@CbGf)pca$N5dG zCk{^YXoFpL>ec7YjEMME9eWO-OMZ8o9_LtR@Eee;x)`r3ZgN1P<*T|f4)lYU8sAal-@4nO!M8uXZO zUashsyfR+GEq}v$Uc!7^-tHx#IyDqQb76X^TDNU)L(Sq(Q)bn1a>6z(_u0FmO*cc; zrq|;`MJXLSHQVwx?gI6=4ML84D@#l7MvWJGs>=k;;%Lw$I~!c_y9{#8PJht?pVS(i z!r&TRn{V@@^Q73R@J@XFi)bHy^eBYSe0p&rW4J%Xfi?|Yj~832z=tM%B#f(#bp5J6 z{;}Z!&vgH@y0p_|v-f4*EgZC3Gt`6j6Vo@oZ(*zNxxx*NY1A6MitH%NCuHQ|Lgbic zOndxjWQ;cH(8K~-Yg)adXRm6-NE}8pMOISOloO9%PKjJM3b{>TL_-LlY?x=xxt-1m z40e8mJgHhsW{K?v+{8cJM&X_6Gf1P3@hp4^5cH}74ySf=$<2}AsJ%kH^o*8wJmEND zwOy!yN&v=O0{nq@gc?A5jbTVvL$gw1_BKuS(~O}zkcqqys2h8E+-lc(J18q6N?F!U|9UEy zDP-O=_pEzKC5xzV zS(AH)5*JDF=PYwFTa4SE&qG;>)r}Xs(^t$1h{E^LxT@Svk58Ddl6#F=x3C~2yEvkHVZZaUH<*SrJg<*xwMYdd^w=!V7y{ER}0 zKV#kgmh(QtV%jyjq*@)D1pVtKlA>XQ+3Srr*rt!bHwLfQd=t_$MYrAHmV2n6P?ukN zIq>nN<80St=?x@o2>m!cD?k0sM>a@z7~kyPtC%yWu?m+knHG@?51LExKg-41vTxXJ z=0+p58z9kSf%(8#-qK?kHO>IZW9Uh|~t?v93MrU%pJg*in{jKeir! z1k@Yug?jI6wsuH#)dpC+Nttj8{r1Ad-cwuwmj!4AGX?F=`D5juWW_7WYdk{mzk0`% z%IO=??`qh-eJFtBTVE-)_6o-tNAcfh7r&$=i}|Wi*VIO^ett9J5S!TMSjn-2{DG%G z?E5nF=y}yy?g_nEhx%^_n?;cMU3! za74?czs0r6I+!V_&b(u2=99~OWj1<{lC=$9DsrRqQFC5IH9w@~q8HQB06pFQ9dEV7 zbi8U0n%)adYCwKiJac9D{ktlOJmpO9VC&Blj^L7j^wTm6PHeef6aMD@32iZoLunNm zlIvBjzi`oa@=;k${>u3*?qFdVQM>xmo0|>HX$FEebxH#RFA<7=h-Xv)g^Z^EnLU+EaNt7cdF_> zbWgEm?AvuQ##s|Oq?odE3nk}th|9Nr%}Y=Dw`TCMLupzBvgQC>D77Zwl5NP8@#kYJ z1!m?g9OJq0u_f(|Af3s~WIKzC@SyKQbE1g6V0%Q;`<^ZhaX0(a6TcQoASPTCeVqp` z&Df~P4<8-d6UjHW$PVpBUAZn4TzdB<<~}Tm2fg2K6Bi%GnoXw|h^F?}oM#HT!l*|WzE`y>7hKT#+AG%mpBg#w$Q6*L`L4W||2#vf$jX$}Icl9uI=3#iY-e%Tx@h>NL zHg=v;>f9bZ|Net;N2m{iqsXga_D1kKxh1+sjGi6B2OMd5?6p@G71{f46)+zLrFqom3qe02aEETH7j1e?(dZ?irXqkC*mV#M80z{k(WHaIqR&Tw|A-3!Ql$xK7U#EOlf zeKhp8{P`5Mu@+xXj>9ZdMu{tFeS=~7h9J1 z77vJ4zMYky%h&nhhptUC*?24V;dW;ZJK(huQr#TIh#j#UIPH=yD=RYrYwGNGD{Drdg-#~PjLP#+=O z)fGG_rPbWp_Bu-{H=f$hN~i7z)pBv|MddlJIp~p4&Q-t;SYe1G@QK0QgZ2v@`oFL< z*L#%oIeJKSYA=@uOU=$QdRx^N$|@Ff&ZbeP3lZJ5G)w(9rvG>j#0mA!HW5X8sWxod z>AE&G*sxUZu(69vs-_nl5*LI`j|N2^dm+w;7Ex~)+k=VNQ*Zqi9xiXQn>zZX%{*6Z zp8o4@YVq)_ov>?1iuIX2RpIoy19gOF98l=U#yll=GGs9L5jc$iW&R}e%%dX13hkb? z`==kSRRCQXndpx@D5aCt&3lm>eG2`Oq>Y@Guy-u+D`|Ir+h3dUNj! z{OuR1Cnk52)*(w{Fk-F!NtQ*)WK8*4k^SC{2u52!kh1)A$&GyeU4+PwoqoHfc4s`F zM0<^#2Hs2?e<&{U+{fTe?9j(2(x@GfL={BB#bo9^Kjuv^bFPY|wbI0+`N`W;>o_WO z6L<^fiDG^Mes1S=EFTD^Ij_UE0!c^+_kA!HoVD^9%_^1Z;{I zqC9eiq{ui`Z{WnwI~G)^`Jd-vYdbU*RhMEI6@1#i3UjvkM*^ngHZoZ-!10yd$JvfU zWtf&{)u|}UF8$$InQ`kqB)tTk!}j}>Q@oEw!MMGIUZ|%$3YVRWJnHqyce4*PC-OVUc_r=2DQ!#;h^npJf^D+f zPwA4+&?U)|C-bOf=xE4-Cp&bJzG(gi8@R3WaWOd<9)sf1bPf_7-I&O4lj!Jc(}`YS zD=ab3p=N!~z*vdChU7%1@6_Kva%=rCf29yfI-D`^_FKZqwA^1&FTPgf>k3W^Q1Jd* z*2eA6LiosQbq4}np2P}24Ci1YxPs`gaM^9A!f|d)H$dxqNh8!Vt+f9-lD*geUb}6f zMqz%=Hlri2t8;3<4BVJKlu3n5*lPQBNowg_uF@Ru-Dgo+(YukO1arS%#mp|vBW3Pk zX;dK&1Ta4tN{i)RG3W$p?)`{wuM5(xKkSKP>-66BQ)MXY-7M1`m8=-YEWlqG!bop5 zzqqp1eT^b*7NB)Qiv40{8ZoOP_nM}Hs+Vn@4`LQm#~s7EL6v9)l~c5hH6FekpQmMM zA?rX`Q4Fdk!{f}L82oPqJJOo1B~D1Bpo%=i1rGxT=d;N6w{ z@3Fwe9G)D-)2jN+X=M#)F^3<*M=Z~i_%!Jb&MkFu4^#QMnaN08+^{El!5`EZShaS6 zeeY?FWxZmdbVl!U?Qn<93Qq(mim>gJ+rOCG=BaVw*0^y>Y&b_r7=#DkcavQNXtYc0 z!friPW_4ZlgJEni+-4BxP3%4-)m(DO*`9h)tUPu^={|S`D7bkL|I2&IJQd-ktwZ^y zbSuCV?xoxi8jEi!it-dOm^XfMcf@#XZ_Qc3I_+?rJ>3ZZEwY*G7SMq7VXrQ5@q(rn zM$0LN3xzQY2%sF5ZJMH{xAes%t>Kz^nshzW-U(cs)E*?bulyQOUa-noHf*XBrd zT2Z}K84DBO8fPr8@8VkZ{+Z^bo_8;r1y_l=k|?MZyhcvx2-^PPe8_R66Ej=XZDrbE z`zC2um<~}U6EjZVA~B`ri(zI4NV-ztIO}8NjzgvEN>{vc)l##Rx#OPhabMipXO|z1ZRfmF$9*|#!%FkK=R&LJD% zk0IK(=Y>y}KUYw^x1&&hRA1rJ$d2fZHLCca^JB7KJTRUkQ<^g58ByX=h_3h#aJ4O& zG?XRP5Ko<6yP56pafix$-(jKut7%+VGSV|na1|mbVgMpe5@5UgRrWXE59l><&g(q& zMQ5h~N|$$2yi(aO`3vQ0BBonCsfTMl(yr-}2(Jo}0+!w2O|%&avn=T%O!_idDV=n$|)5Wnby>kK6CB!Tqsj*y+59Ah8Boobvq5g)j3 z5#BvXw|gs}l9<2Gf1GZ1;h}h4)K(;Gt2tn+TfY`eaN;*$w@_|A4w(O7vbY|kQ`V0^ z&8kK0!{(64)zOhg;=zZ&-DA-WPK_$sl<9BpPCAo@k9YEZb?z#i+MdEsxeAQEbim?S z_){(KnXJWmdiWlG=B-ltQdO|dDte+N1D=PPEbzgD z?dPUxF(kjeD`agmuN{vzu@_BV>hl(DFM+g`4qi(vrE1@YGJoj9 zGJQEi+Z|_Vy8v$D$@8MM@W4mBAw>@F#7cpxm9<4$ZhnFFKCE-kXZo&_zpy~vJAk@h z3GI2SF&k75%-N#Sj4r9Xc``qD?tPSL5u5pVxY1%2pMS6!IdE zRz)DAFPt1TKd+zM_5jN1R9(0bMtzxEHZUfMKkIMT_E`R_D)ia(nsipT(SRqrojSKX z7Z#TA%fpk%(+vWOGeW?vwgLBpZi!d;IVFE&mZW(3(AFB!YvmE%bgC+AkyD1&tI+&JiR*szD8rB0c#`C&b{B4`i1 z9Zoj+0@G9zQ`M?~57rkwmRi(g-y?>pr)HhofczP>vDnmIQ)Q@sa#Yo$cMyMik+q|O zWwJsP#&QNE*26e`J!>Szz3&}rMyy=Ax3=oN^|PaX1iaw+PHQlF@6Us|`k}ExF~%}W z{ibi|q5J}3^s{8dVIun68o_d+F0n(UP&bKwnjz;MF^r138K?Dlr}7wxJxN_QuQE77 z4Yy11ekaG*&w1$(KJ_U3UB?E!a}98C1!xne zmR^_GmGy^kX>qwj&$B}-Xrt?i)j~0cyL5gX&5Ls7TX>Zd?-=74dQ<1{OAyi(gm-a3 z)87!wk*D;lx9_6db|d(uGW70KRSq`qpkrG4wbGX^AL{Wt(2QW_rz$)`$8%<_t4%`p zN_dQH%jD@6BWm<5SOj>aGN#zDcj7=eLlU#LR0Xd^FYP~ZzrFGF3J0l^+d#cwsb2GG zsUtIn-m#l4C*GN3KZd9zuoH@M(ULqCj<2{?_TGUC6WsAwi;m zG@$)bRJy_7QGTtQ!cT}U;CL_~!xM+*5W&k*)qDiinHOKgFyFyV^~2OG+vEB(!cWCP zdbca}M&8t9hMHHt6R#H!`Ys=E7CRAQUlpS6a^hn+7A3z5C#}XV>zT33m&zV^PQnWC zD%TN&cD~Ntro-5G!`NPFyKr95u-O?<&~7{ZDI6Ca+S?wxbFjh-^1NtI&!@l{o^jej z$Qjga)CZ86VL|kORrx}atvJFqkhAAU zoUo41z3rds3Z4Tuu5$8oGDmnfqDRGw1C9i+%QjorF>@0iukHoQuG9p#6KjO7m^W~R z4i=Jk{!AO+h<5j2ZmCP{6DMA=bBhk)^WlNL24jJmWXU2m$VT+Z5K&;`&kx_La|v## zBfd#J7?`=ueQ~#GzUYRW=N~fG*?$s>uwu;c_Q1>bvsQ|@QP-xsrsjukuFCm;8!vB2y>qfvnebWfpT%kILa9nvo z`V3b!yA?ZB>}+NwV7iL^QCwc!y>GdXg-sg+w`L`sJDT}yX#;K%KJ;K-;c( z@i~{>6g%Sl?U`!_Zn8rW%vAIntqEqzjQKG_E(o9e;#zl$Hg&7r@E1KaTo#mw@1xQ@ zGJE|?3GJG{e8J69BpJ!}`pzg^%;nS<)8Q!MqbD5DHTHwLxK|M!$sl^g3i z+CJ`!1a%uGDeBdlt$%{sR~eo+%TVWK`eja5?!h6MblCek+pQsUy0BfWWU?^LZ~Dx^ z5eI~px3I8j>rks!`{OpT8p!17w8#-|G~)A(T;N{6NQxsyXqp>$(GS;kFzcW0Z=lS0EkN4;2pSkb* zTF!OOxz2v@!}?0Uy*j!ye-$TMN}DYTQT%(l-P7gIb{%#-!X)fXFM}vp#?wX%}eTHf?CK^y}=A*u6@jB$E?kgF8)JDuA zd`xIzG1UDE`irs(zaF4Q*H!V#weKoJ=(G0L)wO@5oKHMLC|aX!x^z#55^xpj1EAb` zlljPPP?3OYXkh#IsKwthakhmWafb*F@BcC7($l3GvuoOKqN@sRe9-*#SMk(SKI|`g z4bw=4@%Sc;`3yH(kenz1(pF+83)#b^#WDFWnx~Tn zFFo-zIyKF8=>Ey?RKI#bAvK1e8Hl^_>C*6&v{fy#XHUTKo^S^Z4k~BcAG@FYJ4gHv z)zUiG(|SHG$17^S+Rj#1BvZbJ#DPd_Rv=1fNZk2n!|Yo#JN%EC8_b712R(cHX8w$X z8Yb1Qi{g{Bb^^vZO#)U)esWmuC%LH?Hve3Te0iKxfNk-$G$|J<4zQ8)lHaZ zPsZ}s*uF?6{Mo=&bfxPN^*1@&_ku(?-uH?K52~l&;eXDUZ+9Zgt!vY}#p*>yB#QU{ z2e(AIf3SKy%>Qy^u#nYp6~65yL<~kMz72}{It4Oc@<3?(ufV>HOh$WilGV}q?^u3w z() z9-Wl-b!0bFNITDG^OVKKE^ByB5HPHNi<`ggQc)S#(WNuVsB7ObcK#Lrk}-=z7Lh;p z&QaeSw!FAa6)s9mhS??h2(wFaYn_ch7BesNat_Bid`X>CVJFVXwl=s9!a1H4Rt`C< z@f6>v_d#M*4Z%ClO-`R*fn*5?y@X^5`8BK7<^$#mPc1m8i<#uU!ibaXa$1fIic%?x zkTR5CNpLRYa&gEyyksB|f8Q9*R!%l`cC@`aFqE}#B9nDLFNAawH8G9!Mi^CYbnF{M z)vsU&;By@>72o>yDfzJQ#u5jnOAi7DkShO!0lWR-BxqL%sTI1EB0h7Oc#DJj)CKGY zt>Lb_-?QA(97%D@MoWb|+)pdi)BP0!W-gGHZ5RDk;_Ih~7wMawY%Mn#y+wN{klG-S zu%2H+8R6D;=*954Q!HyEe|?oeTahmYi8Ni$LmBR(-Y-~hI;8NLd}xphgec9Is&Jn$ zQr?9NIxEb=G0`m4s||kg!3!U;G-7aU7G938MBdZZ(a)xT>_PY$|+t9TagkHyyEqBC^Scf)-ID5*ol+?#eA*`LgZX}&HP`X%FSiZSzLVLA52rJ)DvH2kqVJ?HYhnop;!x33P6{1sY= zw>~jsFtU9v26tG+PaZPy*J3UI?EV!hKK75knO&Gbs#GLz-t4Kh72?iPJ}=A`;*7j% z3!#3+nvIurUzSzyhe-{8LhqxUrRn>7{v|#H-)r!NulAI@DCmPKIBq;vefCbg0>NmI zUW&|~F2?DcndeeU^{_wnYPh$-`^FajNs~9}KhgLxL9W8bl}$wNN39Cc0dOFWF{ijBLzBr!QCE{da<7Cs%n`B((*_Cr49;a}vyuWfX%P6t!e{El!C{^dyV|hE9 za)VOT>>7K{m)T{w`)PFlBR8>Ne_nfWY5R!VvqCnFtJEL}V+exy#ymL-G7$HV=ktW{ z**_}uYe~%|YYbJP#9}4AmS5U+BL&1S(n6s{<74&CKz>Qahw8K!KYXd59`AR7QVvl4 zCC^IPA1iAw4wP0fE8kXxI%)KQ^ep?i2bL5#qm2=+m%LEL)EANRqb-G#bCg?vUO%=3bt1CR1T4;P7Ka84F-HCvPm z61orBU~D4B)*lP~hua8;p@J0=TodKNC2MuhMRV@@P`)1>b^N#_h>tSoCgw1mzsOnQ z!(04ru^h~SRIKAAOSAWmB65T6z;0WjK2RsFLG`anOIJ$t_nM%^B?ZcqO?jhQaPCQx zG8F=LpiPH-;OexjcOLh7(L#SE?D@YW|GVTX)cR>{o_*HiFpPUXiujcK*knzS3UrsL zU0P%QD|5Z$wRMGzY#>z#_bDRMY??;ArlixW^qW!5u=~l{*P)NSb@ukcE#D*bRFTjf zqfT7{;d+YsBksibNrs`}7gK&Y|uBWwER&dfc;n zp;eqERMw--PSCuiq#OK=_+{yxo|mY3U!!_~{94Y(P0)7@byu_$gw*dq-rE#z*vWaV zU|!QTtmnB*JaH!s^(8y#TJtv2HLdpNH<-o`ec`|^fFy5+95+a=Esp-g2eCul1EXSg zZIG_DI4R&-H^Huou{jxz(eTiV{u!U{+A%#LbzqvDDO$EF zw*JL^Y`tSBk2};$`%4?0cqn(viSKU)l%SS2-q4hJ zd_{^X+lxx!bvX8urGN6cmnN+1itR-01Z9xn{6q`Ne?=wEk^3{q<2UdhWHWDNgk&cE zux_vLiBunRKG7R+(JPsZgugh zjd5mXXOD30x>za-zJ*-#-OMf`%#^8>cVlW`gi{!}-;ah!zSd$*$U2YUcXM&t$l}*e zkDcPC{|;2}B2kSXwsxetQh$B+p>w>F{6<&2)sp14xOW;KRSyfuh%Hhd77?6fqS(jZ z=*x2A-`sn2ky+HAHA~Igm_|)ui>5SsT!HIB1wBspO2~_~F}!Vp{&eupAu{u0{)Tc5 z@HD+BLEB0%pV_f1EThV9kJ%;AD`S)ml!r?#<%J4Z%8Y7*ozX$4*%K9vMPExoSONY5 zGv^3mpDwh5n9J4oppH%M)8Y|XZ?6x(-$Y)!>iR}&pV`4w7O;6ikh`e4akVEO2Rk_? z+KyceN_@0+T`O{|CwYMFb9~^vN7^J#I^KR@$Pz56kNMNZrwA)Y2?mhsWklj-++VkI zQdn8jflv3KbDyE|aG8AS?yOo@TZQXl@gp*$T<#N^mc+{Q{-Sx255lQQ$6YJeKr9+| zZBN@Tzdx<*$)f$J#pMYc-|x3l6Hi>?Zu?Bob%BeIcK#TCI7|Jx?QJRh2+rkvDuPJh zCC-A?Nhm4%k!$Y{Ty4tdABNtpifK($e(9Y|r4_G1dle`C#HWzIR|kvo!O{tY%X)X-?eci_mE%Ga)UWG4(h zbKbm}H2J=KkyB$fes+($Pm8#1k0WzSg;9I#iG*_mC|4dkNj9+P zZz+qV3%%Lx5(-5)a?W;{4Dc-tWEW~U_+uMwr?!NSDpS41Kx0|-PmCa|-(alS4RjiFvr0B{0~UGcxx%@Dq5-qE){j>4 zHJYYncTPbyCF)=C84U(i-oC$mm_v&*Kes8UxfD^WJ{jHSIDZ`9iCQ(U;TVg0gqlY7iYtR==( zIZD4Q6el~Z4Dx>jfA%H9&q`gww6Ibs)>A3UW%3Z_Gb8lJHc1tjQy#7`=Cm|6L1GQvB8=gN*fZ81 zkzU;OO+0GU7;B}z-|Ah4eZvikY%0j74Jh}Hh^MAPS+j#hMi#5LD+>0n>U3-g=m;03 z&SPoe^vLFtla zfWWFV^3$Bhj5D=OJV5Y#-&zxr^x^L?wWPjc4Dq*fb=qANxM|GU3cOp%gHOPb74$)`5_=U;JUX4b+y@B`3jImMnEH zt7C+}7R|m9br?PD@=6F`#{oDE9@d}4uOhc)#WGIYvjAr4dQGWvp&j%ny!5!=Oryy3 z4=T*gto~RppHR`oyIs*CePs!YD0M~A{p#xuhJB$uYP7&3+?L$n0%njAHT0w0Ooiezy5V@!YFtC03l2f zA@uT`KUU^qu2b4n-1n;yvjYCuJfau!?!MF2bV0E@kYAsA^c1d0{xx5sNT`rkCM3Mp zKSgrmsJ#L&7Vw|hxin)Pr-V|w%Tns0r{Co2z{~Mi=FwVWxE;gMa819Jn;d@%tz{>Q z1gA*!sbN_DyP>KSZ6*+M#jha!yL2h^#1?nr%>22*(W&3c zCwc<2Nyzj~Mw?Vm#jW!ae3{f^v}-pP#z)=q`WBc-FF8p*z5}_lLlugkE_h9auzq!5 zxMUwuxst7j(4UY~x0;n}V`PCS+gH0?d9QpC%z|vD$u)glzIO~LbJ62uDq3l|=dhEN zGhWj7q*F?3(mUiWz>TDH+c3!eyqA-6q@qp6Agwpas=$1}7Sm!9wJKZOcYv6(8rviB zO~sSRX##ck@}WxV!YHT2rhX}TBo`(2CTV??yL5Q5SAoj+-#(#3a{FUz4%UVmp6K*= zt@w6t_nCo7g84hBkc1FVz|trW%&{fyBOk^N2yl%tPctNdQgfomv9>wb@R!-XDQ4rHdK>VzakLPFn9zH40$h_t5=$p2oiaZ0<}VHdl!{?#^(yf}fRIa9$w zJskhoQj(YV=(T5zo#pN0}aPep3-UXj5iQo_5FV7?Sp5q#n31lj1 zIo`jazc&Y+^GNMLRA_)gSxQsq*b(5xpVLs|GE`5ArRW6?JFf9VZPY74H4TukYzn;0 zWuaPGUT~GlnSd)UzmMYQTt4H+9YrykL_`D@JQ9`y{T( z_Rwor7)xOB;>rx&2I@rEzL0Tgz9e}NP?Bo#8WZlHm3lNGqiby-QL}F-#W4B0OhxJ0 zzdrof&9bM|AKVJpE7-vw2!4Dw-eiMCxLv)l5bAxuENn;6Z3^FGM>*?_inZg^!i$gi zlXdoXXk5u2O^>g9sfaK#?~qS1X=P-I>tLG)JHU#y7VDcG6}u*J7v(}3t-~A#3-z-! zj^c+suGl+IsoI3Ay*SEBvdZ>3(Q!WUGt&Q;Tior!$8J7W^4bd1UV)wm^Z1tQkMkPU zm$49x4iGMAl8=n%+c)T`vGjwL$|ZNG1Y#-j>~t^RX^m7ePV8yF2Uajl+@;^T8Z%>kn5e;KI`CDxVfHC%q<=OZ z{;M4vR{z8g^2K=%@Xs%4`F%^yn{eXUyGr+JZJz_hI-69#uxM9C*guiG2q^yhS$GSS z6FwYFHF=T8?*HyK(LH>q4S7#6BB+#D35um+MI;Z|x@tomW0PYeSZIEz`2McXEfKJf z{$~>u-`t9pY`dw_E(4dj9J8Jwp3@_Wh-X1PWs-Xc^L68y^{$2kHDF3=mp4Q^^iJN3 z#f@Gn8n;@FyVeCd@>H6Nyq-1x>inOg1q(vW;6i^ZL84RthB!f9r`yN?(`aDbLyBKc z=gn8<^;vgZS)BK{w?>qcMy*$cJbaulKjd{rYdxYT*(bn4d8KvbWy@hx<3cM+8Sc)= zgm2TxQJZrhsz@E}&39;!9h#D9D1c4=h~*4Eus;4FUc<;oF;$XnOh~q=bAiquy8~40 z3_^$p+*MN&yUz#y7=_Ryi{g#j4z9gMo-$pl4JrM@S|-H7o*?%lh7d9_ow8DChsGi4 zG$#M7)x9OU_c3#pYTx0$i5XDzat*Q%2!==@q zeIC2i%aMLm<{mb+CA*q5);8S5dQnmfR;nLhJQ}dPjAus%E;eh6hM@CRXD5&P(&Ko? zIHgHe;nK*FedIBZEJrq5G+G*6Qc%g1`*i)Y?1#~u(SZ1uWpI5G&m zm>&bi6T2r{v?9hUa(dC7tjPvR1rJb6u6y&p#9r-S+`I_Dnq$X14ty+au_F}8gW_dZ zxCj~@|KjTFOT84P&`e=Ci1wfqPP4Sk-_*RAlFcJ>>arq+P_8Rin(d z0JP@y>(opkskdLpXr*vly_?~&u?Y@7-((@XSN8)6{3owz35OAc#`)yD^50eSxa)kT z_D}$M*I2xNyjlZoDvA3u@#0J5nz5^>!#I$ZwfI9MjWzoB$CS9iOyA>p4pp!2RH1t{ zZjGEE6na!Z)ctZ-)O*-OAFyGq6|jr)T~4}vpLRsCl@WKWJ5zKy3oMb~h)!PYs{yku zVx9HPcvPRk$TGYCVq9io<_9McR04W0r^aheI!0dQ-Do;wncIVU34hVwj>_Sdgh-*G zDP0K*)GXVpx0M-+gy{o*D?FMdWjI=N_oK{7$9zb&sVMww?@*2fhgA<`n%+JOrO^qs zS{R#fPZI&Hs@>;z(BmGg)Rcsm&dB05#{}#9ezhHJy|9j?ynJlr2AWFPw?G!T@=b#$$M$>3J^-tCDB`0M@9T-c|LB zRmAk8!^QPN@+S%k)MU#c?tZ*BAc&om z`Z7xqG38qMu=m)md4#{H=kK>c9~z__sQ{PQkw}#4AQ<6s?1UlrrS`SmFRf{{V~Pan)^qn#NiQT9iUn{z29_S z%J`keK!|fx9eBsFnrX)0Gb=)}5}W;vOPsoMIn~BzV028bnNgT1wot()FxkRknUtO zK?P0;`--SM_vs9HCcAu9T?s8yE1S%K6St+H_`Zb6-Dq&WA{&tSxlE``{)qsrPhL-G zPVM}n@0T_2wnC1m5ST#lPcip*Jzf_w zeJ2==1Kn+6#CWH-+`8!SxjTjz4dJ#Y*3?a}@xSU6tPs?|WCVj+iYrpr+T)tcLw-?# zt)E;j@X^7%MDZ!wo@bi9w zZo&e>vS8GFZzn&hikOFs+uGsbDrBh22S~-YZY|V z#i&>fhUe@0u`>n5o_x|Y#*9nqiF>epK8IY}Yvmse$2=7#lJ+giLGJh_K;#uW&V`rWtCyOKyLF8(!pK*2*9!yx#Lm%(&K!G zo%WHJJBb3rLGu}Ui!}5&PwtGHdS$F_Ejw|tdbolXl(wJKB8urs^~rfbLWS!ce@eRA zb*1if2$OX8-0=7)4$|~{uVYGGd+mC_;DTYSC$aXJ?_;HVV;-IvO0~h@s=j_Z-n~bD zeZ?7}z&kgpB10=Qe<{e$OD#WAM3B1gZw1RjzXC(u^rVbYbl-*#Al=vl1J|WdvJvUhQ(? z(s+py=#cZyzN0?BtH_?I1aZ4GMX=w+Q<8;OPdb4oz(VJ$>j`}4M4$_|8E3NiVf@f1 zJEY<>8-hCiRCFPF>pWfCD!jl6Gb-Ua@47Vk)96>m4y0^SRq(MrZgST7Alav@xjQhx zrS;oucsen24X=a^1f|gA)E(a?ikXF&-926%H~#ef%=K7ppUV5P zBKPBOFD_NwXPZpqr?|J)hq?E-c3sEphPDU&If9K}o){q-#coK1Vz24Yce|R7<@ymm|9qs|Akiwym(KaZa~I<5#5`y1V)VU-6-~sIkyH4Qw$GQn z`_^SZ@Js5i48o!7d%c#hQFHNL`m#c28& z#g@#k5Oba;Ejvq+PG0zi{HJSL&QE{FC-(mKNmunEuPAzvGdQzbRsAcLwH{32v`pw{ zjA+>>+=I=$Vuy~_IPJlRFr;4uVUOXL{zr#X(!P_?ngM*Ll3uE&&8+#Y`MlQF+rjA_ zTqb&<_(6U2OQ-hB-mxBi!92xG?7olRnZ#^Ns(bJA5_=Tqf!R0gGkJ_Xe=oaz>4S}% zAqR5KhGhpMR`~ee7|RCdO4hq}_4yKRo!dq|w@=hr zJ@W7PSlN@71C4mXL~I+RTaOSr^W+%XJ+TV@*r2{=r>dSWo=(t~Y_rA8)X)&{!(Wa1 zYBDZUG7iYGR?#qUkq(6#(wDe-H!WnnAub%UL1k2Z=|ko-RN3>IuU+2b^XErREz5zK)Ug!zKxofrk`VxAsD}KL$8&IUVc$r(O2M8OqiP)_!7O+~|rFRq1|t1oubkWH}#kmj)26+kf|r9I!n>(W+3PH}Bga?RRmT7u6dIR;GR2CRInHG119)-5@i6S@;;@NGcCx*=~G z0PU0+7SYN?Q*yyF=BoFnAH!NUTa6q1Sa`#@Y#Y@5D0SwXl+ZCK^BaH;VZyei!5He4}=EHaYjrR-XlOH87=Jyy6Y1Jai8E%3Y6ILB>!T)_p)R z9@f){(qyJ-YiG#28B?5DD7^`b>f?pbZYZ!oU8w$c*UwL$XT|ZImC1KSl3a;&S`Otj zeg*8D~%B7=B!5&0KlE1NjZj&#|O<{*F`^=?k<+o)NZP&u{;+ z1!(~w*7SvLMKdV=BF0(luE@=PfNZ@!zPhnIU0ZQP_rtIr+BuPn=2KP<)Y07Peo=iz z?Smx=uXJn}tyDV3XBXjvp}7B4*OvT&ka!PegUR?aP^YH9%W&QxbY4!9NULbX% z?X><{e+1#J$i+dd&x2p?pNF7OU5F>mzOc*xod?pUBF)!YdX5mv!xqSpQ6umzN`b8+z@s5~}z z$cX#x@yyfvN=)lsnjd!*F*fg`wpvw432qEVITl$|J+e4ivn7|@_XQ*OM|NuZoA}3p_%*ey6CgxwxYc5qR*>eW$c!R^XtcG>BS+!;5<#0G z>hl^4Qui^M(^o!1R8rU0G2Q5J@dSNE;3|NjS0DO4Kt~x2&n^ZWeaqHKIElr@i^Sv| zN`YMTsu_C`ePplNt@8$;ogMcZsO)$wb(^}#YR<;+enaYdpV(_yQ0G?9Y-iiGRo zTU*7@Y_5a5MhL?D8o`#(N<-6d&e+$@JX4`kWQuJd2m<1#%Sb(EjXJl!prJY80P|n85b%a?Out{W7!ulU1$9Jt zVlzJcvL5(kBEkHPHQxRxPhu094}JpmvjiG_xfO0VbGaS-Yc3Po=o|qH&-*-^hNjN# z?ly|KaA>9GkR-q$x{}g?y}muz(jYnk3#T~*E@9e+biw0@quY;+;2fw#(*}u)2{4ai z=hpeq0NaJp(gkJAMEtQd(9fhaW6$kr{AAu?iKRXzTX55 z=srn}V1KXR+WtTsp!p4m7owEMQCgIW?cc)_e$Cl-M1s?BzeQ(cuJIP~!qaG2YMt75 zh<(?WR7;!trz6v8SSpo%@Eq5^OITnL+lQ|>1T*6Vy})XIvoA6to@sjqDgp!C!KX!l z4pVwl+e@Xv0wPhNPG&ZM!l-jwyc)h5G=`D35+>gGXpeXv+8$}zbPFj#ToncOGxtvu zu|ZAv!ckjy2T~wPO}ox>yW!KolclytSPA7^=I;czYK# zbN8ualnmv4ujxxzBt6=mnSsbZ12y4wUt^NPy9QF&ia;0vv8CjWyneo24<`6=W3 z_qy6iFF}b`B!o%xB*Io#rhtKH%}5%r15@;<|s!SMaoW z3l4NpEJ7`WAww5{v^?SeSB#Sysr2eLIP5mnNvgwom2RSVx;{X5v diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/publisher-portal-light.png.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/publisher-portal-light.png.meta deleted file mode 100644 index 2f19af2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Icons/publisher-portal-light.png.meta +++ /dev/null @@ -1,135 +0,0 @@ -fileFormatVersion: 2 -guid: 8e0749dce5b14cc46b73b0303375c162 -TextureImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 12 - mipmaps: - mipMapMode: 0 - enableMipMap: 1 - sRGBTexture: 1 - linearTexture: 0 - fadeOut: 0 - borderMipMap: 0 - mipMapsPreserveCoverage: 0 - alphaTestReferenceValue: 0.5 - mipMapFadeDistanceStart: 1 - mipMapFadeDistanceEnd: 3 - bumpmap: - convertToNormalMap: 0 - externalNormalMap: 0 - heightScale: 0.25 - normalMapFilter: 0 - isReadable: 0 - streamingMipmaps: 0 - streamingMipmapsPriority: 0 - vTOnly: 0 - ignoreMasterTextureLimit: 0 - grayScaleToAlpha: 0 - generateCubemap: 6 - cubemapConvolution: 0 - seamlessCubemap: 0 - textureFormat: 1 - maxTextureSize: 2048 - textureSettings: - serializedVersion: 2 - filterMode: 1 - aniso: 1 - mipBias: 0 - wrapU: 1 - wrapV: 1 - wrapW: 0 - nPOTScale: 0 - lightmap: 0 - compressionQuality: 50 - spriteMode: 1 - spriteExtrude: 1 - spriteMeshType: 1 - alignment: 0 - spritePivot: {x: 0.5, y: 0.5} - spritePixelsToUnits: 100 - spriteBorder: {x: 0, y: 0, z: 0, w: 0} - spriteGenerateFallbackPhysicsShape: 0 - alphaUsage: 1 - alphaIsTransparency: 1 - spriteTessellationDetail: -1 - textureType: 8 - textureShape: 1 - singleChannelComponent: 0 - flipbookRows: 1 - flipbookColumns: 1 - maxTextureSizeSet: 0 - compressionQualitySet: 0 - textureFormatSet: 0 - ignorePngGamma: 0 - applyGammaDecoding: 0 - cookieLightType: 1 - platformSettings: - - serializedVersion: 3 - buildTarget: DefaultTexturePlatform - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Standalone - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: iPhone - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Android - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - spriteSheet: - serializedVersion: 2 - sprites: [] - outline: [] - physicsShape: [] - bones: [] - spriteID: 5e97eb03825dee720800000000000000 - internalID: 0 - vertices: [] - indices: - edges: [] - weights: [] - secondaryTextures: [] - nameFileIdTable: {} - spritePackingTag: - pSDRemoveMatte: 0 - pSDShowRemoveMatteOption: 0 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts.meta deleted file mode 100644 index 63c6efc..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 15b24ad8f9d236249910fb8eef1e30ea -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data.meta deleted file mode 100644 index 1382bf8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 930cfc857321b1048bf9607d4c8f89d3 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions.meta deleted file mode 100644 index 73728d0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 771776e4d51c47945b3449d4de948c00 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackage.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackage.cs deleted file mode 100644 index 84033b5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackage.cs +++ /dev/null @@ -1,34 +0,0 @@ -using System; -using UnityEngine; -using PackageModel = AssetStoreTools.Api.Models.Package; - -namespace AssetStoreTools.Uploader.Data -{ - internal interface IPackage - { - string PackageId { get; } - string VersionId { get; } - string Name { get; } - string Status { get; } - string Category { get; } - bool IsCompleteProject { get; } - string RootGuid { get; } - string RootPath { get; } - string ProjectPath { get; } - string Modified { get; } - string Size { get; } - bool IsDraft { get; } - Texture2D Icon { get; } - - event Action OnUpdate; - event Action OnIconUpdate; - - string FormattedSize(); - string FormattedModified(); - - void UpdateData(PackageModel source); - void UpdateIcon(Texture2D texture); - - PackageModel ToModel(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackage.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackage.cs.meta deleted file mode 100644 index f0a0de3..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackage.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: b92f2ed98d0b31a479aa2bfd95528fbd -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageContent.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageContent.cs deleted file mode 100644 index d82520f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageContent.cs +++ /dev/null @@ -1,14 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace AssetStoreTools.Uploader.Data -{ - internal interface IPackageContent - { - event Action OnActiveWorkflowChanged; - - IWorkflow GetActiveWorkflow(); - List GetAvailableWorkflows(); - void SetActiveWorkflow(IWorkflow workflow); - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageContent.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageContent.cs.meta deleted file mode 100644 index 3d538b8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageContent.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 45ce41158c3174149b7056a30ac901db -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageGroup.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageGroup.cs deleted file mode 100644 index c35936b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageGroup.cs +++ /dev/null @@ -1,17 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace AssetStoreTools.Uploader.Data -{ - internal interface IPackageGroup - { - string Name { get; } - List Packages { get; } - - event Action> OnPackagesSorted; - event Action> OnPackagesFiltered; - - void Sort(PackageSorting sortingType); - void Filter(string filter); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageGroup.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageGroup.cs.meta deleted file mode 100644 index f247540..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IPackageGroup.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: f683845071b8891498156d95a1a5c2dd -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflow.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflow.cs deleted file mode 100644 index c6e9b81..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflow.cs +++ /dev/null @@ -1,36 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Api.Responses; -using AssetStoreTools.Exporter; -using AssetStoreTools.Validator.Data; -using System; -using System.Collections.Generic; -using System.Threading.Tasks; - -namespace AssetStoreTools.Uploader.Data -{ - internal interface IWorkflow - { - string Name { get; } - string DisplayName { get; } - string PackageName { get; } - string PackageExtension { get; } - bool IsPathSet { get; } - - event Action OnChanged; - event Action OnUploadStateChanged; - - bool GenerateHighQualityPreviews { get; set; } - ValidationSettings LastValidationSettings { get; } - ValidationResult LastValidationResult { get; } - - IEnumerable GetAllPaths(); - ValidationResult Validate(); - Task ExportPackage(string outputPath); - Task ValidatePackageUploadedVersions(); - - Task UploadPackage(string exportedPackagePath); - void AbortUpload(); - void ResetUploadStatus(); - Task RefreshPackage(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflow.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflow.cs.meta deleted file mode 100644 index 6efa281..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflow.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 7a2f796eadafa774bae89cf3939611dd -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflowServices.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflowServices.cs deleted file mode 100644 index 6987b91..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflowServices.cs +++ /dev/null @@ -1,18 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Api.Responses; -using AssetStoreTools.Uploader.Services.Analytics.Data; -using System; -using System.Threading.Tasks; -using UnityEngine.Analytics; - -namespace AssetStoreTools.Uploader.Data -{ - internal interface IWorkflowServices - { - Task GetPackageUploadedVersions(IPackage package, int timeoutMs); - Task UploadPackage(IPackageUploader uploader, IProgress progress); - void StopUploading(IPackageUploader uploader); - AnalyticsResult SendAnalytic(IAssetStoreAnalytic data); - Task UpdatePackageData(IPackage package); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflowServices.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflowServices.cs.meta deleted file mode 100644 index 70b77be..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/IWorkflowServices.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 0ae017363fa41ff4d9926dc4a5852246 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/WorkflowBase.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/WorkflowBase.cs deleted file mode 100644 index cd3462a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/WorkflowBase.cs +++ /dev/null @@ -1,253 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Api.Responses; -using AssetStoreTools.Exporter; -using AssetStoreTools.Previews; -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Previews.Generators; -using AssetStoreTools.Uploader.Services.Analytics.Data; -using AssetStoreTools.Utility; -using AssetStoreTools.Validator; -using AssetStoreTools.Validator.Data; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Threading.Tasks; -using UnityEngine; - -namespace AssetStoreTools.Uploader.Data -{ - internal abstract class WorkflowBase : IWorkflow - { - protected IPackage Package; - - public abstract string Name { get; } - public abstract string DisplayName { get; } - public string PackageName => Package.Name; - public abstract string PackageExtension { get; } - public abstract bool IsPathSet { get; } - - protected string LocalPackageGuid; - protected string LocalPackagePath; - protected string LocalProjectPath; - - public bool GenerateHighQualityPreviews { get; set; } - public ValidationSettings LastValidationSettings { get; private set; } - public ValidationResult LastValidationResult { get; private set; } - - private IWorkflowServices _services; - private IPackageUploader _activeUploader; - - public abstract event Action OnChanged; - public event Action OnUploadStateChanged; - - public WorkflowBase(IPackage package, IWorkflowServices services) - { - Package = package; - _services = services; - } - - public abstract IEnumerable GetAllPaths(); - - public abstract IValidator CreateValidator(); - - public ValidationResult Validate() - { - var validator = CreateValidator(); - var result = CreateValidator().Validate(); - - LastValidationSettings = validator.Settings; - LastValidationResult = result; - - return result; - } - - protected IPreviewGenerator CreatePreviewGenerator(List inputPaths) - { - PreviewGenerationSettings settings; - IPreviewGenerator generator; - - // Filter out ProjectSettings - inputPaths = inputPaths.Where(x => x == "Assets" || x.StartsWith("Assets/") || x.StartsWith("Packages/")).ToList(); - - if (!GenerateHighQualityPreviews) - { - settings = new NativePreviewGenerationSettings() - { - InputPaths = inputPaths.ToArray(), - OverwriteExisting = false, - OutputPath = Constants.Previews.Native.DefaultOutputPath, - Format = Constants.Previews.Native.DefaultFormat, - PreviewFileNamingFormat = Constants.Previews.DefaultFileNameFormat, - WaitForPreviews = Constants.Previews.Native.DefaultWaitForPreviews, - ChunkedPreviewLoading = Constants.Previews.Native.DefaultChunkedPreviewLoading, - ChunkSize = Constants.Previews.Native.DefaultChunkSize - }; - - generator = new NativePreviewGenerator((NativePreviewGenerationSettings)settings); - } - else - { - settings = new CustomPreviewGenerationSettings() - { - InputPaths = inputPaths.ToArray(), - OverwriteExisting = false, - Width = Constants.Previews.Custom.DefaultWidth, - Height = Constants.Previews.Custom.DefaultHeight, - Depth = Constants.Previews.Custom.DefaultDepth, - NativeWidth = Constants.Previews.Custom.DefaultNativeWidth, - NativeHeight = Constants.Previews.Custom.DefaultNativeHeight, - OutputPath = Constants.Previews.Custom.DefaultOutputPath, - Format = Constants.Previews.Custom.DefaultFormat, - PreviewFileNamingFormat = Constants.Previews.DefaultFileNameFormat, - AudioSampleColor = Constants.Previews.Custom.DefaultAudioSampleColor, - AudioBackgroundColor = Constants.Previews.Custom.DefaultAudioBackgroundColor, - }; - - generator = new CustomPreviewGenerator((CustomPreviewGenerationSettings)settings); - } - - return generator; - } - - public abstract IPackageExporter CreateExporter(string outputPath); - - public virtual async Task ExportPackage(string outputPath) - { - var exporter = CreateExporter(outputPath); - var result = await exporter.Export(); - return result; - } - - public async Task ValidatePackageUploadedVersions() - { - var unityVersionSupported = string.Compare(Application.unityVersion, Constants.Uploader.MinRequiredUnitySupportVersion, StringComparison.Ordinal) >= 0; - if (unityVersionSupported) - return true; - - var response = await _services.GetPackageUploadedVersions(Package, 5000); - if (response.Cancelled || response.Success == false) - return true; - - return response.UnityVersions.Any(x => string.Compare(x, Constants.Uploader.MinRequiredUnitySupportVersion, StringComparison.Ordinal) >= 0); - } - - private bool ValidatePackageBeforeUpload(string packagePath, out string error) - { - error = string.Empty; - - if (!File.Exists(packagePath)) - { - error = $"File '{packagePath}' was not found."; - return false; - } - - if (!ValidatePackageSize(packagePath, out error)) - { - return false; - } - - return true; - } - - private bool ValidatePackageSize(string packagePath, out string error) - { - error = string.Empty; - - long packageSize = new FileInfo(packagePath).Length; - long packageSizeLimit = Constants.Uploader.MaxPackageSizeBytes; - - if (packageSize <= packageSizeLimit) - return true; - - float packageSizeInGB = packageSize / (float)1073741824; // (1024 * 1024 * 1024) - float maxPackageSizeInGB = packageSizeLimit / (float)1073741824; - error = $"The size of your package ({packageSizeInGB:0.0} GB) exceeds the maximum allowed package size of {maxPackageSizeInGB:0} GB. " + - $"Please reduce the size of your package."; - - return false; - } - - public async Task UploadPackage(string packagePath) - { - if (!ValidatePackageBeforeUpload(packagePath, out var error)) - { - return new PackageUploadResponse() { Success = false, Status = UploadStatus.Fail, Exception = new Exception(error) }; - } - - _activeUploader = CreatePackageUploader(packagePath); - var progress = new Progress(); - - var time = System.Diagnostics.Stopwatch.StartNew(); - - progress.ProgressChanged += ReportUploadProgress; - var response = await _services.UploadPackage(_activeUploader, progress); - progress.ProgressChanged -= ReportUploadProgress; - - // Send analytics - time.Stop(); - if (!response.Cancelled) - SendAnalytics(packagePath, response.Status, time.Elapsed.TotalSeconds); - - OnUploadStateChanged?.Invoke(response.Status, null); - _activeUploader = null; - return response; - } - - protected abstract IPackageUploader CreatePackageUploader(string exportedPackagePath); - - private void ReportUploadProgress(object _, float value) - { - OnUploadStateChanged?.Invoke(null, value); - } - - private void SendAnalytics(string packagePath, UploadStatus uploadStatus, double timeTakenSeconds) - { - try - { - var analytic = new PackageUploadAnalytic( - packageId: Package.PackageId, - category: Package.Category, - usedValidator: LastValidationResult != null, - validationSettings: LastValidationSettings, - validationResult: LastValidationResult, - uploadFinishedReason: uploadStatus, - timeTaken: timeTakenSeconds, - packageSize: new FileInfo(packagePath).Length, - workflow: Name - ); - - var result = _services.SendAnalytic(analytic); - } - catch (Exception e) { ASDebug.LogError($"Could not send analytics: {e}"); } - } - - public void AbortUpload() - { - if (_activeUploader != null) - _services.StopUploading(_activeUploader); - - _activeUploader = null; - } - - public void ResetUploadStatus() - { - OnUploadStateChanged?.Invoke(UploadStatus.Default, 0f); - } - - public async Task RefreshPackage() - { - var response = await _services.UpdatePackageData(Package); - if (!response.Success) - return; - - Package.UpdateData(response.Package); - } - - public abstract bool IsPathValid(string path, out string reason); - - protected abstract void Serialize(); - - protected abstract void Deserialize(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/WorkflowBase.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/WorkflowBase.cs.meta deleted file mode 100644 index 65c40e6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Abstractions/WorkflowBase.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: d0e87ee17aa944c42b1c335abe19daaf -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/AssetsWorkflow.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/AssetsWorkflow.cs deleted file mode 100644 index 967bd9b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/AssetsWorkflow.cs +++ /dev/null @@ -1,329 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Exporter; -using AssetStoreTools.Uploader.Data.Serialization; -using AssetStoreTools.Utility; -using AssetStoreTools.Validator; -using AssetStoreTools.Validator.Data; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using UnityEditor; -using PackageInfo = UnityEditor.PackageManager.PackageInfo; - -namespace AssetStoreTools.Uploader.Data -{ - internal class AssetsWorkflow : WorkflowBase - { - public override string Name => "AssetsWorkflow"; - public override string DisplayName => "From Assets Folder"; - public override string PackageExtension => ".unitypackage"; - public override bool IsPathSet => !string.IsNullOrEmpty(_mainExportPath); - public bool IsCompleteProject => Package.IsCompleteProject; - - private AssetsWorkflowState _stateData; - - private string _mainExportPath; - private bool _includeDependencies; - private List _dependencies; - private List _specialFolders; - - public override event Action OnChanged; - - // Special folders that would not work if not placed directly in the 'Assets' folder - private readonly string[] _extraAssetFolderNames = - { - "Editor Default Resources", "Gizmos", "Plugins", - "StreamingAssets", "Standard Assets", "WebGLTemplates", - "ExternalDependencyManager", "XR" - }; - - public AssetsWorkflow(IPackage package, AssetsWorkflowState stateData, IWorkflowServices services) - : base(package, services) - { - _stateData = stateData; - Deserialize(); - } - - public string GetMainExportPath() - { - return _mainExportPath; - } - - public void SetMainExportPath(string path, bool serialize) - { - _mainExportPath = path; - SetMetadata(); - if (serialize) - Serialize(); - } - - private void SetMetadata() - { - LocalPackageGuid = AssetDatabase.AssetPathToGUID(_mainExportPath); - LocalPackagePath = _mainExportPath; - LocalProjectPath = _mainExportPath; - } - - public bool GetIncludeDependencies() - { - return _includeDependencies; - } - - public void SetIncludeDependencies(bool value, bool serialize) - { - _includeDependencies = value; - // Note: make sure that exporting does not fail when - // a serialized dependency that has been removed from a project is sent to exporter - if (serialize) - Serialize(); - } - - public List GetDependencies() - { - return _dependencies; - } - - public void SetDependencies(IEnumerable dependencies, bool serialize) - { - _dependencies.Clear(); - foreach (var dependency in dependencies) - { - if (!PackageUtility.GetPackageByPackageName(dependency, out var package)) - continue; - _dependencies.Add(package); - } - - if (serialize) - Serialize(); - } - - public List GetSpecialFolders() - { - return _specialFolders; - } - - public void SetSpecialFolders(IEnumerable specialFolders, bool serialize) - { - _specialFolders.Clear(); - foreach (var folder in specialFolders) - { - _specialFolders.Add(folder); - } - - if (serialize) - Serialize(); - } - - public override bool IsPathValid(string path, out string error) - { - error = string.Empty; - - var pathIsFolder = Directory.Exists(path); - if (!pathIsFolder) - { - error = "Path must point to a valid folder"; - return false; - } - - var pathWithinAssetsFolder = path.StartsWith("Assets/") && path != "Assets/"; - if (pathWithinAssetsFolder) - return true; - - var pathIsAssetsFolder = path == "Assets" || path == "Assets/"; - if (pathIsAssetsFolder) - { - var assetsFolderSelectionAllowed = Package.IsCompleteProject; - if (assetsFolderSelectionAllowed) - return true; - - error = "'Assets' folder is only available for packages tagged as a 'Complete Project'."; - return false; - } - - error = "Selected folder path must be within the project's Assets."; - return false; - } - - public List GetAvailableDependencies() - { - var registryPackages = PackageUtility.GetAllRegistryPackages(); - return registryPackages.Select(x => x.name).ToList(); - } - - public List GetAvailableSpecialFolders() - { - var specialFolders = new List(); - - foreach (var extraAssetFolderName in _extraAssetFolderNames) - { - var fullExtraPath = "Assets/" + extraAssetFolderName; - - if (!Directory.Exists(fullExtraPath)) - continue; - - if (_mainExportPath.ToLower().StartsWith(fullExtraPath.ToLower())) - continue; - - // Don't include nested paths - if (!fullExtraPath.ToLower().StartsWith(_mainExportPath.ToLower())) - specialFolders.Add(fullExtraPath); - } - - return specialFolders; - } - - public override IEnumerable GetAllPaths() - { - var paths = new List() - { - _mainExportPath - }; - paths.AddRange(GetSpecialFolders()); - - return paths; - } - - public override IValidator CreateValidator() - { - var validationPaths = GetAllPaths(); - - var validationSettings = new CurrentProjectValidationSettings() - { - Category = Package.Category, - ValidationPaths = validationPaths.ToList(), - ValidationType = ValidationType.UnityPackage - }; - - var validator = new CurrentProjectValidator(validationSettings); - return validator; - } - - public override IPackageExporter CreateExporter(string outputPath) - { - var exportPaths = GetAllPaths().ToList(); - - if (IsCompleteProject && !exportPaths.Contains("ProjectSettings")) - { - exportPaths.Add("ProjectSettings"); - } - - var dependenciesToInclude = new List(); - if (_includeDependencies) - { - dependenciesToInclude.AddRange(_dependencies.Select(x => x.name)); - } - - if (ASToolsPreferences.Instance.UseLegacyExporting) - { - var exportSettings = new LegacyExporterSettings() - { - ExportPaths = exportPaths.ToArray(), - OutputFilename = outputPath, - IncludeDependencies = _includeDependencies, - }; - - return new LegacyPackageExporter(exportSettings); - } - else - { - var exportSettings = new DefaultExporterSettings() - { - ExportPaths = exportPaths.ToArray(), - OutputFilename = outputPath, - Dependencies = dependenciesToInclude.ToArray(), - PreviewGenerator = CreatePreviewGenerator(exportPaths), - }; - - return new DefaultPackageExporter(exportSettings); - } - } - - protected override IPackageUploader CreatePackageUploader(string exportedPackagePath) - { - var uploaderSettings = new UnityPackageUploadSettings() - { - UnityPackagePath = exportedPackagePath, - VersionId = Package.VersionId, - RootGuid = LocalPackageGuid, - RootPath = LocalPackagePath, - ProjectPath = LocalProjectPath - }; - - var uploader = new UnityPackageUploader(uploaderSettings); - return uploader; - } - - protected override void Serialize() - { - _stateData.SetMainPath(_mainExportPath); - _stateData.SetIncludeDependencies(_includeDependencies); - _stateData.SetDependencies(_dependencies.Select(x => x.name)); - _stateData.SetSpecialFolders(_specialFolders); - OnChanged?.Invoke(); - } - - protected override void Deserialize() - { - _mainExportPath = _stateData.GetMainPath(); - - _specialFolders = new List(); - foreach (var path in _stateData.GetSpecialFolders()) - { - _specialFolders.Add(path); - } - - _includeDependencies = _stateData.GetIncludeDependencies(); - - _dependencies = new List(); - foreach (var dependency in _stateData.GetDependencies()) - { - if (!PackageUtility.GetPackageByPackageName(dependency, out var package)) - continue; - - _dependencies.Add(package); - } - - DeserializeFromUploadedData(); - } - - private void DeserializeFromUploadedData() - { - DeserializeFromUploadedDataByGuid(); - DeserializeFromUploadedDataByPath(); - } - - private void DeserializeFromUploadedDataByGuid() - { - if (!string.IsNullOrEmpty(_mainExportPath)) - return; - - var lastUploadedGuid = Package.RootGuid; - if (string.IsNullOrEmpty(lastUploadedGuid)) - return; - - var potentialPackagePath = AssetDatabase.GUIDToAssetPath(lastUploadedGuid); - DeserializeFromUploadedDataByPath(potentialPackagePath); - } - - private void DeserializeFromUploadedDataByPath() - { - if (!string.IsNullOrEmpty(_mainExportPath)) - return; - - var lastUploadedPath = Package.ProjectPath; - if (string.IsNullOrEmpty(lastUploadedPath)) - return; - - DeserializeFromUploadedDataByPath(lastUploadedPath); - } - - private void DeserializeFromUploadedDataByPath(string path) - { - if (string.IsNullOrEmpty(path) || !IsPathValid(path, out var _)) - return; - - _mainExportPath = path; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/AssetsWorkflow.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/AssetsWorkflow.cs.meta deleted file mode 100644 index 331e6ab..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/AssetsWorkflow.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 4657d35aaf9d70948a0840dc615f64ec -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/HybridPackageWorkflow.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/HybridPackageWorkflow.cs deleted file mode 100644 index 3759313..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/HybridPackageWorkflow.cs +++ /dev/null @@ -1,251 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Exporter; -using AssetStoreTools.Uploader.Data.Serialization; -using AssetStoreTools.Utility; -using AssetStoreTools.Validator; -using AssetStoreTools.Validator.Data; -using System; -using System.Collections.Generic; -using System.Linq; -using UnityEditor; -using UnityEditor.PackageManager; -using PackageInfo = UnityEditor.PackageManager.PackageInfo; -using PackageManager = UnityEditor.PackageManager; - -namespace AssetStoreTools.Uploader.Data -{ - internal class HybridPackageWorkflow : WorkflowBase - { - public override string Name => "HybridPackageWorkflow"; - public override string DisplayName => "Local UPM Package"; - public override string PackageExtension => ".unitypackage"; - public override bool IsPathSet => _packageInfo != null; - - private HybridPackageWorkflowState _stateData; - - private PackageInfo _packageInfo; - private List _dependencies; - - public override event Action OnChanged; - - public HybridPackageWorkflow(IPackage package, HybridPackageWorkflowState stateData, IWorkflowServices services) - : base(package, services) - { - _stateData = stateData; - Deserialize(); - } - - public PackageInfo GetPackage() - { - return _packageInfo; - } - - public void SetPackage(PackageInfo packageInfo, bool serialize) - { - if (packageInfo == null) - throw new ArgumentException("Package is null"); - - _packageInfo = packageInfo; - SetMetadata(); - if (serialize) - Serialize(); - } - - public void SetPackage(string packageManifestPath, bool serialize) - { - if (!PackageUtility.GetPackageByManifestPath(packageManifestPath, out var package)) - throw new ArgumentException("Path does not correspond to a valid package"); - - SetPackage(package, serialize); - } - - private void SetMetadata() - { - LocalPackageGuid = AssetDatabase.AssetPathToGUID(AssetDatabase.GetAssetPath(_packageInfo.GetManifestAsset())); - LocalPackagePath = _packageInfo.assetPath; - LocalProjectPath = _packageInfo.name; - } - - public List GetDependencies() - { - return _dependencies; - } - - public void SetDependencies(IEnumerable dependencies, bool serialize) - { - _dependencies.Clear(); - foreach (var dependency in dependencies) - { - if (!PackageUtility.GetPackageByPackageName(dependency, out var package)) - continue; - _dependencies.Add(package); - } - - if (serialize) - Serialize(); - } - - public List GetAvailableDependencies() - { - var availableDependencies = new List(); - if (_packageInfo == null) - return availableDependencies; - - var packageDependencies = _packageInfo.dependencies.Select(x => x.name); - foreach (var dependency in packageDependencies) - { - if (!PackageUtility.GetPackageByPackageName(dependency, out var package)) - continue; - - if (package.source != PackageManager.PackageSource.Local - && package.source != PackageManager.PackageSource.Embedded) - continue; - - availableDependencies.Add(package); - } - - return availableDependencies; - } - - public override IEnumerable GetAllPaths() - { - var paths = new List(); - - if (_packageInfo == null) - return paths; - - paths.Add(_packageInfo.assetPath); - paths.AddRange(_dependencies.Select(x => x.assetPath)); - - return paths; - } - - public override bool IsPathValid(string path, out string reason) - { - reason = string.Empty; - - if (!PackageUtility.GetPackageByManifestPath(path, out var package)) - { - reason = "Selected path must point to a package manifest for a package that is imported into the current project"; - return false; - } - - var packageSourceValid = package.source == PackageSource.Embedded || package.source == PackageSource.Local; - if (!packageSourceValid) - { - reason = "Selected package must be a local or an embedded package"; - return false; - } - - return true; - } - - public override IValidator CreateValidator() - { - var validationPaths = GetAllPaths(); - - var validationSettings = new CurrentProjectValidationSettings() - { - Category = Package?.Category, - ValidationPaths = validationPaths.ToList(), - ValidationType = ValidationType.UnityPackage - }; - - var validator = new CurrentProjectValidator(validationSettings); - return validator; - } - - public override IPackageExporter CreateExporter(string outputPath) - { - var exportPaths = GetAllPaths(); - - var exportSettings = new DefaultExporterSettings() - { - ExportPaths = exportPaths.ToArray(), - OutputFilename = outputPath, - PreviewGenerator = CreatePreviewGenerator(exportPaths.ToList()) - }; - - return new DefaultPackageExporter(exportSettings); - } - - protected override IPackageUploader CreatePackageUploader(string exportedPackagePath) - { - var uploaderSettings = new UnityPackageUploadSettings() - { - UnityPackagePath = exportedPackagePath, - VersionId = Package.VersionId, - RootGuid = LocalPackageGuid, - RootPath = LocalPackagePath, - ProjectPath = LocalProjectPath - }; - - var uploader = new UnityPackageUploader(uploaderSettings); - return uploader; - } - - protected override void Serialize() - { - if (_packageInfo == null) - return; - - _stateData.SetPackageName(_packageInfo.name); - _stateData.SetPackageDependencies(_dependencies.Select(x => x.name).OrderBy(x => x)); - OnChanged?.Invoke(); - } - - protected override void Deserialize() - { - var packageName = _stateData.GetPackageName(); - if (PackageUtility.GetPackageByPackageName(packageName, out var package)) - _packageInfo = package; - - _dependencies = new List(); - var dependencies = _stateData.GetPackageDependencies(); - foreach (var dependency in dependencies) - { - if (PackageUtility.GetPackageByPackageName(dependency, out var packageDependency)) - _dependencies.Add(packageDependency); - } - - DeserializeFromUploadedData(); - } - - private void DeserializeFromUploadedData() - { - DeserializeFromUploadedDataByPackageName(); - DeserializeFromUploadedDataByPackageGuid(); - } - - private void DeserializeFromUploadedDataByPackageName() - { - if (_packageInfo != null) - return; - - var lastUploadedPackageName = Package.ProjectPath; - if (!PackageUtility.GetPackageByPackageName(lastUploadedPackageName, out var package)) - return; - - _packageInfo = package; - } - - private void DeserializeFromUploadedDataByPackageGuid() - { - if (_packageInfo != null) - return; - - var lastUploadedGuid = Package.RootGuid; - if (string.IsNullOrEmpty(lastUploadedGuid)) - return; - - var potentialPackageManifestPath = AssetDatabase.GUIDToAssetPath(lastUploadedGuid); - if (string.IsNullOrEmpty(potentialPackageManifestPath) || !IsPathValid(potentialPackageManifestPath, out var _)) - return; - - if (!PackageUtility.GetPackageByManifestPath(potentialPackageManifestPath, out var package)) - return; - - _packageInfo = package; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/HybridPackageWorkflow.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/HybridPackageWorkflow.cs.meta deleted file mode 100644 index f815b9d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/HybridPackageWorkflow.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 3061839aba3894246a20195639eeda1f -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Package.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Package.cs deleted file mode 100644 index 1a984e5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Package.cs +++ /dev/null @@ -1,91 +0,0 @@ -using System; -using UnityEngine; -using PackageModel = AssetStoreTools.Api.Models.Package; - -namespace AssetStoreTools.Uploader.Data -{ - internal class Package : IPackage - { - private PackageModel _source; - - public string PackageId => _source.PackageId; - public string VersionId => _source.VersionId; - public string Name => _source.Name; - public string Status => _source.Status; - public string Category => _source.Category; - public bool IsCompleteProject => _source.IsCompleteProject; - public string RootGuid => _source.RootGuid; - public string RootPath => _source.RootPath; - public string ProjectPath => _source.ProjectPath; - public string Modified => _source.Modified; - public string Size => _source.Size; - public string IconUrl => _source.IconUrl; - public bool IsDraft => Status.Equals("draft", StringComparison.OrdinalIgnoreCase); - public Texture2D Icon { get; private set; } - - public event Action OnUpdate; - public event Action OnIconUpdate; - - public Package(PackageModel packageSource) - { - _source = packageSource; - } - - public void UpdateIcon(Texture2D texture) - { - if (texture == null) - return; - - Icon = texture; - OnIconUpdate?.Invoke(); - } - - public string FormattedSize() - { - var defaultSize = "0.00 MB"; - if (float.TryParse(Size, out var sizeBytes)) - return $"{sizeBytes / (1024f * 1024f):0.00} MB"; - - return defaultSize; - } - - public string FormattedModified() - { - var defaultDate = "Unknown"; - if (DateTime.TryParse(Modified, out var dt)) - return dt.Date.ToString("yyyy-MM-dd"); - - return defaultDate; - } - - public void UpdateData(PackageModel source) - { - if (source == null) - throw new ArgumentException("Provided package is null"); - - _source = source; - OnUpdate?.Invoke(); - } - - public PackageModel ToModel() - { - var model = new PackageModel() - { - PackageId = _source.PackageId, - VersionId = _source.VersionId, - Name = _source.Name, - Status = _source.Status, - Category = _source.Category, - IsCompleteProject = _source.IsCompleteProject, - RootGuid = _source.RootGuid, - RootPath = _source.RootPath, - ProjectPath = _source.ProjectPath, - Modified = _source.Modified, - Size = _source.Size, - IconUrl = _source.IconUrl - }; - - return model; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Package.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Package.cs.meta deleted file mode 100644 index 588a5fd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Package.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: fc2198164bbd6394b87c51a74fe2915e -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageContent.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageContent.cs deleted file mode 100644 index bac6c08..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageContent.cs +++ /dev/null @@ -1,68 +0,0 @@ -using AssetStoreTools.Uploader.Data.Serialization; -using AssetStoreTools.Uploader.Services; -using System; -using System.Collections.Generic; -using System.Linq; - -namespace AssetStoreTools.Uploader.Data -{ - internal class PackageContent : IPackageContent - { - private IWorkflow _activeWorkflow; - private List _workflows; - private WorkflowStateData _workflowStateData; - - private ICachingService _cachingService; - - public event Action OnActiveWorkflowChanged; - - public PackageContent(List workflows, WorkflowStateData workflowStateData, ICachingService cachingService) - { - _workflows = workflows; - _workflowStateData = workflowStateData; - _cachingService = cachingService; - - foreach (var workflow in _workflows) - { - workflow.OnChanged += Serialize; - } - - Deserialize(); - } - - public IWorkflow GetActiveWorkflow() - { - return _activeWorkflow; - } - - public void SetActiveWorkflow(IWorkflow workflow) - { - _activeWorkflow = workflow; - - OnActiveWorkflowChanged?.Invoke(_activeWorkflow); - - Serialize(); - } - - public List GetAvailableWorkflows() - { - return _workflows; - } - - private void Serialize() - { - _workflowStateData.SetActiveWorkflow(_activeWorkflow.Name); - _cachingService.CacheWorkflowStateData(_workflowStateData); - } - - private void Deserialize() - { - var serializedWorkflow = _workflowStateData.GetActiveWorkflow(); - var workflow = _workflows.FirstOrDefault(x => x.Name == serializedWorkflow); - if (workflow != null) - _activeWorkflow = workflow; - else - _activeWorkflow = _workflows[0]; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageContent.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageContent.cs.meta deleted file mode 100644 index afce82d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageContent.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: f36086f9380a49949ab45463abc6fee8 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageGroup.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageGroup.cs deleted file mode 100644 index 78e9aa1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageGroup.cs +++ /dev/null @@ -1,64 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; - -namespace AssetStoreTools.Uploader.Data -{ - internal class PackageGroup : IPackageGroup - { - private class FilteredPackage - { - public IPackage Package; - public bool IsInFilter; - } - - public string Name { get; private set; } - public List Packages { get; private set; } - - private List _filteredPackages; - - public event Action> OnPackagesSorted; - public event Action> OnPackagesFiltered; - - public PackageGroup(string name, List packages) - { - Name = name; - Packages = packages; - - _filteredPackages = new List(); - foreach (var package in Packages) - _filteredPackages.Add(new FilteredPackage() { Package = package, IsInFilter = true }); - } - - public void Sort(PackageSorting sortingType) - { - switch (sortingType) - { - case PackageSorting.Name: - _filteredPackages = _filteredPackages.OrderBy(x => x.Package.Name).ToList(); - break; - case PackageSorting.Date: - _filteredPackages = _filteredPackages.OrderByDescending(x => x.Package.Modified).ToList(); - break; - case PackageSorting.Category: - _filteredPackages = _filteredPackages.OrderBy(x => x.Package.Category).ThenBy(x => x.Package.Name).ToList(); - break; - default: - throw new NotImplementedException("Undefined sorting type"); - } - - OnPackagesSorted?.Invoke(_filteredPackages.Where(x => x.IsInFilter).Select(x => x.Package).ToList()); - } - - public void Filter(string filter) - { - foreach (var package in _filteredPackages) - { - bool inFilter = package.Package.Name.ToLower().Contains(filter.ToLower()); - package.IsInFilter = inFilter; - } - - OnPackagesFiltered?.Invoke(_filteredPackages.Where(x => x.IsInFilter).Select(x => x.Package).ToList()); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageGroup.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageGroup.cs.meta deleted file mode 100644 index 2806af6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageGroup.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: c9cc17f6b95bb2c42913a1451b9af29e -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageSorting.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageSorting.cs deleted file mode 100644 index 7ef00e4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageSorting.cs +++ /dev/null @@ -1,9 +0,0 @@ -namespace AssetStoreTools.Uploader.Data -{ - internal enum PackageSorting - { - Name, - Category, - Date - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageSorting.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageSorting.cs.meta deleted file mode 100644 index a9261e6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/PackageSorting.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: b1d61d0de90e022469b5ed312d4b7beb -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization.meta deleted file mode 100644 index 2ba3d4c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 0b05e199f21f636439844a8cc7e2c225 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetPath.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetPath.cs deleted file mode 100644 index 4970e73..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetPath.cs +++ /dev/null @@ -1,59 +0,0 @@ -using AssetStoreTools.Utility; -using Newtonsoft.Json; -using System.IO; -using UnityEditor; - -namespace AssetStoreTools.Uploader.Data.Serialization -{ - internal class AssetPath - { - [JsonProperty("path")] - private string _path = string.Empty; - [JsonProperty("guid")] - private string _guid = string.Empty; - - [JsonIgnore] - public string Path { get => _path; set { SetAssetPath(value); } } - [JsonIgnore] - public string Guid { get => _guid; set { _guid = value; } } - - public AssetPath() { } - - public AssetPath(string path) - { - SetAssetPath(path); - } - - private void SetAssetPath(string path) - { - _path = path.Replace("\\", "/"); - if (TryGetGuid(_path, out var guid)) - _guid = guid; - } - - private bool TryGetGuid(string path, out string guid) - { - guid = string.Empty; - - var relativePath = FileUtility.AbsolutePathToRelativePath(path, ASToolsPreferences.Instance.EnableSymlinkSupport); - - if (!relativePath.StartsWith("Assets/") && !relativePath.StartsWith("Packages/")) - return false; - - guid = AssetDatabase.AssetPathToGUID(relativePath); - return !string.IsNullOrEmpty(guid); - } - - public override string ToString() - { - var pathFromGuid = AssetDatabase.GUIDToAssetPath(_guid); - if (!string.IsNullOrEmpty(pathFromGuid) && (File.Exists(pathFromGuid) || Directory.Exists(pathFromGuid))) - return pathFromGuid; - - if (File.Exists(_path) || Directory.Exists(_path)) - return _path; - - return string.Empty; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetPath.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetPath.cs.meta deleted file mode 100644 index d6ced93..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetPath.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 920ff8e4ffe77ec44bede985593cc187 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetsWorkflowStateData.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetsWorkflowStateData.cs deleted file mode 100644 index 8d955c3..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetsWorkflowStateData.cs +++ /dev/null @@ -1,77 +0,0 @@ -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace AssetStoreTools.Uploader.Data.Serialization -{ - internal class AssetsWorkflowState - { - [JsonProperty("main_path")] - private AssetPath _mainPath; - [JsonProperty("special_folders")] - private List _specialFolders; - [JsonProperty("include_dependencies")] - private bool _includeDependencies; - [JsonProperty("dependencies")] - private List _dependencies; - - public AssetsWorkflowState() - { - _mainPath = new AssetPath(); - _includeDependencies = false; - _dependencies = new List(); - _specialFolders = new List(); - } - - public string GetMainPath() - { - return _mainPath?.ToString(); - } - - public void SetMainPath(string path) - { - _mainPath = new AssetPath(path); - } - - public bool GetIncludeDependencies() - { - return _includeDependencies; - } - - public void SetIncludeDependencies(bool value) - { - _includeDependencies = value; - } - - public List GetDependencies() - { - return _dependencies; - } - - public void SetDependencies(IEnumerable dependencies) - { - _dependencies = new List(); - foreach (var dependency in dependencies) - _dependencies.Add(dependency); - } - - public List GetSpecialFolders() - { - var specialFolders = new List(); - foreach (var folder in _specialFolders) - { - var path = folder.ToString(); - if (!string.IsNullOrEmpty(path)) - specialFolders.Add(path); - } - - return specialFolders; - } - - public void SetSpecialFolders(List specialFolders) - { - _specialFolders = new List(); - foreach (var path in specialFolders) - _specialFolders.Add(new AssetPath(path)); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetsWorkflowStateData.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetsWorkflowStateData.cs.meta deleted file mode 100644 index 58c77a5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/AssetsWorkflowStateData.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 505f0a5aa753b4445a467539e150190a -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/HybridPackageWorkflowState.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/HybridPackageWorkflowState.cs deleted file mode 100644 index 58e428e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/HybridPackageWorkflowState.cs +++ /dev/null @@ -1,41 +0,0 @@ -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace AssetStoreTools.Uploader.Data.Serialization -{ - internal class HybridPackageWorkflowState - { - [JsonProperty("package_name")] - private string _packageName; - [JsonProperty("dependencies")] - private List _dependencies; - - public HybridPackageWorkflowState() - { - _packageName = string.Empty; - _dependencies = new List(); - } - - public string GetPackageName() - { - return _packageName; - } - - public void SetPackageName(string packageName) - { - _packageName = packageName; - } - - public List GetPackageDependencies() - { - return _dependencies; - } - - public void SetPackageDependencies(IEnumerable dependencies) - { - _dependencies.Clear(); - foreach (var dependency in dependencies) - _dependencies.Add(dependency); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/HybridPackageWorkflowState.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/HybridPackageWorkflowState.cs.meta deleted file mode 100644 index 6638cf8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/HybridPackageWorkflowState.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 2848375fcb0a4174495573190bfc3900 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/UnityPackageWorkflowStateData.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/UnityPackageWorkflowStateData.cs deleted file mode 100644 index ca14b88..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/UnityPackageWorkflowStateData.cs +++ /dev/null @@ -1,25 +0,0 @@ -using Newtonsoft.Json; - -namespace AssetStoreTools.Uploader.Data.Serialization -{ - internal class UnityPackageWorkflowState - { - [JsonProperty("package_path")] - private AssetPath _packagePath; - - public UnityPackageWorkflowState() - { - _packagePath = new AssetPath(); - } - - public string GetPackagePath() - { - return _packagePath?.ToString(); - } - - public void SetPackagePath(string path) - { - _packagePath = new AssetPath(path); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/UnityPackageWorkflowStateData.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/UnityPackageWorkflowStateData.cs.meta deleted file mode 100644 index a9d8b2c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/UnityPackageWorkflowStateData.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 101a66adc88639b43b07cc28214474cf -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/WorkflowStateData.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/WorkflowStateData.cs deleted file mode 100644 index 25e72c6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/WorkflowStateData.cs +++ /dev/null @@ -1,68 +0,0 @@ -using Newtonsoft.Json; -using Newtonsoft.Json.Serialization; - -namespace AssetStoreTools.Uploader.Data.Serialization -{ - internal class WorkflowStateData - { - [JsonProperty("package_id")] - private string _packageId; - [JsonProperty("active_workflow")] - private string _activeWorkflow; - [JsonProperty("assets_workflow")] - private AssetsWorkflowState _assetsWorkflow; - [JsonProperty("unitypackage_workflow")] - private UnityPackageWorkflowState _unityPackageWorkflow; - [JsonProperty("hybrid_workflow")] - private HybridPackageWorkflowState _hybridPackageWorkflow; - - public WorkflowStateData() - { - _activeWorkflow = string.Empty; - - _assetsWorkflow = new AssetsWorkflowState(); - _unityPackageWorkflow = new UnityPackageWorkflowState(); - _hybridPackageWorkflow = new HybridPackageWorkflowState(); - } - - public WorkflowStateData(string packageId) : this() - { - SetPackageId(packageId); - } - - public string GetPackageId() - { - return _packageId; - } - - public void SetPackageId(string packageId) - { - _packageId = packageId; - } - - public string GetActiveWorkflow() - { - return _activeWorkflow; - } - - public void SetActiveWorkflow(string activeWorkflow) - { - _activeWorkflow = activeWorkflow; - } - - public AssetsWorkflowState GetAssetsWorkflowState() - { - return _assetsWorkflow; - } - - public UnityPackageWorkflowState GetUnityPackageWorkflowState() - { - return _unityPackageWorkflow; - } - - public HybridPackageWorkflowState GetHybridPackageWorkflowState() - { - return _hybridPackageWorkflow; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/WorkflowStateData.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/WorkflowStateData.cs.meta deleted file mode 100644 index 4a58328..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/Serialization/WorkflowStateData.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: eecebbc83661a4f41a14e293c9fc3331 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/UnityPackageWorkflow.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/UnityPackageWorkflow.cs deleted file mode 100644 index 6668fd6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/UnityPackageWorkflow.cs +++ /dev/null @@ -1,135 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Exporter; -using AssetStoreTools.Uploader.Data.Serialization; -using AssetStoreTools.Validator; -using AssetStoreTools.Validator.Data; -using System; -using System.Collections.Generic; -using System.IO; -using System.Threading.Tasks; - -namespace AssetStoreTools.Uploader.Data -{ - internal class UnityPackageWorkflow : WorkflowBase - { - public override string Name => "UnityPackageWorkflow"; - public override string DisplayName => "Pre-exported .unitypackage"; - public override string PackageExtension => ".unitypackage"; - public override bool IsPathSet => !string.IsNullOrEmpty(_packagePath); - - private UnityPackageWorkflowState _workflowState; - private string _packagePath; - - public override event Action OnChanged; - - public UnityPackageWorkflow(IPackage package, UnityPackageWorkflowState workflowState, IWorkflowServices services) - : base(package, services) - { - _workflowState = workflowState; - Deserialize(); - } - - public void SetPackagePath(string path, bool serialize) - { - _packagePath = path; - SetMetadata(); - if (serialize) - Serialize(); - } - - private void SetMetadata() - { - LocalPackageGuid = string.Empty; - LocalPackagePath = string.Empty; - LocalProjectPath = _packagePath; - } - - public string GetPackagePath() - { - return _packagePath; - } - - public override IEnumerable GetAllPaths() - { - return new List() { _packagePath }; - } - - public override bool IsPathValid(string path, out string error) - { - error = null; - - var pathIsUnityPackage = path.EndsWith(PackageExtension); - var pathExists = File.Exists(path); - - if (!pathIsUnityPackage || !pathExists) - { - error = "Path must point to a .unitypackage file"; - return false; - } - - return true; - } - - public override IValidator CreateValidator() - { - var validationSettings = new ExternalProjectValidationSettings() - { - Category = Package.Category, - PackagePath = GetPackagePath() - }; - - var validator = new ExternalProjectValidator(validationSettings); - return validator; - } - - public override IPackageExporter CreateExporter(string _) - { - // This workflow already takes exported packages as input - throw new InvalidOperationException($"{nameof(UnityPackageWorkflow)} already takes exported packages as input"); - } - - public override Task ExportPackage(string _) - { - return Task.FromResult(new PackageExporterResult() { Success = true, ExportedPath = GetPackagePath() }); - } - - protected override IPackageUploader CreatePackageUploader(string exportedPackagePath) - { - var uploaderSettings = new UnityPackageUploadSettings() - { - VersionId = Package.VersionId, - UnityPackagePath = exportedPackagePath, - RootGuid = LocalPackageGuid, - RootPath = LocalPackagePath, - ProjectPath = LocalProjectPath - }; - - var uploader = new UnityPackageUploader(uploaderSettings); - return uploader; - } - - protected override void Serialize() - { - _workflowState.SetPackagePath(_packagePath); - OnChanged?.Invoke(); - } - - protected override void Deserialize() - { - _packagePath = _workflowState.GetPackagePath(); - DeserializeFromUploadedData(); - } - - private void DeserializeFromUploadedData() - { - if (!string.IsNullOrEmpty(_packagePath)) - return; - - var potentialPackagePath = Package.ProjectPath; - if (string.IsNullOrEmpty(potentialPackagePath) || !IsPathValid(potentialPackagePath, out var _)) - return; - - _packagePath = potentialPackagePath; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/UnityPackageWorkflow.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/UnityPackageWorkflow.cs.meta deleted file mode 100644 index 031a510..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/UnityPackageWorkflow.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 47ee1db30792bf84aa1af8be7ce0dee6 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/WorkflowServices.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/WorkflowServices.cs deleted file mode 100644 index 525374d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/WorkflowServices.cs +++ /dev/null @@ -1,53 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Api.Responses; -using AssetStoreTools.Uploader.Services.Analytics; -using AssetStoreTools.Uploader.Services.Analytics.Data; -using AssetStoreTools.Uploader.Services.Api; -using System; -using System.Threading.Tasks; -using UnityEngine.Analytics; - -namespace AssetStoreTools.Uploader.Data -{ - internal class WorkflowServices : IWorkflowServices - { - private IPackageDownloadingService _downloadingService; - private IPackageUploadingService _uploadingService; - private IAnalyticsService _analyticsService; - - public WorkflowServices( - IPackageDownloadingService downloadingService, - IPackageUploadingService uploadingService, - IAnalyticsService analyticsService) - { - _downloadingService = downloadingService; - _uploadingService = uploadingService; - _analyticsService = analyticsService; - } - - public Task GetPackageUploadedVersions(IPackage package, int timeoutMs) - { - return _downloadingService.GetPackageUploadedVersions(package, timeoutMs); - } - - public Task UploadPackage(IPackageUploader uploader, IProgress progress) - { - return _uploadingService.UploadPackage(uploader, progress); - } - - public void StopUploading(IPackageUploader uploader) - { - _uploadingService.StopUploading(uploader); - } - - public Task UpdatePackageData(IPackage package) - { - return _downloadingService.UpdatePackageData(package); - } - - public AnalyticsResult SendAnalytic(IAssetStoreAnalytic data) - { - return _analyticsService.Send(data); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/WorkflowServices.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/WorkflowServices.cs.meta deleted file mode 100644 index 2431462..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Data/WorkflowServices.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a78b96ae30966e94ba9ffdddf19c1692 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services.meta deleted file mode 100644 index 6d1acef..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: d9787842821f3d041904186d0e0cc61d -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics.meta deleted file mode 100644 index 30b3cbf..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 17f95678acdb51548908d81be7146b5b -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/AnalyticsService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/AnalyticsService.cs deleted file mode 100644 index a2f6e1e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/AnalyticsService.cs +++ /dev/null @@ -1,45 +0,0 @@ -using AssetStoreTools.Uploader.Services.Analytics.Data; -using UnityEditor; -using UnityEngine.Analytics; -#if !UNITY_2023_2_OR_NEWER -using AnalyticsConstants = AssetStoreTools.Constants.Uploader.Analytics; -#endif - -namespace AssetStoreTools.Uploader.Services.Analytics -{ - internal class AnalyticsService : IAnalyticsService - { - public AnalyticsResult Send(IAssetStoreAnalytic analytic) - { - if (!EditorAnalytics.enabled) - return AnalyticsResult.AnalyticsDisabled; - - if (!Register(analytic)) - return AnalyticsResult.AnalyticsDisabled; - -#if UNITY_2023_2_OR_NEWER - return EditorAnalytics.SendAnalytic(analytic); -#else - return EditorAnalytics.SendEventWithLimit(analytic.EventName, - analytic.Data, - analytic.EventVersion); -#endif - } - - private bool Register(IAssetStoreAnalytic analytic) - { -#if UNITY_2023_2_OR_NEWER - return true; -#else - var result = EditorAnalytics.RegisterEventWithLimit( - eventName: analytic.EventName, - maxEventPerHour: AnalyticsConstants.MaxEventsPerHour, - maxItems: AnalyticsConstants.MaxNumberOfElements, - vendorKey: AnalyticsConstants.VendorKey, - ver: analytic.EventVersion); - - return result == AnalyticsResult.Ok; -#endif - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/AnalyticsService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/AnalyticsService.cs.meta deleted file mode 100644 index a4acea1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/AnalyticsService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 408b5b0136da9ca4f9598b8688f6210e -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data.meta deleted file mode 100644 index 59ec0e4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: df1fca726619f2f4fae3bd93b0ef5a8b -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/AuthenticationAnalytic.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/AuthenticationAnalytic.cs deleted file mode 100644 index 74edf0e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/AuthenticationAnalytic.cs +++ /dev/null @@ -1,46 +0,0 @@ -using AssetStoreTools.Api; -using System; -#if UNITY_2023_2_OR_NEWER -using UnityEngine.Analytics; -#endif -using AnalyticsConstants = AssetStoreTools.Constants.Uploader.Analytics; - -namespace AssetStoreTools.Uploader.Services.Analytics.Data -{ -#if UNITY_2023_2_OR_NEWER - [AnalyticInfo - (eventName: AnalyticsConstants.AuthenticationAnalytics.EventName, - vendorKey: AnalyticsConstants.VendorKey, - version: AnalyticsConstants.AuthenticationAnalytics.EventVersion, - maxEventsPerHour: AnalyticsConstants.MaxEventsPerHour, - maxNumberOfElements: AnalyticsConstants.MaxNumberOfElements)] -#endif - internal class AuthenticationAnalytic : BaseAnalytic - { - [Serializable] - public class AuthenticationAnalyticData : BaseAnalyticData - { - public string AuthenticationType; - public string PublisherId; - } - - public override string EventName => AnalyticsConstants.AuthenticationAnalytics.EventName; - public override int EventVersion => AnalyticsConstants.AuthenticationAnalytics.EventVersion; - - private AuthenticationAnalyticData _data; - - public AuthenticationAnalytic(IAuthenticationType authenticationType, string publisherId) - { - _data = new AuthenticationAnalyticData - { - AuthenticationType = authenticationType.GetType().Name, - PublisherId = publisherId - }; - } - - protected override BaseAnalyticData GetData() - { - return _data; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/AuthenticationAnalytic.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/AuthenticationAnalytic.cs.meta deleted file mode 100644 index 83763d7..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/AuthenticationAnalytic.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 4b9389e3ee578484493d36775c75baa1 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/BaseAnalytic.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/BaseAnalytic.cs deleted file mode 100644 index 60c3396..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/BaseAnalytic.cs +++ /dev/null @@ -1,35 +0,0 @@ -using System; -#if UNITY_2023_2_OR_NEWER -using UnityEngine.Analytics; -#endif - -namespace AssetStoreTools.Uploader.Services.Analytics.Data -{ - internal abstract class BaseAnalytic : IAssetStoreAnalytic - { - [Serializable] - public class BaseAnalyticData : IAssetStoreAnalyticData - { - public string ToolVersion = Constants.Api.ApiVersion; - } - - public abstract string EventName { get; } - public abstract int EventVersion { get; } - - public IAssetStoreAnalyticData Data => GetData(); - protected abstract BaseAnalyticData GetData(); - -#if UNITY_2023_2_OR_NEWER - public bool TryGatherData(out IAnalytic.IData data, [System.Diagnostics.CodeAnalysis.NotNullWhen(false)] out Exception error) - { - error = null; - data = Data; - - if (data == null) - error = new Exception("Analytic data is null"); - - return error == null; - } -#endif - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/BaseAnalytic.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/BaseAnalytic.cs.meta deleted file mode 100644 index b16de7f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/BaseAnalytic.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 51ec1e4b6505b694ab01f7c523744fbc -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalytic.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalytic.cs deleted file mode 100644 index 5207ca0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalytic.cs +++ /dev/null @@ -1,16 +0,0 @@ -#if UNITY_2023_2_OR_NEWER -using UnityEngine.Analytics; -#endif - -namespace AssetStoreTools.Uploader.Services.Analytics.Data -{ - internal interface IAssetStoreAnalytic -#if UNITY_2023_2_OR_NEWER - : IAnalytic -#endif - { - string EventName { get; } - int EventVersion { get; } - IAssetStoreAnalyticData Data { get; } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalytic.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalytic.cs.meta deleted file mode 100644 index 29bfff8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalytic.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 6e9b53aa176bbed48bafa538c26df304 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalyticData.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalyticData.cs deleted file mode 100644 index e08b8f8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalyticData.cs +++ /dev/null @@ -1,8 +0,0 @@ -namespace AssetStoreTools.Uploader.Services.Analytics.Data -{ - interface IAssetStoreAnalyticData -#if UNITY_2023_2_OR_NEWER - : UnityEngine.Analytics.IAnalytic.IData -#endif - { } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalyticData.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalyticData.cs.meta deleted file mode 100644 index 0c3280d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/IAssetStoreAnalyticData.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: b639e25d9b9abd34d8eb67b0e17dde86 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/PackageUploadAnalytic.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/PackageUploadAnalytic.cs deleted file mode 100644 index d8a3479..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/PackageUploadAnalytic.cs +++ /dev/null @@ -1,72 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Validator.Data; -using System; -#if UNITY_2023_2_OR_NEWER -using UnityEngine.Analytics; -#endif -using AnalyticsConstants = AssetStoreTools.Constants.Uploader.Analytics; - -namespace AssetStoreTools.Uploader.Services.Analytics.Data -{ -#if UNITY_2023_2_OR_NEWER - [AnalyticInfo - (eventName: AnalyticsConstants.PackageUploadAnalytics.EventName, - vendorKey: AnalyticsConstants.VendorKey, - version: AnalyticsConstants.PackageUploadAnalytics.EventVersion, - maxEventsPerHour: AnalyticsConstants.MaxEventsPerHour, - maxNumberOfElements: AnalyticsConstants.MaxNumberOfElements)] -#endif - internal class PackageUploadAnalytic : BaseAnalytic - { - [Serializable] - public class PackageUploadAnalyticData : BaseAnalyticData - { - public string PackageId; - public string Category; - public bool UsedValidator; - public string ValidatorResults; - public string UploadFinishedReason; - public double TimeTaken; - public long PackageSize; - public string Workflow; - public string EndpointUrl; - } - - public override string EventName => AnalyticsConstants.PackageUploadAnalytics.EventName; - public override int EventVersion => AnalyticsConstants.PackageUploadAnalytics.EventVersion; - - private PackageUploadAnalyticData _data; - - public PackageUploadAnalytic( - string packageId, - string category, - bool usedValidator, - ValidationSettings validationSettings, - ValidationResult validationResult, - UploadStatus uploadFinishedReason, - double timeTaken, - long packageSize, - string workflow - ) - { - _data = new PackageUploadAnalyticData() - { - PackageId = packageId, - Category = category, - UsedValidator = usedValidator, - ValidatorResults = usedValidator ? - ValidationResultsSerializer.ConstructValidationResultsJson(validationSettings, validationResult) : null, - UploadFinishedReason = uploadFinishedReason.ToString(), - TimeTaken = timeTaken, - PackageSize = packageSize, - Workflow = workflow, - EndpointUrl = Constants.Api.AssetStoreBaseUrl - }; - } - - protected override BaseAnalyticData GetData() - { - return _data; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/PackageUploadAnalytic.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/PackageUploadAnalytic.cs.meta deleted file mode 100644 index bb91393..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/PackageUploadAnalytic.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 6cc34de12dce9964b9c900d5bb159966 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/ValidationResultsSerializer.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/ValidationResultsSerializer.cs deleted file mode 100644 index 1bb7b56..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/ValidationResultsSerializer.cs +++ /dev/null @@ -1,91 +0,0 @@ -using AssetStoreTools.Validator.Data; -using Newtonsoft.Json; -using Newtonsoft.Json.Serialization; -using System.Collections.Generic; -using System.Reflection; - -namespace AssetStoreTools.Uploader.Services.Analytics.Data -{ - internal class ValidationResultsSerializer - { - private class ValidationResults - { - public bool HasCompilationErrors; - public string[] Paths; - public Dictionary Results; - } - - private class TestResultOutcome - { - public int IntegerValue; - public string StringValue; - - public TestResultOutcome(TestResultStatus status) - { - IntegerValue = (int)status; - StringValue = status.ToString(); - } - } - - private class ValidationResultsResolver : DefaultContractResolver - { - private static ValidationResultsResolver _instance; - public static ValidationResultsResolver Instance => _instance ?? (_instance = new ValidationResultsResolver()); - - private Dictionary _propertyConversion; - - private ValidationResultsResolver() - { - _propertyConversion = new Dictionary() - { - { nameof(ValidationResults.HasCompilationErrors), "has_compilation_errors" }, - { nameof(ValidationResults.Paths), "validation_paths" }, - { nameof(ValidationResults.Results), "validation_results" }, - { nameof(TestResultOutcome.IntegerValue), "int" }, - { nameof(TestResultOutcome.StringValue), "string" }, - }; - } - - protected override JsonProperty CreateProperty(MemberInfo member, MemberSerialization memberSerialization) - { - var property = base.CreateProperty(member, memberSerialization); - if (_propertyConversion.ContainsKey(property.PropertyName)) - property.PropertyName = _propertyConversion[property.PropertyName]; - - return property; - } - } - - public static string ConstructValidationResultsJson(ValidationSettings settings, ValidationResult result) - { - if (result == null) - return string.Empty; - - var resultObject = new ValidationResults(); - resultObject.HasCompilationErrors = result.HadCompilationErrors; - - switch (settings) - { - case CurrentProjectValidationSettings currentProjectValidationSettings: - resultObject.Paths = currentProjectValidationSettings.ValidationPaths.ToArray(); - break; - case ExternalProjectValidationSettings externalProjectValidationSettings: - resultObject.Paths = new string[] { externalProjectValidationSettings.PackagePath }; - break; - } - - resultObject.Results = new Dictionary(); - foreach (var test in result.Tests) - { - resultObject.Results.Add(test.Id.ToString(), new TestResultOutcome(test.Result.Status)); - } - - var serializerSettings = new JsonSerializerSettings() - { - ContractResolver = ValidationResultsResolver.Instance - }; - - return JsonConvert.SerializeObject(resultObject, serializerSettings); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/ValidationResultsSerializer.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/ValidationResultsSerializer.cs.meta deleted file mode 100644 index f5415b8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/Data/ValidationResultsSerializer.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: fa15fc27c7f3d044884885b3dad73efc -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/IAnalyticsService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/IAnalyticsService.cs deleted file mode 100644 index a64dce1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/IAnalyticsService.cs +++ /dev/null @@ -1,10 +0,0 @@ -using AssetStoreTools.Uploader.Services.Analytics.Data; -using UnityEngine.Analytics; - -namespace AssetStoreTools.Uploader.Services.Analytics -{ - internal interface IAnalyticsService : IUploaderService - { - AnalyticsResult Send(IAssetStoreAnalytic analytic); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/IAnalyticsService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/IAnalyticsService.cs.meta deleted file mode 100644 index 2db5042..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Analytics/IAnalyticsService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: faa1f39fc83b86b438f6e0f34f01167b -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api.meta deleted file mode 100644 index 7075aa4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 4d983b64bd0866a428f937434252f537 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/AuthenticationService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/AuthenticationService.cs deleted file mode 100644 index e002818..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/AuthenticationService.cs +++ /dev/null @@ -1,100 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Api.Models; -using AssetStoreTools.Api.Responses; -using AssetStoreTools.Uploader.Services.Analytics; -using AssetStoreTools.Uploader.Services.Analytics.Data; -using AssetStoreTools.Utility; -using System; -using System.Threading.Tasks; -using UnityEditor; - -namespace AssetStoreTools.Uploader.Services.Api -{ - internal class AuthenticationService : IAuthenticationService - { - private IAssetStoreApi _api; - private ICachingService _cachingService; - private IAnalyticsService _analyticsService; - - public User User { get; private set; } - - public AuthenticationService(IAssetStoreApi api, ICachingService cachingService, IAnalyticsService analyticsService) - { - _api = api; - _cachingService = cachingService; - _analyticsService = analyticsService; - } - - public async Task AuthenticateWithCredentials(string email, string password) - { - var authenticationType = new CredentialsAuthentication(email, password); - return await Authenticate(authenticationType); - } - - public async Task AuthenticateWithSessionToken() - { - if (!_cachingService.GetCachedSessionToken(out var cachedSessionToken)) - { - return new AuthenticationResponse() { Success = false, Exception = new Exception("No cached session token found") }; - } - - var authenticationType = new SessionAuthentication(cachedSessionToken); - return await Authenticate(authenticationType); - } - - public async Task AuthenticateWithCloudToken() - { - var authenticationType = new CloudTokenAuthentication(CloudProjectSettings.accessToken); - return await Authenticate(authenticationType); - } - - private async Task Authenticate(IAuthenticationType authenticationType) - { - var response = await _api.Authenticate(authenticationType); - HandleLoginResponse(authenticationType, response); - return response; - } - - private void HandleLoginResponse(IAuthenticationType authenticationType, AuthenticationResponse response) - { - if (!response.Success) - { - Deauthenticate(); - return; - } - - User = response.User; - _cachingService.CacheSessionToken(User.SessionId); - SendAnalytics(authenticationType, User); - } - - public bool CloudAuthenticationAvailable(out string username, out string cloudToken) - { - username = CloudProjectSettings.userName; - cloudToken = CloudProjectSettings.accessToken; - return !username.Equals("anonymous"); - } - - public void Deauthenticate() - { - _api.Deauthenticate(); - - User = null; - _cachingService.ClearCachedSessionToken(); - } - - private void SendAnalytics(IAuthenticationType authenticationType, User user) - { - try - { - // Do not send session authentication events - if (authenticationType is SessionAuthentication) - return; - - var analytic = new AuthenticationAnalytic(authenticationType, user.PublisherId); - var result = _analyticsService.Send(analytic); - } - catch (Exception e) { ASDebug.LogError($"Could not send analytics: {e}"); } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/AuthenticationService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/AuthenticationService.cs.meta deleted file mode 100644 index b36dd7d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/AuthenticationService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: c1c3d6578d298d049a8dcf858fd3686e -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IAuthenticationService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IAuthenticationService.cs deleted file mode 100644 index 96c9ee3..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IAuthenticationService.cs +++ /dev/null @@ -1,16 +0,0 @@ -using AssetStoreTools.Api.Models; -using AssetStoreTools.Api.Responses; -using System.Threading.Tasks; - -namespace AssetStoreTools.Uploader.Services.Api -{ - internal interface IAuthenticationService : IUploaderService - { - User User { get; } - Task AuthenticateWithCredentials(string email, string password); - Task AuthenticateWithSessionToken(); - Task AuthenticateWithCloudToken(); - bool CloudAuthenticationAvailable(out string username, out string cloudToken); - void Deauthenticate(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IAuthenticationService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IAuthenticationService.cs.meta deleted file mode 100644 index 25b27c4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IAuthenticationService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: ff0518dc0d95d3540857d138215bb900 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageDownloadingService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageDownloadingService.cs deleted file mode 100644 index 4cef2c0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageDownloadingService.cs +++ /dev/null @@ -1,16 +0,0 @@ -using AssetStoreTools.Api.Responses; -using AssetStoreTools.Uploader.Data; -using System.Threading.Tasks; - -namespace AssetStoreTools.Uploader.Services.Api -{ - internal interface IPackageDownloadingService : IUploaderService - { - Task GetPackageData(); - Task UpdatePackageData(IPackage package); - void ClearPackageData(); - Task GetPackageThumbnail(IPackage package); - Task GetPackageUploadedVersions(IPackage package, int timeoutMs); - void StopDownloading(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageDownloadingService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageDownloadingService.cs.meta deleted file mode 100644 index 35eaf1e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageDownloadingService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 96acd12a628311d429cc285f418f8b90 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageUploadingService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageUploadingService.cs deleted file mode 100644 index f1ff1d4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageUploadingService.cs +++ /dev/null @@ -1,16 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Api.Responses; -using System; -using System.Threading.Tasks; - -namespace AssetStoreTools.Uploader.Services.Api -{ - internal interface IPackageUploadingService : IUploaderService - { - bool IsUploading { get; } - - Task UploadPackage(IPackageUploader uploader, IProgress progress); - void StopUploading(IPackageUploader package); - void StopAllUploadinng(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageUploadingService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageUploadingService.cs.meta deleted file mode 100644 index 153b53a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/IPackageUploadingService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 9a3d78f3bc68d3d44b4300bc8ffe69c2 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageDownloadingService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageDownloadingService.cs deleted file mode 100644 index 5ab052f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageDownloadingService.cs +++ /dev/null @@ -1,109 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Api.Responses; -using AssetStoreTools.Uploader.Data; -using System.Threading; -using System.Threading.Tasks; - -namespace AssetStoreTools.Uploader.Services.Api -{ - internal class PackageDownloadingService : IPackageDownloadingService - { - public const int MaxConcurrentTumbnailDownloads = 10; - - private IAssetStoreApi _api; - private ICachingService _cachingService; - - private int _currentDownloads; - private CancellationTokenSource _cancellationTokenSource; - - public PackageDownloadingService(IAssetStoreApi api, ICachingService cachingService) - { - _api = api; - _cachingService = cachingService; - _cancellationTokenSource = new CancellationTokenSource(); - } - - public void ClearPackageData() - { - _cachingService.DeletePackageMetadata(); - } - - public async Task GetPackageData() - { - if (!_cachingService.GetCachedPackageMetadata(out var models)) - { - var cancellationToken = _cancellationTokenSource.Token; - var packagesResponse = await _api.GetPackages(cancellationToken); - - if (packagesResponse.Cancelled || !packagesResponse.Success) - return packagesResponse; - - _cachingService.CachePackageMetadata(packagesResponse.Packages); - return packagesResponse; - } - - return new PackagesDataResponse() { Success = true, Packages = models }; - } - - public async Task UpdatePackageData(IPackage package) - { - var response = await _api.RefreshPackageMetadata(package.ToModel()); - - if (response.Success) - _cachingService.UpdatePackageMetadata(response.Package); - - return response; - } - - public async Task GetPackageThumbnail(IPackage package) - { - if (_cachingService.GetCachedPackageThumbnail(package.PackageId, out var cachedTexture)) - { - return new PackageThumbnailResponse() { Success = true, Thumbnail = cachedTexture }; - } - - var cancellationToken = _cancellationTokenSource.Token; - while (_currentDownloads >= MaxConcurrentTumbnailDownloads) - await Task.Delay(100); - - if (cancellationToken.IsCancellationRequested) - return new PackageThumbnailResponse() { Success = false, Cancelled = true }; - - _currentDownloads++; - var result = await _api.GetPackageThumbnail(package.ToModel(), cancellationToken); - _currentDownloads--; - - if (result.Success && result.Thumbnail != null) - _cachingService.CachePackageThumbnail(package.PackageId, result.Thumbnail); - - return result; - } - - public async Task GetPackageUploadedVersions(IPackage package, int timeoutMs) - { - var timeoutTokenSource = new CancellationTokenSource(); - try - { - var versionsTask = _api.GetPackageUploadedVersions(package.ToModel(), timeoutTokenSource.Token); - - // Wait for versions to be retrieved, or a timeout to occur, whichever is first - if (await Task.WhenAny(versionsTask, Task.Delay(timeoutMs)) != versionsTask) - { - timeoutTokenSource.Cancel(); - } - - return await versionsTask; - } - finally - { - timeoutTokenSource.Dispose(); - } - } - - public void StopDownloading() - { - _cancellationTokenSource.Cancel(); - _cancellationTokenSource = new CancellationTokenSource(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageDownloadingService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageDownloadingService.cs.meta deleted file mode 100644 index 5e82ecb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageDownloadingService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: adc44e974cb91b54fac3819284b7ba82 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageUploadingService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageUploadingService.cs deleted file mode 100644 index 53da1bb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageUploadingService.cs +++ /dev/null @@ -1,103 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Api.Responses; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading; -using System.Threading.Tasks; -using UnityEditor; - -namespace AssetStoreTools.Uploader.Services.Api -{ - internal class PackageUploadingService : IPackageUploadingService - { - private class UploadInProgress - { - public IPackageUploader Uploader; - public IProgress Progress = new Progress(); - public CancellationTokenSource CancellationTokenSource = new CancellationTokenSource(); - - public UploadInProgress(IPackageUploader uploader, IProgress progress) - { - Uploader = uploader; - Progress = progress; - CancellationTokenSource = new CancellationTokenSource(); - } - } - - private IAssetStoreApi _api; - private List _uploadsInProgress; - - public bool IsUploading => _uploadsInProgress.Count > 0; - - public PackageUploadingService(IAssetStoreApi api) - { - _api = api; - _uploadsInProgress = new List(); - } - - public async Task UploadPackage(IPackageUploader uploader, IProgress progress) - { - using (var cancellationTokenSource = new CancellationTokenSource()) - { - var uploadInProgress = StartTrackingUpload(uploader, progress); - var response = await _api.UploadPackage(uploadInProgress.Uploader, uploadInProgress.Progress, uploadInProgress.CancellationTokenSource.Token); - StopTrackingUpload(uploadInProgress); - - return response; - } - } - - private UploadInProgress StartTrackingUpload(IPackageUploader uploader, IProgress progress) - { - // If this is the first upload - lock reload assemblies and prevent entering play mode - if (_uploadsInProgress.Count == 0) - { - EditorApplication.LockReloadAssemblies(); - EditorApplication.playModeStateChanged += PreventEnteringPlayMode; - } - - var uploadInProgress = new UploadInProgress(uploader, progress); - _uploadsInProgress.Add(uploadInProgress); - - return uploadInProgress; - } - - private void StopTrackingUpload(UploadInProgress uploadInProgress) - { - _uploadsInProgress.Remove(uploadInProgress); - - // If this was the last upload - unlock reload assemblies and allow entering play mode - if (_uploadsInProgress.Count > 0) - return; - - EditorApplication.UnlockReloadAssemblies(); - EditorApplication.playModeStateChanged -= PreventEnteringPlayMode; - } - - private void PreventEnteringPlayMode(PlayModeStateChange change) - { - if (change != PlayModeStateChange.ExitingEditMode) - return; - - EditorApplication.ExitPlaymode(); - EditorUtility.DisplayDialog("Notice", "Entering Play Mode is not allowed while there's a package upload in progress.\n\n" + - "Please wait until the upload is finished or cancel the upload from the Asset Store Uploader window", "OK"); - } - - public void StopUploading(IPackageUploader uploader) - { - var uploadInProgress = _uploadsInProgress.FirstOrDefault(x => x.Uploader == uploader); - if (uploadInProgress == null) - return; - - uploadInProgress.CancellationTokenSource.Cancel(); - } - - public void StopAllUploadinng() - { - foreach (var uploadInProgress in _uploadsInProgress) - uploadInProgress.CancellationTokenSource.Cancel(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageUploadingService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageUploadingService.cs.meta deleted file mode 100644 index 3ea1381..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Api/PackageUploadingService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 22e23997fe339a74bb5355d6a88ce731 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching.meta deleted file mode 100644 index 7267ddb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: a834946d92154754493879c5fcc7dbc9 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/CachingService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/CachingService.cs deleted file mode 100644 index c86ee80..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/CachingService.cs +++ /dev/null @@ -1,157 +0,0 @@ -using AssetStoreTools.Api.Models; -using AssetStoreTools.Uploader.Data.Serialization; -using AssetStoreTools.Utility; -using Newtonsoft.Json; -using System; -using System.Collections.Generic; -using System.IO; -using System.Text; -using UnityEditor; -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.Services -{ - internal class CachingService : ICachingService - { - private VisualElement _cachedUploaderWindow; - - public bool GetCachedUploaderWindow(out VisualElement uploaderWindow) - { - uploaderWindow = _cachedUploaderWindow; - return uploaderWindow != null; - } - - public void CacheUploaderWindow(VisualElement uploaderWindow) - { - _cachedUploaderWindow = uploaderWindow; - } - - public void CacheSessionToken(string sessionToken) - { - if (string.IsNullOrEmpty(sessionToken)) - throw new ArgumentException("Session token cannot be null"); - - EditorPrefs.SetString(Constants.Cache.SessionTokenKey, sessionToken); - } - - public bool GetCachedSessionToken(out string sessionToken) - { - sessionToken = EditorPrefs.GetString(Constants.Cache.SessionTokenKey, string.Empty); - return !string.IsNullOrEmpty(sessionToken); - } - - public void ClearCachedSessionToken() - { - EditorPrefs.DeleteKey(Constants.Cache.SessionTokenKey); - } - - public bool GetCachedPackageMetadata(out List data) - { - data = new List(); - if (!CacheUtil.GetFileFromTempCache(Constants.Cache.PackageDataFileName, out var filePath)) - return false; - - try - { - var serializerSettings = new JsonSerializerSettings() - { - ContractResolver = Package.CachedPackageResolver.Instance - }; - - data = JsonConvert.DeserializeObject>(File.ReadAllText(filePath, Encoding.UTF8), serializerSettings); - return true; - } - catch - { - return false; - } - } - - public void CachePackageMetadata(List data) - { - if (data == null) - throw new ArgumentException("Package data cannot be null"); - - var serializerSettings = new JsonSerializerSettings() - { - ContractResolver = Package.CachedPackageResolver.Instance, - Formatting = Formatting.Indented - }; - - CacheUtil.CreateFileInTempCache(Constants.Cache.PackageDataFileName, JsonConvert.SerializeObject(data, serializerSettings), true); - } - - public void DeletePackageMetadata() - { - CacheUtil.DeleteFileFromTempCache(Constants.Cache.PackageDataFileName); - } - - public void UpdatePackageMetadata(Package data) - { - if (!GetCachedPackageMetadata(out var cachedData)) - return; - - var index = cachedData.FindIndex(x => x.PackageId.Equals(data.PackageId)); - if (index == -1) - { - cachedData.Add(data); - } - else - { - cachedData.RemoveAt(index); - cachedData.Insert(index, data); - } - - CachePackageMetadata(cachedData); - } - - public bool GetCachedPackageThumbnail(string packageId, out Texture2D texture) - { - texture = null; - if (!CacheUtil.GetFileFromTempCache(Constants.Cache.PackageThumbnailFileName(packageId), out var filePath)) - return false; - - texture = new Texture2D(1, 1); - texture.LoadImage(File.ReadAllBytes(filePath)); - return true; - } - - public void CachePackageThumbnail(string packageId, Texture2D texture) - { - CacheUtil.CreateFileInTempCache(Constants.Cache.PackageThumbnailFileName(packageId), texture.EncodeToPNG(), true); - } - - public bool GetCachedWorkflowStateData(string packageId, out WorkflowStateData data) - { - data = null; - - if (string.IsNullOrEmpty(packageId)) - return false; - - if (!CacheUtil.GetFileFromPersistentCache(Constants.Cache.WorkflowStateDataFileName(packageId), out var filePath)) - return false; - - try - { - data = JsonConvert.DeserializeObject(File.ReadAllText(filePath, Encoding.UTF8)); - if (string.IsNullOrEmpty(data.GetPackageId())) - return false; - } - catch - { - return false; - } - - return true; - } - - public void CacheWorkflowStateData(WorkflowStateData data) - { - if (data == null) - throw new ArgumentException("Workflow state data cannot be null"); - - CacheUtil.CreateFileInPersistentCache(Constants.Cache.WorkflowStateDataFileName(data.GetPackageId()), JsonConvert.SerializeObject(data, Formatting.Indented), true); - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/CachingService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/CachingService.cs.meta deleted file mode 100644 index b5893a5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/CachingService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: fffaed09a3f76f945a7ececfb355f3e0 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/ICachingService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/ICachingService.cs deleted file mode 100644 index 1077281..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/ICachingService.cs +++ /dev/null @@ -1,25 +0,0 @@ -using AssetStoreTools.Api.Models; -using AssetStoreTools.Uploader.Data.Serialization; -using System.Collections.Generic; -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.Services -{ - internal interface ICachingService : IUploaderService - { - void CacheUploaderWindow(VisualElement uploaderWindow); - bool GetCachedUploaderWindow(out VisualElement uploaderWindow); - void CacheSessionToken(string sessionToken); - bool GetCachedSessionToken(out string sessionToken); - void ClearCachedSessionToken(); - bool GetCachedPackageMetadata(out List data); - void UpdatePackageMetadata(Package data); - void CachePackageMetadata(List data); - void DeletePackageMetadata(); - bool GetCachedPackageThumbnail(string packageId, out Texture2D texture); - void CachePackageThumbnail(string packageId, Texture2D texture); - bool GetCachedWorkflowStateData(string packageId, out WorkflowStateData data); - void CacheWorkflowStateData(WorkflowStateData data); - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/ICachingService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/ICachingService.cs.meta deleted file mode 100644 index 559ee87..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/Caching/ICachingService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a904477679e07bc4889bc15e894c0c48 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/IUploaderService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/IUploaderService.cs deleted file mode 100644 index 424dd9c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/IUploaderService.cs +++ /dev/null @@ -1,4 +0,0 @@ -namespace AssetStoreTools.Uploader.Services -{ - internal interface IUploaderService { } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/IUploaderService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/IUploaderService.cs.meta deleted file mode 100644 index 7168b6f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/IUploaderService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 757d7a4dc29863740859c936be514fea -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory.meta deleted file mode 100644 index cb9e723..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 02e4a5ee9e2fb7941b876b207078e01d -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/IPackageFactoryService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/IPackageFactoryService.cs deleted file mode 100644 index 83c9c48..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/IPackageFactoryService.cs +++ /dev/null @@ -1,18 +0,0 @@ -using AssetStoreTools.Uploader.Data; -using AssetStoreTools.Uploader.Data.Serialization; -using System.Collections.Generic; -using PackageModel = AssetStoreTools.Api.Models.Package; - -namespace AssetStoreTools.Uploader.Services -{ - internal interface IPackageFactoryService : IUploaderService - { - IPackageGroup CreatePackageGroup(string groupName, List packages); - IPackage CreatePackage(PackageModel packageModel); - IPackageContent CreatePackageContent(IPackage package); - List CreateWorkflows(IPackage package, WorkflowStateData stateData); - AssetsWorkflow CreateAssetsWorkflow(IPackage package, AssetsWorkflowState stateData); - UnityPackageWorkflow CreateUnityPackageWorkflow(IPackage package, UnityPackageWorkflowState stateData); - HybridPackageWorkflow CreateHybridPackageWorkflow(IPackage package, HybridPackageWorkflowState stateData); - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/IPackageFactoryService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/IPackageFactoryService.cs.meta deleted file mode 100644 index 1a49e7c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/IPackageFactoryService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 14324b71768a1ea499baa06de33f05af -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/PackageFactoryService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/PackageFactoryService.cs deleted file mode 100644 index a9fffa5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/PackageFactoryService.cs +++ /dev/null @@ -1,95 +0,0 @@ -using AssetStoreTools.Uploader.Data; -using AssetStoreTools.Uploader.Data.Serialization; -using AssetStoreTools.Uploader.Services.Analytics; -using AssetStoreTools.Uploader.Services.Api; -using System.Collections.Generic; -using PackageModel = AssetStoreTools.Api.Models.Package; - -namespace AssetStoreTools.Uploader.Services -{ - internal class PackageFactoryService : IPackageFactoryService - { - private IWorkflowServices _workflowServices; - - // Service dependencies - private ICachingService _cachingService; - private IPackageDownloadingService _packageDownloadingService; - private IPackageUploadingService _packageUploadingService; - private IAnalyticsService _analyticsService; - - public PackageFactoryService( - ICachingService cachingService, - IPackageDownloadingService packageDownloadingService, - IPackageUploadingService packageUploadingService, - IAnalyticsService analyticsService - ) - { - _cachingService = cachingService; - _packageDownloadingService = packageDownloadingService; - _packageUploadingService = packageUploadingService; - _analyticsService = analyticsService; - - _workflowServices = new WorkflowServices(_packageDownloadingService, _packageUploadingService, _analyticsService); - } - - public IPackage CreatePackage(PackageModel packageModel) - { - var package = new Package(packageModel); - return package; - } - - public IPackageGroup CreatePackageGroup(string groupName, List packages) - { - return new PackageGroup(groupName, packages); - } - - public IPackageContent CreatePackageContent(IPackage package) - { - if (!package.IsDraft) - return null; - - WorkflowStateData stateData = GetOrCreateWorkflowStateData(package); - - var workflows = CreateWorkflows(package, stateData); - var packageContent = new PackageContent(workflows, stateData, _cachingService); - return packageContent; - } - - public List CreateWorkflows(IPackage package, WorkflowStateData stateData) - { - var workflows = new List - { - CreateAssetsWorkflow(package, stateData.GetAssetsWorkflowState()), - CreateUnityPackageWorkflow(package, stateData.GetUnityPackageWorkflowState()), -#if UNITY_ASTOOLS_EXPERIMENTAL - CreateHybridPackageWorkflow(package, stateData.GetHybridPackageWorkflowState()), -#endif - }; - - return workflows; - } - - public AssetsWorkflow CreateAssetsWorkflow(IPackage package, AssetsWorkflowState stateData) - { - return new AssetsWorkflow(package, stateData, _workflowServices); - } - - public UnityPackageWorkflow CreateUnityPackageWorkflow(IPackage package, UnityPackageWorkflowState stateData) - { - return new UnityPackageWorkflow(package, stateData, _workflowServices); - } - - public HybridPackageWorkflow CreateHybridPackageWorkflow(IPackage package, HybridPackageWorkflowState stateData) - { - return new HybridPackageWorkflow(package, stateData, _workflowServices); - } - - private WorkflowStateData GetOrCreateWorkflowStateData(IPackage package) - { - if (!_cachingService.GetCachedWorkflowStateData(package.PackageId, out var stateData)) - stateData = new WorkflowStateData(package.PackageId); - - return stateData; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/PackageFactoryService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/PackageFactoryService.cs.meta deleted file mode 100644 index b99429f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/PackageFactory/PackageFactoryService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 4074a5b21b6201d449974dcfb652a00b -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/UploaderServiceProvider.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/UploaderServiceProvider.cs deleted file mode 100644 index 0aaa686..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/UploaderServiceProvider.cs +++ /dev/null @@ -1,26 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Uploader.Services.Analytics; -using AssetStoreTools.Uploader.Services.Api; -using AssetStoreTools.Utility; - -namespace AssetStoreTools.Uploader.Services -{ - internal class UploaderServiceProvider : ServiceProvider - { - public static UploaderServiceProvider Instance => _instance ?? (_instance = new UploaderServiceProvider()); - private static UploaderServiceProvider _instance; - - private UploaderServiceProvider() { } - - protected override void RegisterServices() - { - var api = new AssetStoreApi(new AssetStoreClient()); - Register(); - Register(); - Register(() => new AuthenticationService(api, GetService(), GetService())); - Register(() => new PackageDownloadingService(api, GetService())); - Register(() => new PackageUploadingService(api)); - Register(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/UploaderServiceProvider.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/UploaderServiceProvider.cs.meta deleted file mode 100644 index ccf2e7b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/Services/UploaderServiceProvider.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: e66f9c7f198baff41ba77f4d0ed7b60f -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI.meta deleted file mode 100644 index e39a22f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: ed759a6e886dbfd4fbcecc2beb7248b8 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements.meta deleted file mode 100644 index 497fc1d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: d14df9cf4e7e9b54c8c94a8cc1aa70c0 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions.meta deleted file mode 100644 index 9ec9955..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 144a518ff26df1e41845217c0f0002d7 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/ValidationElementBase.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/ValidationElementBase.cs deleted file mode 100644 index 27957b2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/ValidationElementBase.cs +++ /dev/null @@ -1,170 +0,0 @@ -using AssetStoreTools.Uploader.Data; -using AssetStoreTools.Validator.Data; -using System.Linq; -using UnityEditor; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal abstract class ValidationElementBase : VisualElement - { - // Data - protected IWorkflow Workflow; - - // UI - protected VisualElement ResultsBox; - protected Image ResultsBoxImage; - protected Label ResultsBoxLabel; - - protected ValidationElementBase(IWorkflow workflow) - { - Workflow = workflow; - Create(); - } - - private void Create() - { - CreateInfoRow(); - CreateResultsBox(); - } - - private void CreateInfoRow() - { - VisualElement validatorButtonRow = new VisualElement(); - validatorButtonRow.AddToClassList("package-content-option-box"); - - VisualElement validatorLabelHelpRow = new VisualElement(); - validatorLabelHelpRow.AddToClassList("package-content-option-label-help-row"); - - Label validatorLabel = new Label { text = "Validation" }; - Image validatorLabelTooltip = new Image - { - tooltip = "You can use the Asset Store Validator to check your package for common publishing issues" - }; - - var validateButton = new Button(Validate) { name = "ValidateButton", text = "Validate" }; - - validatorLabelHelpRow.Add(validatorLabel); - validatorLabelHelpRow.Add(validatorLabelTooltip); - - validatorButtonRow.Add(validatorLabelHelpRow); - validatorButtonRow.Add(validateButton); - - Add(validatorButtonRow); - } - - private void CreateResultsBox() - { - ResultsBox = new Box { name = "InfoBox" }; - ResultsBox.style.display = DisplayStyle.None; - ResultsBox.AddToClassList("validation-result-box"); - - ResultsBoxImage = new Image(); - ResultsBoxLabel = new Label { name = "ValidationLabel" }; - - ResultsBox.Add(ResultsBoxImage); - ResultsBox.Add(ResultsBoxLabel); - - Add(ResultsBox); - } - - protected virtual bool ConfirmValidation() - { - // Child classes can implement pre-validation prompts - return true; - } - - private void Validate() - { - if (!ConfirmValidation()) - return; - - var validationResult = Workflow.Validate(); - - if (validationResult.Status == ValidationStatus.Cancelled) - return; - - if (validationResult.Status != ValidationStatus.RanToCompletion) - { - EditorUtility.DisplayDialog("Validation failed", $"Package validation failed: {validationResult.Exception.Message}", "OK"); - return; - } - - DisplayResult(validationResult); - } - - private void DisplayResult(ValidationResult result) - { - ResultsBox.style.display = DisplayStyle.Flex; - UpdateValidationResultImage(result); - UpdateValidationResultLabel(result); - } - - public void HideResult() - { - ResultsBox.style.display = DisplayStyle.None; - } - - protected void UpdateValidationResultImage(ValidationResult result) - { - switch (GetValidationSummaryStatus(result)) - { - case TestResultStatus.Pass: - ResultsBoxImage.image = EditorGUIUtility.IconContent("console.infoicon@2x").image; - break; - case TestResultStatus.Warning: - ResultsBoxImage.image = EditorGUIUtility.IconContent("console.warnicon@2x").image; - break; - case TestResultStatus.Fail: - ResultsBoxImage.image = EditorGUIUtility.IconContent("console.erroricon@2x").image; - break; - default: - ResultsBoxImage.image = EditorGUIUtility.IconContent("_Help@2x").image; - break; - } - } - - private void UpdateValidationResultLabel(ValidationResult result) - { - var errorCount = result.Tests.Where(x => x.Result.Status == TestResultStatus.Fail).Count(); - var warningCount = result.Tests.Where(x => x.Result.Status == TestResultStatus.Warning).Count(); - - string text = string.Empty; - if (result.HadCompilationErrors) - { - text += "- Package caused compilation errors\n"; - } - if (errorCount > 0) - { - text += $"- Validation reported {errorCount} error(s)\n"; - } - if (warningCount > 0) - { - text += $"- Validation reported {warningCount} warning(s)\n"; - } - - if (string.IsNullOrEmpty(text)) - { - text = "No issues were found!"; - } - else - { - text = text.Substring(0, text.Length - "\n".Length); - } - - ResultsBoxLabel.text = text; - } - - private TestResultStatus GetValidationSummaryStatus(ValidationResult result) - { - if (result.HadCompilationErrors || - result.Tests.Any(x => x.Result.Status == TestResultStatus.Fail)) - return TestResultStatus.Fail; - - if (result.Tests.Any(x => x.Result.Status == TestResultStatus.Warning)) - return TestResultStatus.Warning; - - return TestResultStatus.Pass; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/ValidationElementBase.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/ValidationElementBase.cs.meta deleted file mode 100644 index f96190a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/ValidationElementBase.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: cb20404763eac7144b562c18ad1c37fe -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/WorkflowElementBase.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/WorkflowElementBase.cs deleted file mode 100644 index f4b22b7..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/WorkflowElementBase.cs +++ /dev/null @@ -1,151 +0,0 @@ -using AssetStoreTools.Uploader.Data; -using AssetStoreTools.Utility; -using System; -using System.Collections.Generic; -using UnityEditor; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal abstract class WorkflowElementBase : VisualElement - { - // Data - protected IWorkflow Workflow; - public string Name => Workflow.Name; - public string DisplayName => Workflow.DisplayName; - - // UI Elements that all workflows have - protected PathSelectionElement PathSelectionElement; - protected PreviewGenerationElement PreviewGenerationElement; - protected ValidationElementBase ValidationElement; - protected PackageUploadElement UploadElement; - - public event Action OnInteractionAvailable; - public event Action OnInteractionUnavailable; - - public WorkflowElementBase(IWorkflow workflow) - { - Workflow = workflow; - } - - protected void CreatePathElement(string labelText, string labelTooltip) - { - PathSelectionElement = new PathSelectionElement(labelText, labelTooltip); - PathSelectionElement.OnBrowse += BrowsePath; - Add(PathSelectionElement); - } - - protected void CreatePreviewGenerationElement() - { - PreviewGenerationElement = new PreviewGenerationElement(Workflow); - PreviewGenerationElement.style.display = DisplayStyle.None; - var callback = new Action(() => - PreviewGenerationElement.style.display = ASToolsPreferences.Instance.UseLegacyExporting - ? DisplayStyle.None - : DisplayStyle.Flex); - RegisterCallback((_) => { ASToolsPreferences.OnSettingsChange += callback; }); - RegisterCallback((_) => { ASToolsPreferences.OnSettingsChange -= callback; }); - Add(PreviewGenerationElement); - } - - protected void CreateValidationElement(ValidationElementBase validationElement) - { - ValidationElement = validationElement; - ValidationElement.style.display = DisplayStyle.None; - Add(ValidationElement); - } - - protected void CreateUploadElement(IWorkflow workflow, bool exposeExportButton) - { - UploadElement = new PackageUploadElement(workflow, exposeExportButton); - UploadElement.OnInteractionAvailable += EnableInteraction; - UploadElement.OnInteractionUnavailable += DisableInteraction; - UploadElement.style.display = DisplayStyle.None; - Add(UploadElement); - } - - protected abstract void BrowsePath(); - - protected void SetPathSelectionTextField(string value) - { - if (string.IsNullOrEmpty(value)) - return; - - PathSelectionElement.SetPath(value); - ValidationElement.style.display = DisplayStyle.Flex; - UploadElement.style.display = DisplayStyle.Flex; - - if (PreviewGenerationElement != null && !ASToolsPreferences.Instance.UseLegacyExporting) - { - PreviewGenerationElement.style.display = DisplayStyle.Flex; - } - } - - protected void CheckForMissingMetas(IEnumerable paths) - { - bool displayDialog = ASToolsPreferences.Instance.DisplayHiddenMetaDialog && FileUtility.IsMissingMetaFiles(paths); - if (!displayDialog) - return; - - var selectedOption = EditorUtility.DisplayDialogComplex( - "Notice", - "Your package includes hidden folders which do not contain meta files. " + - "Hidden folders will not be exported unless they contain meta files.\n\nWould you like meta files to be generated?", - "Yes", "No", "No and do not display this again"); - - switch (selectedOption) - { - case 0: - try - { - FileUtility.GenerateMetaFiles(paths); - EditorUtility.DisplayDialog( - "Success", - "Meta files have been generated. Please note that further manual tweaking may be required to set up correct references", - "OK"); - } - catch (Exception e) - { - EditorUtility.DisplayDialog( - "Error", - $"Meta file generation failed: {e.Message}", - "OK" - ); - } - break; - case 1: - // Do nothing - return; - case 2: - ASToolsPreferences.Instance.DisplayHiddenMetaDialog = false; - ASToolsPreferences.Instance.Save(); - return; - } - } - - public bool Is(IWorkflow workflow) - { - return Workflow == workflow; - } - - protected virtual void EnableInteraction() - { - PathSelectionElement.SetEnabled(true); - ValidationElement.SetEnabled(true); - PreviewGenerationElement?.SetEnabled(true); - UploadElement.SetEnabled(true); - OnInteractionAvailable?.Invoke(); - } - - protected virtual void DisableInteraction() - { - PathSelectionElement.SetEnabled(false); - ValidationElement.SetEnabled(false); - PreviewGenerationElement?.SetEnabled(false); - UploadElement.SetEnabled(false); - OnInteractionUnavailable?.Invoke(); - } - - protected abstract void Deserialize(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/WorkflowElementBase.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/WorkflowElementBase.cs.meta deleted file mode 100644 index bdd8416..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/Abstractions/WorkflowElementBase.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 45d1bf267c3ea9048bfdd75d0d19c8bd -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AccountToolbar.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AccountToolbar.cs deleted file mode 100644 index 393c4aa..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AccountToolbar.cs +++ /dev/null @@ -1,102 +0,0 @@ -using AssetStoreTools.Api.Models; -using System; -using System.Threading.Tasks; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class AccountToolbar : VisualElement - { - private Image _accountImage; - private Label _accountEmailLabel; - private Button _refreshButton; - - public event Func OnRefresh; - public event Action OnLogout; - - public AccountToolbar() - { - Create(); - } - - private void Create() - { - AddToClassList("account-toolbar"); - - // Left side of the toolbar - VisualElement leftSideContainer = new VisualElement { name = "LeftSideContainer" }; - leftSideContainer.AddToClassList("account-toolbar-left-side-container"); - - _accountImage = new Image(); - _accountImage.AddToClassList("account-toolbar-user-image"); - - _accountEmailLabel = new Label() { name = "AccountEmail" }; - _accountEmailLabel.AddToClassList("account-toolbar-email-label"); - - leftSideContainer.Add(_accountImage); - leftSideContainer.Add(_accountEmailLabel); - - // Right side of the toolbar - VisualElement rightSideContainer = new VisualElement { name = "RightSideContainer" }; - rightSideContainer.AddToClassList("account-toolbar-right-side-container"); - - // Refresh button - _refreshButton = new Button(Refresh) { name = "RefreshButton", text = "Refresh" }; - _refreshButton.AddToClassList("account-toolbar-button-refresh"); - - // Logout button - var logoutButton = new Button(Logout) { name = "LogoutButton", text = "Log out" }; - logoutButton.AddToClassList("account-toolbar-button-logout"); - - rightSideContainer.Add(_refreshButton); - rightSideContainer.Add(logoutButton); - - // Constructing the final toolbar - Add(leftSideContainer); - Add(rightSideContainer); - } - - private async void Refresh() - { - _refreshButton.SetEnabled(false); - await OnRefresh?.Invoke(); - _refreshButton.SetEnabled(true); - } - - private void Logout() - { - OnLogout?.Invoke(); - } - - public void SetUser(User user) - { - if (user == null) - { - _accountEmailLabel.text = string.Empty; - _accountImage.tooltip = string.Empty; - return; - } - - var userEmail = !string.IsNullOrEmpty(user.Username) ? user.Username : "Unknown"; - var publisherName = !string.IsNullOrEmpty(user.Name) ? user.Name : "Unknown"; - var publisherId = !string.IsNullOrEmpty(user.PublisherId) ? user.PublisherId : "Unknown"; - var userInfo = - $"Username: {userEmail}\n" + - $"Publisher Name: {publisherName}\n" + - $"Publisher ID: {publisherId}"; - - _accountEmailLabel.text = userEmail; - _accountImage.tooltip = userInfo; - } - - public void EnableButtons() - { - _refreshButton.SetEnabled(true); - } - - public void DisableButtons() - { - _refreshButton.SetEnabled(false); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AccountToolbar.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AccountToolbar.cs.meta deleted file mode 100644 index 8ac16ee..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AccountToolbar.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 3c275be3817d1684ca1802c2738ac4d9 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AssetsWorkflowElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AssetsWorkflowElement.cs deleted file mode 100644 index 283017d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AssetsWorkflowElement.cs +++ /dev/null @@ -1,215 +0,0 @@ -using AssetStoreTools.Uploader.Data; -using AssetStoreTools.Utility; -using System; -using System.Collections.Generic; -using System.Linq; -using UnityEditor; -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class AssetsWorkflowElement : WorkflowElementBase - { - // Data - private AssetsWorkflow _workflow; - - // UI - private VisualElement _dependenciesToggleElement; - private Toggle _dependenciesToggle; - private MultiToggleSelectionElement _dependenciesElement; - private MultiToggleSelectionElement _specialFoldersElement; - - private const string PathSelectionTooltip = "Select the main folder of your package" + - "\n\nAll files and folders of your package should preferably be contained within a single root folder that is named after your package" + - "\n\nExample: 'Assets/[MyPackageName]'" + - "\n\nNote: If your content makes use of special folders that are required to be placed in the root Assets folder (e.g. 'StreamingAssets')," + - " you will be able to include them after selecting the main folder"; - - public AssetsWorkflowElement(AssetsWorkflow workflow) : base(workflow) - { - _workflow = workflow; - - Create(); - Deserialize(); - } - - private void Create() - { - CreatePathElement("Folder path", PathSelectionTooltip); - CreateDependenciesToggleElement(); - CreateDependenciesSelectionElement(); - CreateSpecialFoldersElement(); - CreatePreviewGenerationElement(); - CreateValidationElement(new CurrentProjectValidationElement(_workflow)); - CreateUploadElement(_workflow, true); - } - - private void CreateDependenciesToggleElement() - { - _dependenciesToggleElement = new VisualElement() { name = "Dependencies Toggle" }; - _dependenciesToggleElement.AddToClassList("package-content-option-box"); - - VisualElement dependenciesLabelHelpRow = new VisualElement(); - dependenciesLabelHelpRow.AddToClassList("package-content-option-label-help-row"); - - Label dependenciesLabel = new Label { text = "Dependencies" }; - Image dependenciesLabelTooltip = new Image - { - tooltip = "Tick this checkbox if your package content has dependencies on Unity packages from the Package Manager" - }; - - _dependenciesToggle = new Toggle { name = "DependenciesToggle", text = "Include Package Manifest" }; - _dependenciesToggle.AddToClassList("package-content-option-toggle"); - - var callback = new Action(() => DependencyToggleValueChange(true)); - _dependenciesToggle.RegisterValueChangedCallback((_) => DependencyToggleValueChange(true)); - RegisterCallback((_) => { ASToolsPreferences.OnSettingsChange += callback; }); - RegisterCallback((_) => { ASToolsPreferences.OnSettingsChange -= callback; }); - - dependenciesLabelHelpRow.Add(dependenciesLabel); - dependenciesLabelHelpRow.Add(dependenciesLabelTooltip); - - _dependenciesToggleElement.Add(dependenciesLabelHelpRow); - _dependenciesToggleElement.Add(_dependenciesToggle); - - _dependenciesToggleElement.style.display = DisplayStyle.None; - Add(_dependenciesToggleElement); - } - - private void CreateDependenciesSelectionElement() - { - _dependenciesElement = new MultiToggleSelectionElement() - { - DisplayElementLabel = false, - ElementLabel = "Dependencies", - NoSelectionLabel = "No packages match this criteria" - }; - - var setDependencies = new Action>((dict) => _workflow.SetDependencies(dict.Where(x => x.Value).Select(x => x.Key), true)); - _dependenciesElement.OnValuesChanged += setDependencies; - _dependenciesElement.style.display = DisplayStyle.None; - Add(_dependenciesElement); - } - - private void CreateSpecialFoldersElement() - { - _specialFoldersElement = new MultiToggleSelectionElement() - { - ElementLabel = "Special Folders", - ElementTooltip = "If your package content relies on Special Folders (e.g. StreamingAssets), please select which of these folders should be included in the package.", - NoSelectionLabel = "No folders match this criteria." - }; - - var setSpecialFolders = new Action>((dict) => _workflow.SetSpecialFolders(dict.Where(x => x.Value).Select(x => x.Key), true)); - _specialFoldersElement.OnValuesChanged += setSpecialFolders; - _specialFoldersElement.style.display = DisplayStyle.None; - Add(_specialFoldersElement); - } - - protected override void BrowsePath() - { - string absoluteExportPath = string.Empty; - bool includeAllAssets = false; - - if (_workflow.IsCompleteProject) - { - includeAllAssets = EditorUtility.DisplayDialog("Notice", - "Your package draft is set to a category that is treated" + - " as a complete project. Project settings will be included automatically. Would you like everything in the " + - "'Assets' folder to be included?\n\nYou will still be able to change the selected assets before uploading", - "Yes, include all folders and assets", - "No, I'll select what to include manually"); - - if (includeAllAssets) - absoluteExportPath = Application.dataPath; - } - - if (!includeAllAssets) - { - absoluteExportPath = EditorUtility.OpenFolderPanel( - "Select folder to compress into a package", "Assets/", ""); - - if (string.IsNullOrEmpty(absoluteExportPath)) - return; - } - - var relativeExportPath = FileUtility.AbsolutePathToRelativePath(absoluteExportPath, ASToolsPreferences.Instance.EnableSymlinkSupport); - if (!_workflow.IsPathValid(relativeExportPath, out var error)) - { - EditorUtility.DisplayDialog("Invalid selection", error, "OK"); - return; - } - - HandlePathSelection(relativeExportPath, true); - CheckForMissingMetas(); - } - - private void HandlePathSelection(string relativeExportPath, bool serialize) - { - if (string.IsNullOrEmpty(relativeExportPath)) - return; - - _workflow.SetMainExportPath(relativeExportPath, serialize); - SetPathSelectionTextField(relativeExportPath + "/"); - - _dependenciesToggleElement.style.display = DisplayStyle.Flex; - UpdateSpecialFoldersElement(); - } - - private void CheckForMissingMetas() - { - var paths = new List() { _workflow.GetMainExportPath() }; - paths.AddRange(_workflow.GetSpecialFolders()); - CheckForMissingMetas(paths); - } - - private void DependencyToggleValueChange(bool serialize) - { - _workflow.SetIncludeDependencies(_dependenciesToggle.value, serialize); - - if (_dependenciesToggle.value && !ASToolsPreferences.Instance.UseLegacyExporting) - { - var allDependencies = _workflow.GetAvailableDependencies(); - var selectedDependencies = allDependencies.ToDictionary(x => x, y => _workflow.GetDependencies().Any(x => x.name == y)); - _dependenciesElement.Populate(selectedDependencies); - _dependenciesElement.style.display = DisplayStyle.Flex; - } - else - { - _dependenciesElement.style.display = DisplayStyle.None; - } - } - - private void UpdateSpecialFoldersElement() - { - var availableSpecialFolders = _workflow.GetAvailableSpecialFolders(); - var selectedSpecialFolders = availableSpecialFolders.ToDictionary(x => x, y => _workflow.GetSpecialFolders().Any(x => x == y)); - _specialFoldersElement.Populate(selectedSpecialFolders); - _specialFoldersElement.style.display = availableSpecialFolders.Count > 0 ? DisplayStyle.Flex : DisplayStyle.None; - } - - protected override void EnableInteraction() - { - base.EnableInteraction(); - _dependenciesToggleElement.SetEnabled(true); - _dependenciesElement.SetEnabled(true); - _specialFoldersElement.SetEnabled(true); - } - - protected override void DisableInteraction() - { - base.DisableInteraction(); - _dependenciesToggleElement.SetEnabled(false); - _dependenciesElement.SetEnabled(false); - _specialFoldersElement.SetEnabled(false); - } - - protected override void Deserialize() - { - HandlePathSelection(_workflow.GetMainExportPath(), false); - _dependenciesToggle.SetValueWithoutNotify(_workflow.GetIncludeDependencies()); - DependencyToggleValueChange(false); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AssetsWorkflowElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AssetsWorkflowElement.cs.meta deleted file mode 100644 index 90d9e5a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/AssetsWorkflowElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 1f62ea8ab5c102e4fa574a3dcac7f6fb -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/CurrentProjectValidationElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/CurrentProjectValidationElement.cs deleted file mode 100644 index adfeab1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/CurrentProjectValidationElement.cs +++ /dev/null @@ -1,31 +0,0 @@ -using AssetStoreTools.Uploader.Data; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class CurrentProjectValidationElement : ValidationElementBase - { - public CurrentProjectValidationElement(IWorkflow workflow) : base(workflow) - { - Create(); - } - - private void Create() - { - CreateResultsBox(); - } - - private void CreateResultsBox() - { - var _viewReportButton = new Button(ViewReport) { text = "View report" }; - _viewReportButton.AddToClassList("validation-result-view-report-button"); - - ResultsBox.Add(_viewReportButton); - } - - private void ViewReport() - { - AssetStoreTools.ShowAssetStoreToolsValidator(Workflow.LastValidationSettings, Workflow.LastValidationResult); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/CurrentProjectValidationElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/CurrentProjectValidationElement.cs.meta deleted file mode 100644 index 4acf35f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/CurrentProjectValidationElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 21a1f13231b167b4c80079a2c1212101 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/ExternalProjectValidationElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/ExternalProjectValidationElement.cs deleted file mode 100644 index 12c596b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/ExternalProjectValidationElement.cs +++ /dev/null @@ -1,92 +0,0 @@ -using AssetStoreTools.Uploader.Data; -using AssetStoreTools.Utility; -using AssetStoreTools.Validator; -using System; -using System.IO; -using UnityEditor; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class ExternalProjectValidationElement : ValidationElementBase - { - private VisualElement _projectButtonContainer; - - public ExternalProjectValidationElement(IWorkflow workflow) : base(workflow) - { - Create(); - } - - private void Create() - { - CreateProjectButtonContainer(); - CreateProjectButtons(); - } - - private void CreateProjectButtonContainer() - { - _projectButtonContainer = new VisualElement(); - _projectButtonContainer.AddToClassList("validation-result-view-report-button-container"); - - ResultsBox.Add(_projectButtonContainer); - } - - private void CreateProjectButtons() - { - var openButton = new Button(OpenProject) { text = "Open Project" }; - openButton.AddToClassList("validation-result-view-report-button"); - - var saveButton = new Button(SaveProject) { text = "Save Project" }; - saveButton.AddToClassList("validation-result-view-report-button"); - - _projectButtonContainer.Add(openButton); - _projectButtonContainer.Add(saveButton); - } - - private void OpenProject() - { - try - { - EditorUtility.DisplayProgressBar("Waiting...", "Validation project is open. Waiting for it to exit...", 0.4f); - var projectPath = Workflow.LastValidationResult.ProjectPath; - ExternalProjectValidator.OpenExternalValidationProject(projectPath); - } - finally - { - EditorUtility.ClearProgressBar(); - } - } - - private void SaveProject() - { - try - { - var projectPath = Workflow.LastValidationResult.ProjectPath; - var savePath = EditorUtility.SaveFolderPanel("Select a folder", Environment.GetFolderPath(Environment.SpecialFolder.Desktop), string.Empty); - if (string.IsNullOrEmpty(savePath)) - return; - - var saveDir = new DirectoryInfo(savePath); - if (!saveDir.Exists || saveDir.GetFileSystemInfos().Length != 0) - { - EditorUtility.DisplayDialog("Saving project failed", "Selected directory must be an empty folder", "OK"); - return; - } - - EditorUtility.DisplayProgressBar("Saving...", "Saving project...", 0.4f); - FileUtility.CopyDirectory(projectPath, savePath, true); - } - finally - { - EditorUtility.ClearProgressBar(); - } - } - - protected override bool ConfirmValidation() - { - return EditorUtility.DisplayDialog("Notice", "Pre-exported package validation is performed in a separate temporary project. " + - "It may take some time for the temporary project to be created, which will halt any actions in the current project. " + - "The current project will resume work after the temporary project is exited.\n\nDo you wish to proceed?", "Yes", "No"); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/ExternalProjectValidationElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/ExternalProjectValidationElement.cs.meta deleted file mode 100644 index 63b8bea..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/ExternalProjectValidationElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 706f01d53c7eaf04bae07fb36684e31b -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/HybridPackageWorkflowElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/HybridPackageWorkflowElement.cs deleted file mode 100644 index 7598142..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/HybridPackageWorkflowElement.cs +++ /dev/null @@ -1,116 +0,0 @@ -using AssetStoreTools.Uploader.Data; -using AssetStoreTools.Utility; -using System; -using System.Collections.Generic; -using System.Linq; -using UnityEditor; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class HybridPackageWorkflowElement : WorkflowElementBase - { - // Data - private HybridPackageWorkflow _workflow; - - // UI - private MultiToggleSelectionElement _dependenciesElement; - - public HybridPackageWorkflowElement(HybridPackageWorkflow workflow) : base(workflow) - { - _workflow = workflow; - - Create(); - Deserialize(); - } - - private void Create() - { - CreatePathElement("Package path", "Select a local Package you would like to export and upload to the Store."); - CreateDependenciesElement(); - CreatePreviewGenerationElement(); - CreateValidationElement(new CurrentProjectValidationElement(_workflow)); - CreateUploadElement(_workflow, true); - } - - private void CreateDependenciesElement() - { - _dependenciesElement = new MultiToggleSelectionElement() - { - ElementLabel = "Dependencies", - ElementTooltip = "Select which local package dependencies should be included when exporting." + - "\n\nNote that only local or embedded dependencies defined in the package.json can be selected.", - NoSelectionLabel = "No packages match this criteria" - }; - - var setDependencies = new Action>((dict) => _workflow.SetDependencies(dict.Where(x => x.Value).Select(x => x.Key), true)); - _dependenciesElement.OnValuesChanged += setDependencies; - Add(_dependenciesElement); - _dependenciesElement.style.display = DisplayStyle.None; - } - - protected override void BrowsePath() - { - var absoluteExportPath = EditorUtility.OpenFilePanel("Select a package.json file", "Packages/", "json"); - if (string.IsNullOrEmpty(absoluteExportPath)) - return; - - if (!_workflow.IsPathValid(absoluteExportPath, out var error)) - { - EditorUtility.DisplayDialog("Invalid selection", error, "OK"); - return; - } - - HandlePathSelection(absoluteExportPath, true); - CheckForMissingMetas(); - } - - private void HandlePathSelection(string packageManifestPath, bool serialize) - { - if (string.IsNullOrEmpty(packageManifestPath)) - return; - - _workflow.SetPackage(packageManifestPath, serialize); - var packageFolderPath = _workflow.GetPackage().assetPath; - SetPathSelectionTextField(packageFolderPath + "/"); - - UpdateDependenciesElement(); - } - - private void CheckForMissingMetas() - { - var paths = new List() { _workflow.GetPackage().assetPath }; - paths.AddRange(_workflow.GetDependencies().Select(x => x.assetPath)); - CheckForMissingMetas(paths); - } - - private void UpdateDependenciesElement() - { - var availableDependencies = _workflow.GetAvailableDependencies(); - var selectedDependencies = availableDependencies.ToDictionary(x => x.name, y => _workflow.GetDependencies().Any(x => x.name == y.name)); - _dependenciesElement.Populate(selectedDependencies); - _dependenciesElement.style.display = availableDependencies.Count > 0 ? DisplayStyle.Flex : DisplayStyle.None; - } - - protected override void EnableInteraction() - { - base.EnableInteraction(); - _dependenciesElement.SetEnabled(true); - } - - protected override void DisableInteraction() - { - base.DisableInteraction(); - _dependenciesElement.SetEnabled(false); - } - - protected override void Deserialize() - { - var package = _workflow.GetPackage(); - if (package == null) - return; - - HandlePathSelection(AssetDatabase.GetAssetPath(package.GetManifestAsset()), false); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/HybridPackageWorkflowElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/HybridPackageWorkflowElement.cs.meta deleted file mode 100644 index 53ad66c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/HybridPackageWorkflowElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 34cd1e5cbe87bb546937a521bd2bc69c -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/LoadingSpinner.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/LoadingSpinner.cs deleted file mode 100644 index b2ad70b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/LoadingSpinner.cs +++ /dev/null @@ -1,52 +0,0 @@ -using UnityEditor; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class LoadingSpinner : VisualElement - { - // Data - private int _spinIndex; - private double _spinTimer; - private double _spinThreshold = 0.1; - - // UI - private Image _spinnerImage; - - public LoadingSpinner() - { - AddToClassList("loading-spinner-box"); - - _spinnerImage = new Image { name = "SpinnerImage" }; - _spinnerImage.AddToClassList("loading-spinner-image"); - - Add(_spinnerImage); - } - - public void Show() - { - EditorApplication.update += SpinnerLoop; - style.display = DisplayStyle.Flex; - } - - public void Hide() - { - EditorApplication.update -= SpinnerLoop; - style.display = DisplayStyle.None; - } - - private void SpinnerLoop() - { - if (_spinTimer + _spinThreshold > EditorApplication.timeSinceStartup) - return; - - _spinTimer = EditorApplication.timeSinceStartup; - _spinnerImage.image = EditorGUIUtility.IconContent($"WaitSpin{_spinIndex:00}").image; - - _spinIndex += 1; - - if (_spinIndex > 11) - _spinIndex = 0; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/LoadingSpinner.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/LoadingSpinner.cs.meta deleted file mode 100644 index 78031dc..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/LoadingSpinner.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 7c7cdef91eb9a894091869ca10d9d178 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/MultiToggleSelectionElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/MultiToggleSelectionElement.cs deleted file mode 100644 index 175a095..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/MultiToggleSelectionElement.cs +++ /dev/null @@ -1,187 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using UnityEditor.UIElements; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class MultiToggleSelectionElement : VisualElement - { - // Data - private Dictionary _selections; - private readonly List _selectionFilters = new List { "All", "Selected", "Not Selected" }; - private string _activeFilter; - - public bool DisplayElementLabel - { - get => _multiToggleSelectionHelpRow.style.visibility == Visibility.Visible; - set { _multiToggleSelectionHelpRow.style.visibility = value ? Visibility.Visible : Visibility.Hidden; } - } - - public string ElementLabel { get => _multiToggleSelectionLabel.text; set { _multiToggleSelectionLabel.text = value; } } - public string ElementTooltip { get => _multiToggleSelectionTooltip.tooltip; set { _multiToggleSelectionTooltip.tooltip = value; } } - public string NoSelectionLabel { get => _noSelectionsLabel.text; set { _noSelectionsLabel.text = value; } } - - // UI - private VisualElement _multiToggleSelectionHelpRow; - private Label _multiToggleSelectionLabel; - private Image _multiToggleSelectionTooltip; - - private ScrollView _selectionTogglesBox; - private Label _noSelectionsLabel; - private ToolbarMenu _filteringDropdown; - - public event Action> OnValuesChanged; - - public MultiToggleSelectionElement() - { - _activeFilter = _selectionFilters[0]; - AddToClassList("package-content-option-box"); - Create(); - } - - private void Create() - { - _multiToggleSelectionHelpRow = new VisualElement(); - _multiToggleSelectionHelpRow.AddToClassList("package-content-option-label-help-row"); - - _multiToggleSelectionLabel = new Label(); - _multiToggleSelectionTooltip = new Image(); - - VisualElement fullSelectionBox = new VisualElement(); - fullSelectionBox.AddToClassList("multi-toggle-box"); - - _selectionTogglesBox = new ScrollView { name = "DependencyToggles" }; - _selectionTogglesBox.AddToClassList("multi-toggle-box-scrollview"); - - _noSelectionsLabel = new Label(); - _noSelectionsLabel.AddToClassList("multi-toggle-box-empty-label"); - - var scrollContainer = _selectionTogglesBox.Q("unity-content-viewport"); - scrollContainer.Add(_noSelectionsLabel); - - VisualElement filteringBox = new VisualElement(); - filteringBox.AddToClassList("multi-toggle-box-toolbar"); - - // Select - deselect buttons - VisualElement selectingBox = new VisualElement(); - selectingBox.AddToClassList("multi-toggle-box-toolbar-selecting-box"); - - Button selectAllButton = new Button(SelectAllToggles) - { - text = "Select All" - }; - - Button deSelectAllButton = new Button(UnselectAllToggles) - { - text = "Deselect All" - }; - - selectingBox.Add(selectAllButton); - selectingBox.Add(deSelectAllButton); - - // Filtering dropdown - VisualElement filteringDropdownBox = new VisualElement(); - filteringDropdownBox.AddToClassList("multi-toggle-box-toolbar-filtering-box"); - - _filteringDropdown = new ToolbarMenu { text = _selectionFilters[0] }; - - foreach (var filter in _selectionFilters) - _filteringDropdown.menu.AppendAction(filter, (_) => { FilterDependencies(filter); }); - - filteringDropdownBox.Add(_filteringDropdown); - - // Final adding - filteringBox.Add(filteringDropdownBox); - filteringBox.Add(selectingBox); - - fullSelectionBox.Add(_selectionTogglesBox); - fullSelectionBox.Add(filteringBox); - - _multiToggleSelectionHelpRow.Add(_multiToggleSelectionLabel); - _multiToggleSelectionHelpRow.Add(_multiToggleSelectionTooltip); - - Add(_multiToggleSelectionHelpRow); - Add(fullSelectionBox); - } - - public void Populate(Dictionary selections) - { - _selectionTogglesBox.Clear(); - _selections = selections; - - EventCallback, string> callback = OnToggle; - - foreach (var kvp in selections) - { - var toggle = new Toggle() { text = kvp.Key, value = kvp.Value }; - toggle.AddToClassList("multi-toggle-box-toggle"); - toggle.RegisterCallback(callback, toggle.text); - _selectionTogglesBox.Add(toggle); - } - - FilterDependencies(_activeFilter); - } - - private void FilterDependencies(string filter) - { - _activeFilter = filter; - - var allToggles = _selectionTogglesBox.Children().Cast().ToArray(); - var selectedIndex = _selectionFilters.FindIndex(x => x == filter); - - switch (selectedIndex) - { - case 0: - foreach (var toggle in allToggles) - toggle.style.display = DisplayStyle.Flex; - break; - case 1: - foreach (var toggle in allToggles) - toggle.style.display = toggle.value ? DisplayStyle.Flex : DisplayStyle.None; - break; - case 2: - foreach (var toggle in allToggles) - toggle.style.display = toggle.value ? DisplayStyle.None : DisplayStyle.Flex; - break; - } - - // Check if any toggles are displayed - var count = allToggles.Count(toggle => toggle.style.display == DisplayStyle.Flex); - _noSelectionsLabel.style.display = count > 0 ? DisplayStyle.None : DisplayStyle.Flex; - - _filteringDropdown.text = filter; - } - - private void OnToggle(ChangeEvent evt, string text) - { - FilterDependencies(_activeFilter); - _selections[text] = evt.newValue; - OnValuesChanged?.Invoke(_selections); - } - - private void OnAllToggles(bool value) - { - var allToggles = _selectionTogglesBox.Children().Cast(); - foreach (var toggle in allToggles) - toggle.SetValueWithoutNotify(value); - - foreach (var key in _selections.Keys.ToArray()) - _selections[key] = value; - - FilterDependencies(_activeFilter); - OnValuesChanged?.Invoke(_selections); - } - - private void SelectAllToggles() - { - OnAllToggles(true); - } - - private void UnselectAllToggles() - { - OnAllToggles(false); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/MultiToggleSelectionElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/MultiToggleSelectionElement.cs.meta deleted file mode 100644 index 8e33995..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/MultiToggleSelectionElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 19e30766043794345beb432973e0eb3c -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageContentElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageContentElement.cs deleted file mode 100644 index eac8455..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageContentElement.cs +++ /dev/null @@ -1,137 +0,0 @@ -using AssetStoreTools.Uploader.Data; -using AssetStoreTools.Utility; -using System.Collections.Generic; -using UnityEditor.UIElements; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class PackageContentElement : VisualElement - { - // Data - private IPackageContent _content; - private List _workflowElements; - - // UI - private VisualElement _workflowSelectionBox; - private ToolbarMenu _toolbarMenu; - - public PackageContentElement(IPackageContent content) - { - _content = content; - content.OnActiveWorkflowChanged += ActiveWorkflowChanged; - - _workflowElements = new List(); - - Create(); - } - - private void Create() - { - AddToClassList("package-content-element"); - - CreateWorkflowSelection(); - CreateWorkflows(); - Deserialize(); - } - - private void CreateWorkflowSelection() - { - _workflowSelectionBox = new VisualElement(); - _workflowSelectionBox.AddToClassList("package-content-option-box"); - - VisualElement labelHelpRow = new VisualElement(); - labelHelpRow.AddToClassList("package-content-option-label-help-row"); - - Label workflowLabel = new Label { text = "Upload type" }; - Image workflowLabelTooltip = new Image - { - tooltip = "Select what content you are uploading to the Asset Store" - + "\n\n- From Assets Folder - content located within the project's 'Assets' folder or one of its subfolders" - + "\n\n- Pre-exported .unitypackage - content that has already been compressed into a .unitypackage file" -#if UNITY_ASTOOLS_EXPERIMENTAL - + "\n\n- Local UPM Package - content that is located within the project's 'Packages' folder. Only embedded and local packages are supported" -#endif - }; - - labelHelpRow.Add(workflowLabel); - labelHelpRow.Add(workflowLabelTooltip); - - _toolbarMenu = new ToolbarMenu(); - _toolbarMenu.AddToClassList("package-content-option-dropdown"); - - foreach (var workflow in _content.GetAvailableWorkflows()) - { - AppendToolbarActionForWorkflow(workflow); - } - - _workflowSelectionBox.Add(labelHelpRow); - _workflowSelectionBox.Add(_toolbarMenu); - - Add(_workflowSelectionBox); - } - - private void AppendToolbarActionForWorkflow(IWorkflow workflow) - { - _toolbarMenu.menu.AppendAction(workflow.DisplayName, _ => - { - _content.SetActiveWorkflow(workflow); - }); - } - - private void CreateWorkflows() - { - foreach (var workflow in _content.GetAvailableWorkflows()) - { - WorkflowElementBase element; - switch (workflow) - { - case AssetsWorkflow assetsWorkflow: - element = new AssetsWorkflowElement(assetsWorkflow); - break; - case UnityPackageWorkflow unityPackageWorkflow: - element = new UnityPackageWorkflowElement(unityPackageWorkflow); - break; -#if UNITY_ASTOOLS_EXPERIMENTAL - case HybridPackageWorkflow hybridPackageWorkflow: - element = new HybridPackageWorkflowElement(hybridPackageWorkflow); - break; -#endif - default: - ASDebug.LogWarning("Package Content Element received an undefined workflow"); - continue; - } - - element.OnInteractionAvailable += EnableInteraction; - element.OnInteractionUnavailable += DisableInteraction; - _workflowElements.Add(element); - Add(element); - } - } - - private void ActiveWorkflowChanged(IWorkflow workflow) - { - _toolbarMenu.text = workflow.DisplayName; - foreach (var workflowElement in _workflowElements) - { - bool show = workflowElement.Is(workflow); - workflowElement.style.display = show ? DisplayStyle.Flex : DisplayStyle.None; - } - } - - private void EnableInteraction() - { - _workflowSelectionBox.SetEnabled(true); - } - - private void DisableInteraction() - { - _workflowSelectionBox.SetEnabled(false); - } - - private void Deserialize() - { - ActiveWorkflowChanged(_content.GetActiveWorkflow()); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageContentElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageContentElement.cs.meta deleted file mode 100644 index 6a3eca3..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageContentElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 09927e9c8fd6e074fa451add92b7ab6f -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageElement.cs deleted file mode 100644 index f934979..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageElement.cs +++ /dev/null @@ -1,215 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Uploader.Data; -using AssetStoreTools.Uploader.Services; -using System; -#if !UNITY_2021_1_OR_NEWER -using UnityEditor.UIElements; -#endif -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class PackageElement : VisualElement - { - // Data - private IPackage _package; - private bool _isSelected; - - private IPackageFactoryService _packageFactory; - - // UI - private Button _foldoutBox; - private Label _expanderLabel; - private Label _assetLabel; - private Label _lastDateSizeLabel; - private Image _assetImage; - - private ProgressBar _uploadProgressBar; - private VisualElement _uploadProgressBarBackground; - - private PackageContentElement _contentElement; - - public event Action OnSelected; - - public PackageElement(IPackage package, IPackageFactoryService packageFactory) - { - _package = package; - _package.OnUpdate += Refresh; - _package.OnIconUpdate += SetPackageThumbnail; - - _packageFactory = packageFactory; - - _isSelected = false; - - Create(); - } - - private void Create() - { - AddToClassList("package-full-box"); - - _foldoutBox = new Button { name = "Package" }; - _foldoutBox.AddToClassList("package-foldout-box"); - if (_package.IsDraft) - _foldoutBox.AddToClassList("package-foldout-box-draft"); - _foldoutBox.clickable.clicked += Toggle; - - // Expander, Icon and Asset Label - VisualElement foldoutBoxInfo = new VisualElement { name = "foldoutBoxInfo" }; - foldoutBoxInfo.AddToClassList("package-foldout-box-info"); - - VisualElement labelExpanderRow = new VisualElement { name = "labelExpanderRow" }; - labelExpanderRow.AddToClassList("package-expander-label-row"); - - _expanderLabel = new Label { name = "ExpanderLabel", text = "►" }; - _expanderLabel.AddToClassList("package-expander"); - _expanderLabel.style.display = _package.IsDraft ? DisplayStyle.Flex : DisplayStyle.None; - - _assetImage = new Image { name = "AssetImage" }; - _assetImage.AddToClassList("package-image"); - - VisualElement assetLabelInfoBox = new VisualElement { name = "assetLabelInfoBox" }; - assetLabelInfoBox.AddToClassList("package-label-info-box"); - - _assetLabel = new Label { name = "AssetLabel", text = _package.Name }; - _assetLabel.AddToClassList("package-label"); - - _lastDateSizeLabel = new Label { name = "AssetInfoLabel", text = FormatDateSize() }; - _lastDateSizeLabel.AddToClassList("package-info"); - - assetLabelInfoBox.Add(_assetLabel); - assetLabelInfoBox.Add(_lastDateSizeLabel); - - labelExpanderRow.Add(_expanderLabel); - labelExpanderRow.Add(_assetImage); - labelExpanderRow.Add(assetLabelInfoBox); - - var openInBrowserButton = new Button(OpenPackageInBrowser) - { - name = "OpenInBrowserButton", - tooltip = "View your package in the Publishing Portal." - }; - openInBrowserButton.AddToClassList("package-open-in-browser-button"); - - // Header Progress bar - _uploadProgressBar = new ProgressBar { name = "HeaderProgressBar" }; - _uploadProgressBar.AddToClassList("package-header-progress-bar"); - _uploadProgressBar.style.display = DisplayStyle.None; - _uploadProgressBarBackground = _uploadProgressBar.Q(className: "unity-progress-bar__progress"); - - // Connect it all - foldoutBoxInfo.Add(labelExpanderRow); - foldoutBoxInfo.Add(openInBrowserButton); - - _foldoutBox.Add(foldoutBoxInfo); - _foldoutBox.Add(_uploadProgressBar); - - Add(_foldoutBox); - } - - private void CreateFoldoutContent() - { - var content = _packageFactory.CreatePackageContent(_package); - if (content == null) - return; - - _contentElement = new PackageContentElement(content); - _contentElement.style.display = DisplayStyle.None; - Add(_contentElement); - - SubscribeToContentWorkflowUpdates(content); - } - - private void SubscribeToContentWorkflowUpdates(IPackageContent content) - { - foreach (var workflow in content.GetAvailableWorkflows()) - { - workflow.OnUploadStateChanged += UpdateProgressBar; - } - } - - private void UpdateProgressBar(UploadStatus? status, float? progress) - { - if (status != null) - { - _uploadProgressBarBackground.style.backgroundColor = PackageUploadElement.GetColorByStatus(status.Value); - } - - if (progress != null) - { - _uploadProgressBar.value = progress.Value; - } - } - - private void Toggle() - { - if (!_package.IsDraft) - return; - - if (!Contains(_contentElement)) - CreateFoldoutContent(); - - var shouldExpand = !_isSelected; - _expanderLabel.text = shouldExpand ? "▼" : "►"; - - if (shouldExpand) - _foldoutBox.AddToClassList("package-foldout-box-expanded"); - else - _foldoutBox.RemoveFromClassList("package-foldout-box-expanded"); - _contentElement.style.display = shouldExpand ? DisplayStyle.Flex : DisplayStyle.None; - - _isSelected = !_isSelected; - ToggleProgressBar(); - - if (_isSelected) - OnSelected?.Invoke(); - } - - private void ToggleProgressBar() - { - if (!_isSelected && _uploadProgressBar.value != 0) - _uploadProgressBar.style.display = DisplayStyle.Flex; - else - _uploadProgressBar.style.display = DisplayStyle.None; - } - - public bool Is(IPackage package) - { - return package == _package; - } - - public void Select() - { - if (!_isSelected) - Toggle(); - } - - public void Unselect() - { - if (_isSelected) - Toggle(); - } - - private void SetPackageThumbnail() - { - _assetImage.image = _package.Icon; - } - - private void Refresh() - { - _assetLabel.text = _package.Name; - _lastDateSizeLabel.text = FormatDateSize(); - } - - private string FormatDateSize() - { - return $"{_package.Category} | {_package.FormattedSize()} | {_package.FormattedModified()}"; - } - - private void OpenPackageInBrowser() - { - Application.OpenURL($"https://publisher.unity.com/packages/{_package.VersionId}/edit/upload"); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageElement.cs.meta deleted file mode 100644 index e807599..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: cef5f23043d318945b844bcac7a7a984 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageGroupElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageGroupElement.cs deleted file mode 100644 index 6c549c0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageGroupElement.cs +++ /dev/null @@ -1,149 +0,0 @@ -using AssetStoreTools.Uploader.Data; -using AssetStoreTools.Uploader.Services; -using System.Collections.Generic; -using System.Linq; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class PackageGroupElement : VisualElement - { - // Data - public string Name => _packageGroup.Name; - private IPackageGroup _packageGroup; - private List _packageElements; - private bool _isExpanded; - - private IPackageFactoryService _packageFactory; - - // UI - private Button _groupExpanderBox; - private VisualElement _groupContent; - - private Label _expanderLabel; - private Label _groupLabel; - - public PackageGroupElement(IPackageGroup packageGroup, IPackageFactoryService packageFactory) - { - _packageGroup = packageGroup; - _packageElements = new List(); - _packageGroup.OnPackagesSorted += RefreshPackages; - _packageGroup.OnPackagesFiltered += RefreshPackages; - - _packageFactory = packageFactory; - - Create(); - } - - private void Create() - { - CreatePackageGroup(); - CreatePackageGroupContent(); - AddPackagesToGroupContent(); - } - - protected void CreatePackageGroup() - { - _groupExpanderBox = new Button(OnPackageGroupClicked); - _groupExpanderBox.AddToClassList("package-group-expander-box"); - - _expanderLabel = new Label { name = "ExpanderLabel", text = "►" }; - _expanderLabel.AddToClassList("package-group-expander"); - - _groupLabel = new Label { text = $"{_packageGroup.Name} ({_packageGroup.Packages.Count})" }; - _groupLabel.AddToClassList("package-group-label"); - FormatGroupLabel(_packageGroup.Packages.Count); - - _groupExpanderBox.Add(_expanderLabel); - _groupExpanderBox.Add(_groupLabel); - - Add(_groupExpanderBox); - } - - private void CreatePackageGroupContent() - { - _groupContent = new VisualElement { name = "GroupContentBox" }; - _groupContent.AddToClassList("package-group-content-box"); - Toggle(false); - - var groupSeparator = new VisualElement { name = "GroupSeparator" }; - groupSeparator.AddToClassList("package-group-separator"); - - if (_packageGroup.Name.ToLower() != "draft") - { - _groupLabel.SetEnabled(false); - _groupContent.AddToClassList("unity-disabled"); - groupSeparator.style.display = DisplayStyle.Flex; - } - - Add(_groupContent); - Add(groupSeparator); - } - - private void AddPackagesToGroupContent() - { - foreach (var package in _packageGroup.Packages) - { - var packageElement = new PackageElement(package, _packageFactory); - packageElement.OnSelected += () => OnPackageSelected(packageElement); - _packageElements.Add(packageElement); - } - } - - private void FormatGroupLabel(int displayedPackageCount) - { - if (_packageGroup.Packages.Count == displayedPackageCount) - _groupLabel.text = $"{Name} ({displayedPackageCount})"; - else - _groupLabel.text = $"{Name} ({displayedPackageCount}/{_packageGroup.Packages.Count})"; - } - - private void RefreshPackages(List packages) - { - _groupContent.Clear(); - - foreach (var package in packages) - { - var correspondingElement = _packageElements.FirstOrDefault(x => x.Is(package)); - if (correspondingElement == null) - continue; - - _groupContent.Add(correspondingElement); - } - - FormatGroupLabel(packages.Count()); - } - - private void OnPackageGroupClicked() - { - Toggle(!_isExpanded); - } - - public void Toggle(bool expand) - { - if (expand) - { - _expanderLabel.text = "▼"; - _groupContent.style.display = DisplayStyle.Flex; - } - else - { - _expanderLabel.text = "►"; - _groupContent.style.display = DisplayStyle.None; - } - - _isExpanded = expand; - } - - private void OnPackageSelected(PackageElement packageElement) - { - foreach (var element in _packageElements) - { - if (element == packageElement) - continue; - - element.Unselect(); - } - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageGroupElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageGroupElement.cs.meta deleted file mode 100644 index 64cde03..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageGroupElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 41e322a1418ab824182eade111145dff -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageListToolbar.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageListToolbar.cs deleted file mode 100644 index 0dfc3c2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageListToolbar.cs +++ /dev/null @@ -1,58 +0,0 @@ -using AssetStoreTools.Uploader.Data; -using System.Collections.Generic; -using UnityEditor.UIElements; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class PackageListToolbar : VisualElement - { - private List _packageGroups; - - public PackageListToolbar() - { - Create(); - } - - private void Create() - { - AddToClassList("package-list-toolbar"); - - // Search - var searchField = new ToolbarSearchField { name = "SearchField" }; - searchField.AddToClassList("package-search-field"); - - // Sorting menu button - var sortMenu = new ToolbarMenu() { text = "Sort: Name ↓" }; - sortMenu.menu.AppendAction("Sort: Name ↓", (_) => { sortMenu.text = "Sort: Name ↓"; Sort(PackageSorting.Name); }); - sortMenu.menu.AppendAction("Sort: Updated ↓", (_) => { sortMenu.text = "Sort: Updated ↓"; Sort(PackageSorting.Date); }); - sortMenu.menu.AppendAction("Sort: Category ↓", (_) => { sortMenu.text = "Sort: Category ↓"; Sort(PackageSorting.Category); }); - sortMenu.AddToClassList("package-sort-menu"); - - // Finalize the bar - Add(searchField); - Add(sortMenu); - - // Add Callbacks and click events - searchField.RegisterCallback>(SearchFilter); - } - - public void SetPackageGroups(List packageGroups) - { - _packageGroups = packageGroups; - } - - private void SearchFilter(ChangeEvent evt) - { - var searchString = evt.newValue.ToLower(); - foreach (var packageGroup in _packageGroups) - packageGroup.Filter(searchString); - } - - public void Sort(PackageSorting sortingType) - { - foreach (var packageGroup in _packageGroups) - packageGroup.Sort(sortingType); - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageListToolbar.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageListToolbar.cs.meta deleted file mode 100644 index d877de7..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageListToolbar.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 6d2659328222e0e4cb36cd194e023f4b -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageUploadElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageUploadElement.cs deleted file mode 100644 index 06fe8ea..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageUploadElement.cs +++ /dev/null @@ -1,321 +0,0 @@ -using AssetStoreTools.Api; -using AssetStoreTools.Api.Responses; -using AssetStoreTools.Exporter; -using AssetStoreTools.Uploader.Data; -using AssetStoreTools.Utility; -using System; -using System.IO; -using System.Text.RegularExpressions; -using System.Threading.Tasks; -using UnityEditor; -#if !UNITY_2021_1_OR_NEWER -using UnityEditor.UIElements; -#endif -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class PackageUploadElement : VisualElement - { - // Data - private IWorkflow _workflow; - private bool _enableExporting; - - // UI - private VisualElement _exportAndUploadContainer; - - private Button _cancelUploadButton; - private VisualElement _uploadProgressContainer; - private ProgressBar _uploadProgressBar; - private VisualElement _uploadProgressBarBackground; - - public event Action OnInteractionAvailable; - public event Action OnInteractionUnavailable; - - public PackageUploadElement(IWorkflow workflow, bool exposeExportButton) - { - _workflow = workflow; - _enableExporting = exposeExportButton; - - Create(); - } - - private void Create() - { - AddToClassList("uploading-box"); - - CreateButtonContainer(); - CreateProgressContainer(); - } - - private void CreateButtonContainer() - { - _exportAndUploadContainer = new VisualElement(); - _exportAndUploadContainer.AddToClassList("uploading-export-and-upload-container"); - - CreateExportButton(); - CreateUploadButton(); - Add(_exportAndUploadContainer); - } - - private void CreateExportButton() - { - if (!_enableExporting) - return; - - var _exportAndUploadButton = new Button(async () => await Export(true)) { name = "ExportButton", text = "Export" }; - _exportAndUploadButton.AddToClassList("uploading-export-button"); - - _exportAndUploadContainer.Add(_exportAndUploadButton); - } - - private void CreateUploadButton() - { - var _uploadButton = new Button(Upload) { name = "UploadButton" }; - _uploadButton.text = _enableExporting ? "Export and Upload" : "Upload"; - _uploadButton.AddToClassList("uploading-upload-button"); - - _exportAndUploadContainer.Add(_uploadButton); - } - - private void CreateProgressContainer() - { - _uploadProgressContainer = new VisualElement(); - _uploadProgressContainer.AddToClassList("uploading-progress-container"); - _uploadProgressContainer.style.display = DisplayStyle.None; - - _uploadProgressBar = new ProgressBar { name = "UploadProgressBar" }; - _uploadProgressBar.AddToClassList("uploading-progress-bar"); - _uploadProgressBarBackground = _uploadProgressBar.Q(className: "unity-progress-bar__progress"); - - _cancelUploadButton = new Button() { name = "CancelButton", text = "Cancel" }; - _cancelUploadButton.AddToClassList("uploading-cancel-button"); - - _uploadProgressContainer.Add(_uploadProgressBar); - _uploadProgressContainer.Add(_cancelUploadButton); - - Add(_uploadProgressContainer); - } - - private async Task Export(bool interactive) - { - try - { - DisableInteraction(); - - if (!_workflow.IsPathSet) - { - EditorUtility.DisplayDialog("Exporting failed", "No path was selected. Please " + - "select a path and try again.", "OK"); - return new PackageExporterResult() { Success = false, Exception = new Exception("No path was selected.") }; - } - - var rootProjectPath = Constants.RootProjectPath; - var packageNameStripped = Regex.Replace(_workflow.PackageName, "[^a-zA-Z0-9]", ""); - var outputName = $"{packageNameStripped}-{DateTime.Now:yyyy-dd-M--HH-mm-ss}"; - - string outputPath; - if (interactive) - { - outputPath = EditorUtility.SaveFilePanel("Export Package", rootProjectPath, - outputName, _workflow.PackageExtension.Remove(0, 1)); // Ignoring the '.' character since SaveFilePanel already appends it - - if (string.IsNullOrEmpty(outputPath)) - return new PackageExporterResult() { Success = false, Exception = null }; - } - else - { - outputPath = $"Temp/{outputName}{_workflow.PackageExtension}"; - } - - var exportResult = await _workflow.ExportPackage(outputPath); - if (!exportResult.Success) - { - Debug.LogError($"Package exporting failed: {exportResult.Exception}"); - EditorUtility.DisplayDialog("Exporting failed", exportResult.Exception.Message, "OK"); - } - else if (interactive) - Debug.Log($"Package exported to '{Path.GetFullPath(exportResult.ExportedPath).Replace("\\", "/")}'"); - - return exportResult; - } - finally - { - if (interactive) - EnableInteraction(); - } - } - - private async void Upload() - { - DisableInteraction(); - - if (await ValidateUnityVersionsBeforeUpload() == false) - { - EnableInteraction(); - return; - } - - var exportResult = await Export(false); - if (!exportResult.Success) - { - EnableInteraction(); - return; - } - - if (!_workflow.IsPathSet) - { - EditorUtility.DisplayDialog("Uploading failed", "No path was selected. Please " + - "select a path and try again.", "OK"); - EnableInteraction(); - return; - } - - _exportAndUploadContainer.style.display = DisplayStyle.None; - _uploadProgressContainer.style.display = DisplayStyle.Flex; - - _cancelUploadButton.clicked += Cancel; - _workflow.OnUploadStateChanged += UpdateProgressBar; - var response = await _workflow.UploadPackage(exportResult.ExportedPath); - _workflow.OnUploadStateChanged -= UpdateProgressBar; - - await OnUploadingStopped(response); - } - - private async Task ValidateUnityVersionsBeforeUpload() - { - var validationEnabled = ASToolsPreferences.Instance.UploadVersionCheck; - if (!validationEnabled) - return true; - - var requiredVersionUploaded = await _workflow.ValidatePackageUploadedVersions(); - if (requiredVersionUploaded) - return true; - - var result = EditorUtility.DisplayDialogComplex("Asset Store Tools", $"You may upload this package, but you will need to add a package using Unity version {Constants.Uploader.MinRequiredUnitySupportVersion} " + - "or higher to be able to submit a new asset", "Upload", "Cancel", "Upload and do not display this again"); - - switch (result) - { - case 1: - return false; - case 2: - ASToolsPreferences.Instance.UploadVersionCheck = false; - ASToolsPreferences.Instance.Save(); - break; - } - - return true; - } - - private void UpdateProgressBar(UploadStatus? status, float? progress) - { - if (status != null) - { - _uploadProgressBarBackground.style.backgroundColor = GetColorByStatus(status.Value); - } - - if (progress != null) - { - _uploadProgressBar.value = progress.Value; - _uploadProgressBar.title = $"{progress.Value:0.#}%"; - - if (progress == 100f && _cancelUploadButton.enabledInHierarchy) - _cancelUploadButton.SetEnabled(false); - } - } - - private void Cancel() - { - _cancelUploadButton.SetEnabled(false); - _workflow.AbortUpload(); - } - - private async Task OnUploadingStopped(PackageUploadResponse response) - { - if (!response.Success && !response.Cancelled) - { - Debug.LogException(response.Exception); - } - - if (response.Success) - { - await _workflow.RefreshPackage(); - } - - if (response.Status == UploadStatus.ResponseTimeout) - { - Debug.LogWarning($"All bytes for the package '{_workflow.PackageName}' have been uploaded, but a response " + - $"from the server was not received. This can happen because of Firewall restrictions. " + - $"Please make sure that a new version of your package has reached the Publishing Portal."); - } - - _uploadProgressBar.title = GetProgressBarTitleByStatus(response.Status); - - _cancelUploadButton.clickable = null; - _cancelUploadButton.clicked += Reset; - _cancelUploadButton.text = "Done"; - _cancelUploadButton.SetEnabled(true); - } - - private void Reset() - { - _cancelUploadButton.clickable = null; - _cancelUploadButton.text = "Cancel"; - - _workflow.ResetUploadStatus(); - UpdateProgressBar(UploadStatus.Default, 0f); - - _uploadProgressContainer.style.display = DisplayStyle.None; - _exportAndUploadContainer.style.display = DisplayStyle.Flex; - EnableInteraction(); - } - - public static Color GetColorByStatus(UploadStatus status) - { - switch (status) - { - default: - case UploadStatus.Default: - return new Color(0.13f, 0.59f, 0.95f); - case UploadStatus.Success: - case UploadStatus.ResponseTimeout: - return new Color(0f, 0.50f, 0.14f); - case UploadStatus.Cancelled: - return new Color(0.78f, 0.59f, 0f); - case UploadStatus.Fail: - return new Color(0.69f, 0.04f, 0.04f); - } - } - - private string GetProgressBarTitleByStatus(UploadStatus status) - { - var progressBarTitle = "Upload: "; - switch (status) - { - case UploadStatus.ResponseTimeout: - progressBarTitle += UploadStatus.Success; - break; - default: - progressBarTitle += status; - break; - } - - return progressBarTitle; - } - - private void EnableInteraction() - { - _exportAndUploadContainer.SetEnabled(true); - OnInteractionAvailable?.Invoke(); - } - - private void DisableInteraction() - { - _exportAndUploadContainer.SetEnabled(false); - OnInteractionUnavailable?.Invoke(); - SetEnabled(true); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageUploadElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageUploadElement.cs.meta deleted file mode 100644 index b3d5d3d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PackageUploadElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 242524e968bd4484eaeb154d8013f427 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PathSelectionElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PathSelectionElement.cs deleted file mode 100644 index d8d79bf..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PathSelectionElement.cs +++ /dev/null @@ -1,63 +0,0 @@ -using System; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class PathSelectionElement : VisualElement - { - // Data - private string _labelText; - private string _labelTooltip; - - public event Action OnBrowse; - - // UI - private TextField _pathSelectionTextField; - - public PathSelectionElement(string labelText, string labelTooltip) - { - AddToClassList("package-content-option-box"); - - _labelText = labelText; - _labelTooltip = labelTooltip; - - Create(); - } - - private void Create() - { - VisualElement labelHelpRow = new VisualElement(); - labelHelpRow.AddToClassList("package-content-option-label-help-row"); - - Label folderPathLabel = new Label { text = _labelText }; - Image folderPathLabelTooltip = new Image - { - tooltip = _labelTooltip - }; - - labelHelpRow.Add(folderPathLabel); - labelHelpRow.Add(folderPathLabelTooltip); - - _pathSelectionTextField = new TextField(); - _pathSelectionTextField.AddToClassList("package-content-option-textfield"); - _pathSelectionTextField.isReadOnly = true; - - Button browsePathButton = new Button(Browse) { name = "BrowsePathButton", text = "Browse" }; - browsePathButton.AddToClassList("package-content-option-button"); - - Add(labelHelpRow); - Add(_pathSelectionTextField); - Add(browsePathButton); - } - - private void Browse() - { - OnBrowse?.Invoke(); - } - - public void SetPath(string path) - { - _pathSelectionTextField.value = path; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PathSelectionElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PathSelectionElement.cs.meta deleted file mode 100644 index 2ba9f4a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PathSelectionElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 753d4442293e5cc4b9efcab089da4d59 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PreviewGenerationElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PreviewGenerationElement.cs deleted file mode 100644 index 8533207..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PreviewGenerationElement.cs +++ /dev/null @@ -1,109 +0,0 @@ -using AssetStoreTools.Previews.Data; -using AssetStoreTools.Uploader.Data; -using System.Linq; -using UnityEditor; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class PreviewGenerationElement : VisualElement - { - // Data - private IWorkflow _workflow; - - // UI - private VisualElement _toggleRow; - private Toggle _previewToggle; - - private VisualElement _buttonRow; - private VisualElement _viewButton; - - public PreviewGenerationElement(IWorkflow workflow) - { - _workflow = workflow; - - Create(); - } - - private void Create() - { - CreateInfoRow(); - CreateViewButton(); - } - - private void CreateInfoRow() - { - _toggleRow = new VisualElement(); - _toggleRow.AddToClassList("package-content-option-box"); - - VisualElement toggleLabelHelpRow = new VisualElement(); - toggleLabelHelpRow.AddToClassList("package-content-option-label-help-row"); - - Label toggleLabel = new Label { text = "Asset Previews" }; - Image toggleLabelTooltip = new Image - { - tooltip = "Select how the previews for your assets will be generated.\n\n" + - "Unity generates asset preview images natively up to a size of 128x128. " + - "You can try generating previews which are of higher resolution, up to 300x300.\n\n" + - "Note: these asset preview images will only be displayed in the 'Package Content' section of the " + - "Asset Store listing page once the package is published, and in the package importer window that appears during the package import process.\n" + - "They will not replace the images used for the assets in the Project window after the package gets imported." - }; - - _previewToggle = new Toggle { name = "PreviewToggle", text = "Generate Hi-Res (experimental)" }; - _previewToggle.AddToClassList("package-content-option-toggle"); - _previewToggle.RegisterValueChangedCallback((_) => DependencyToggleValueChange()); - - toggleLabelHelpRow.Add(toggleLabel); - toggleLabelHelpRow.Add(toggleLabelTooltip); - - _toggleRow.Add(toggleLabelHelpRow); - _toggleRow.Add(_previewToggle); - - Add(_toggleRow); - } - - private void CreateViewButton() - { - _buttonRow = new VisualElement(); - _buttonRow.AddToClassList("package-content-option-box"); - _buttonRow.style.display = DisplayStyle.None; - - var spaceFiller = new VisualElement(); - spaceFiller.AddToClassList("package-content-option-label-help-row"); - - _viewButton = new Button(ViewClicked) { text = "Inspect Previews" }; - - _buttonRow.Add(spaceFiller); - _buttonRow.Add(_viewButton); - - Add(_buttonRow); - } - - private void DependencyToggleValueChange() - { - _workflow.GenerateHighQualityPreviews = _previewToggle.value; - _buttonRow.style.display = _previewToggle.value ? DisplayStyle.Flex : DisplayStyle.None; - } - - private void ViewClicked() - { - PreviewGenerationSettings settings; - if (_workflow.GenerateHighQualityPreviews) - { - settings = new CustomPreviewGenerationSettings() { InputPaths = _workflow.GetAllPaths().ToArray() }; - } - else - { - settings = new NativePreviewGenerationSettings() { InputPaths = _workflow.GetAllPaths().ToArray() }; - } - - AssetStoreTools.ShowAssetStoreToolsPreviewGenerator(settings); - } - - private void DisplayProgress(float value) - { - EditorUtility.DisplayProgressBar("Generating", "Generating previews...", value); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PreviewGenerationElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PreviewGenerationElement.cs.meta deleted file mode 100644 index 251024b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/PreviewGenerationElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 54c7971e2ad639644936d3552b4f4f49 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/UnityPackageWorkflowElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/UnityPackageWorkflowElement.cs deleted file mode 100644 index 2d61e6d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/UnityPackageWorkflowElement.cs +++ /dev/null @@ -1,58 +0,0 @@ -using AssetStoreTools.Uploader.Data; -using AssetStoreTools.Utility; -using UnityEditor; - -namespace AssetStoreTools.Uploader.UI.Elements -{ - internal class UnityPackageWorkflowElement : WorkflowElementBase - { - // Data - private UnityPackageWorkflow _workflow; - - public UnityPackageWorkflowElement(UnityPackageWorkflow workflow) : base(workflow) - { - _workflow = workflow; - Create(); - } - - private void Create() - { - CreatePathElement("Package path", "Select the .unitypackage file you would like to upload."); - CreateValidationElement(new ExternalProjectValidationElement(_workflow)); - CreateUploadElement(_workflow, false); - Deserialize(); - } - - protected override void BrowsePath() - { - // Path retrieval - var absolutePackagePath = EditorUtility.OpenFilePanel("Select a .unitypackage file", Constants.RootProjectPath, "unitypackage"); - - if (string.IsNullOrEmpty(absolutePackagePath)) - return; - - var relativeExportPath = FileUtility.AbsolutePathToRelativePath(absolutePackagePath, ASToolsPreferences.Instance.EnableSymlinkSupport); - if (!_workflow.IsPathValid(relativeExportPath, out var error)) - { - EditorUtility.DisplayDialog("Invalid selection", error, "OK"); - return; - } - - HandleUnityPackageUploadPathSelection(relativeExportPath, true); - } - - private void HandleUnityPackageUploadPathSelection(string selectedPackagePath, bool serialize) - { - if (string.IsNullOrEmpty(selectedPackagePath)) - return; - - _workflow.SetPackagePath(selectedPackagePath, serialize); - SetPathSelectionTextField(selectedPackagePath); - } - - protected override void Deserialize() - { - HandleUnityPackageUploadPathSelection(_workflow.GetPackagePath(), false); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/UnityPackageWorkflowElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/UnityPackageWorkflowElement.cs.meta deleted file mode 100644 index cc30abb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Elements/UnityPackageWorkflowElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 7a0c8a79b7dba9e458ddc54eec30ea66 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views.meta deleted file mode 100644 index e5882f0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 7511d6ab930f33c469562bc3c1c2aab2 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/LoginView.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/LoginView.cs deleted file mode 100644 index 3039572..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/LoginView.cs +++ /dev/null @@ -1,284 +0,0 @@ -using AssetStoreTools.Api.Models; -using AssetStoreTools.Uploader.Services.Api; -using AssetStoreTools.Utility; -using System; -using UnityEditor; -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader.UI.Views -{ - internal class LoginView : VisualElement - { - // Data - private IAuthenticationService _authenticationService; - private double _cloudLoginRefreshTime = 1d; - private double _lastRefreshTime; - - // UI - private Button _cloudLoginButton; - private Label _cloudLoginLabel; - - private Box _errorBox; - private Label _errorLabel; - - private TextField _emailField; - private TextField _passwordField; - private Button _credentialsLoginButton; - - public event Action OnAuthenticated; - - public LoginView(IAuthenticationService authenticationService) - { - _authenticationService = authenticationService; - Create(); - } - - public void Create() - { - styleSheets.Add(StyleSelector.UploaderWindow.LoginViewStyle); - styleSheets.Add(StyleSelector.UploaderWindow.LoginViewTheme); - - CreateAssetStoreLogo(); - CreateCloudLogin(); - CreateErrorBox(); - CreateCredentialsLogin(); - } - - private void CreateAssetStoreLogo() - { - // Asset Store logo - Image assetStoreLogo = new Image { name = "AssetStoreLogo" }; - assetStoreLogo.AddToClassList("asset-store-logo"); - - Add(assetStoreLogo); - } - - private void CreateCloudLogin() - { - VisualElement cloudLogin = new VisualElement { name = "CloudLogin" }; - - _cloudLoginButton = new Button(LoginWithCloudToken) { name = "LoginButtonCloud" }; - _cloudLoginButton.AddToClassList("cloud-button-login"); - _cloudLoginButton.SetEnabled(false); - - _cloudLoginLabel = new Label { text = "Cloud login unavailable" }; - _cloudLoginLabel.AddToClassList("cloud-button-login-label"); - - Label orLabel = new Label { text = "or" }; - orLabel.AddToClassList("cloud-label-or"); - - _cloudLoginButton.Add(_cloudLoginLabel); - - cloudLogin.Add(_cloudLoginButton); - cloudLogin.Add(orLabel); - - UpdateCloudLoginButton(); - EditorApplication.update += UpdateCloudLoginButton; - Add(cloudLogin); - } - - private void CreateErrorBox() - { - _errorBox = new Box() { name = "LoginErrorBox" }; - _errorBox.AddToClassList("error-container"); - _errorBox.style.display = DisplayStyle.None; - - var errorImage = new Image(); - _errorBox.Add(errorImage); - - _errorLabel = new Label(); - _errorBox.Add(_errorLabel); - - Add(_errorBox); - } - - public void DisplayError(string message) - { - if (string.IsNullOrEmpty(message)) - return; - - _errorLabel.text = message; - Debug.LogError(message); - - _errorBox.style.display = DisplayStyle.Flex; - } - - private void ClearError() - { - _errorLabel.text = string.Empty; - _errorBox.style.display = DisplayStyle.None; - } - - private void CreateCredentialsLogin() - { - // Manual login - VisualElement manualLoginBox = new VisualElement { name = "ManualLoginBox" }; - manualLoginBox.AddToClassList("credentials-container"); - - // Email input box - VisualElement inputBoxEmail = new VisualElement(); - inputBoxEmail.AddToClassList("credentials-input-container"); - - Label emailTitle = new Label { text = "Email" }; - _emailField = new TextField(); - - inputBoxEmail.Add(emailTitle); - inputBoxEmail.Add(_emailField); - - manualLoginBox.Add(inputBoxEmail); - - // Password input box - VisualElement inputBoxPassword = new VisualElement(); - inputBoxPassword.AddToClassList("credentials-input-container"); - - Label passwordTitle = new Label { text = "Password" }; - _passwordField = new TextField { isPasswordField = true }; - - inputBoxPassword.Add(passwordTitle); - inputBoxPassword.Add(_passwordField); - - manualLoginBox.Add(inputBoxPassword); - - // Login button - _credentialsLoginButton = new Button(LoginWithCredentials) { name = "LoginButtonCredentials" }; - _credentialsLoginButton.AddToClassList("credentials-button-login"); - - Label loginDescriptionCredentials = new Label { text = "Login" }; - loginDescriptionCredentials.AddToClassList("credentials-button-login-label"); - - _credentialsLoginButton.Add(loginDescriptionCredentials); - - manualLoginBox.Add(_credentialsLoginButton); - - Add(manualLoginBox); - - // Credentials login helpers - VisualElement helperBox = new VisualElement { name = "HelperBox" }; - helperBox.AddToClassList("help-section-container"); - - Button createAccountButton = new Button { name = "CreateAccountButton", text = "Create Publisher ID" }; - Button forgotPasswordButton = new Button { name = "ForgotPasswordButton", text = "Reset Password" }; - - createAccountButton.AddToClassList("help-section-hyperlink-button"); - forgotPasswordButton.AddToClassList("help-section-hyperlink-button"); - - createAccountButton.clicked += () => Application.OpenURL(Constants.Uploader.AccountRegistrationUrl); - forgotPasswordButton.clicked += () => Application.OpenURL(Constants.Uploader.AccountForgottenPasswordUrl); - - helperBox.Add(createAccountButton); - helperBox.Add(forgotPasswordButton); - - Add(helperBox); - } - - public async void LoginWithSessionToken() - { - ASDebug.Log("Authenticating with session token..."); - ClearError(); - SetEnabled(false); - - var result = await _authenticationService.AuthenticateWithSessionToken(); - if (!result.Success) - { - // Session authentication fail does not display errors in the UI - ASDebug.Log("No existing session was found"); - SetEnabled(true); - return; - } - - OnLoginSuccess(result.User); - } - - private async void LoginWithCloudToken() - { - ASDebug.Log("Authenticating with cloud token..."); - ClearError(); - SetEnabled(false); - - var result = await _authenticationService.AuthenticateWithCloudToken(); - if (!result.Success) - { - OnLoginFail(result.Exception.Message); - return; - } - - OnLoginSuccess(result.User); - } - - private async void LoginWithCredentials() - { - ASDebug.Log("Authenticating with credentials..."); - ClearError(); - var isValid = IsLoginDataValid(_emailField.text, _passwordField.value); - SetEnabled(!isValid); - - if (!isValid) - return; - - var result = await _authenticationService.AuthenticateWithCredentials(_emailField.text, _passwordField.text); - if (result.Success) - OnLoginSuccess(result.User); - else - OnLoginFail(result.Exception.Message); - } - - private bool IsLoginDataValid(string email, string password) - { - if (string.IsNullOrEmpty(email)) - { - DisplayError("Email field cannot be empty."); - return false; - } - - if (string.IsNullOrEmpty(password)) - { - DisplayError("Password field cannot be empty."); - return false; - } - - return true; - } - - private void UpdateCloudLoginButton() - { - if (_cloudLoginLabel == null) - return; - - if (_lastRefreshTime + _cloudLoginRefreshTime > EditorApplication.timeSinceStartup) - return; - - _lastRefreshTime = EditorApplication.timeSinceStartup; - - // Cloud login - if (_authenticationService.CloudAuthenticationAvailable(out var username, out var _)) - { - _cloudLoginLabel.text = $"Login as {username}"; - _cloudLoginButton.SetEnabled(true); - } - else - { - _cloudLoginLabel.text = "Cloud login unavailable"; - _cloudLoginButton.SetEnabled(false); - } - } - - private void OnLoginSuccess(User user) - { - ASDebug.Log($"Successfully authenticated as {user.Username}\n{user}"); - - _emailField.value = string.Empty; - _passwordField.value = string.Empty; - - OnAuthenticated?.Invoke(user); - SetEnabled(true); - } - - private void OnLoginFail(string message) - { - ASDebug.LogError($"Authentication failed: {message}"); - DisplayError(message); - SetEnabled(true); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/LoginView.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/LoginView.cs.meta deleted file mode 100644 index 1d2ed9e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/LoginView.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: e20b8602a9bd8ca48a5689b3f32cdd90 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/PackageListView.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/PackageListView.cs deleted file mode 100644 index a980d66..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/PackageListView.cs +++ /dev/null @@ -1,249 +0,0 @@ -using AssetStoreTools.Uploader.Data; -using AssetStoreTools.Uploader.Services; -using AssetStoreTools.Uploader.Services.Api; -using AssetStoreTools.Uploader.UI.Elements; -using AssetStoreTools.Utility; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; -using UnityEditor; -using UnityEditor.SceneManagement; -using UnityEngine.SceneManagement; -using UnityEngine.UIElements; -using PackageModel = AssetStoreTools.Api.Models.Package; - -namespace AssetStoreTools.Uploader.UI.Views -{ - internal class PackageListView : VisualElement - { - // Data - private List _packages; - private readonly string[] _priorityGroupNames = { "draft", "published" }; - - private IPackageDownloadingService _packageDownloadingService; - private IPackageFactoryService _packageFactory; - - // UI - private LoadingSpinner _loadingSpinner; - private ScrollView _packageScrollView; - private PackageListToolbar _packageListToolbar; - - public event Action OnInitializeError; - - public PackageListView(IPackageDownloadingService packageDownloadingService, IPackageFactoryService elementFactory) - { - _packages = new List(); - _packageDownloadingService = packageDownloadingService; - _packageFactory = elementFactory; - - Create(); - EditorSceneManager.activeSceneChangedInEditMode += OnSceneChange; - } - - private void Create() - { - styleSheets.Add(StyleSelector.UploaderWindow.PackageListViewStyle); - styleSheets.Add(StyleSelector.UploaderWindow.PackageListViewTheme); - - AddToClassList("package-list-view"); - - CreateFilteringTools(); - CreateLoadingSpinner(); - CreateScrollView(); - - ShowPackagesView(); - } - - private void CreateScrollView() - { - _packageScrollView = new ScrollView(); - Add(_packageScrollView); - } - - private void CreateFilteringTools() - { - _packageListToolbar = new PackageListToolbar(); - Add(_packageListToolbar); - } - - private void CreateLoadingSpinner() - { - _loadingSpinner = new LoadingSpinner(); - Add(_loadingSpinner); - } - - private void InsertReadOnlyInfoBox(string infoText) - { - var groupHeader = new Box { name = "GroupReadOnlyInfoBox" }; - groupHeader.AddToClassList("package-group-info-box"); - - var infoImage = new Image(); - groupHeader.Add(infoImage); - - var infoLabel = new Label { text = infoText }; - groupHeader.Add(infoLabel); - - _packageScrollView.Add(groupHeader); - } - - public async Task LoadPackages(bool useCachedData) - { - _packages.Clear(); - _packageScrollView.Clear(); - _packageListToolbar.SetEnabled(false); - - if (!useCachedData) - { - _packageDownloadingService.ClearPackageData(); - } - - _loadingSpinner.Show(); - await Task.Delay(100); - - try - { - var response = await _packageDownloadingService.GetPackageData(); - - if (response.Cancelled) - { - ASDebug.Log("Package retrieval was cancelled"); - return; - } - - if (!response.Success) - { - ASDebug.LogError(response.Exception); - OnInitializeError?.Invoke(response.Exception); - return; - } - - var packageModels = response.Packages; - ASDebug.Log($"Found {packageModels.Count} packages"); - - if (packageModels.Count == 0) - { - InsertReadOnlyInfoBox("You do not have any packages yet. Please visit the Publishing Portal if you " + - "would like to create one."); - return; - } - - // Create package groups - _packages = CreatePackages(packageModels); - var packageGroups = CreatePackageGroups(_packages); - var packageGroupElements = CreatePackageGroupElements(packageGroups); - PopulatePackageList(packageGroupElements); - - // Setup filtering and thumbnails - SetupFilteringToolbar(packageGroups); - DownloadAndSetThumbnails(); - } - finally - { - _loadingSpinner.Hide(); - } - } - - private List CreatePackages(List packageModels) - { - return _packages = packageModels.Select(x => _packageFactory.CreatePackage(x)).ToList(); - } - - private List CreatePackageGroups(List packages) - { - var packageGroups = new List(); - var packagesByStatus = packages.GroupBy(x => x.Status).ToDictionary(x => x.Key, x => x.ToList()); - - foreach (var kvp in packagesByStatus) - { - var groupName = char.ToUpper(kvp.Key[0]) + kvp.Key.Substring(1); - var groupPackages = kvp.Value; - var packageGroup = _packageFactory.CreatePackageGroup(groupName, groupPackages); - packageGroups.Add(packageGroup); - } - - return packageGroups; - } - - private List CreatePackageGroupElements(List packageGroups) - { - var elements = new List(); - foreach (var packageGroup in packageGroups) - elements.Add(new PackageGroupElement(packageGroup, _packageFactory)); - - return elements; - } - - private void PopulatePackageList(List packageGroups) - { - // Draft group - var draftGroup = packageGroups.FirstOrDefault(x => x.Name.Equals("draft", StringComparison.OrdinalIgnoreCase)); - if (draftGroup != null) - { - draftGroup.Toggle(true); - _packageScrollView.Add(draftGroup); - } - - // Infobox will only be shown if: - // 1) There is more than 1 group OR - // 2) There is only 1 group, but it is not draft - var showInfoBox = packageGroups.Count > 1 - || packageGroups.Count == 1 && !packageGroups[0].Name.Equals("draft", StringComparison.OrdinalIgnoreCase); - - if (showInfoBox) - InsertReadOnlyInfoBox("Only packages with a 'Draft' status can be selected for uploading Assets"); - - // Priority groups - foreach (var priorityName in _priorityGroupNames) - { - var priorityGroup = packageGroups.FirstOrDefault(x => x.Name.Equals(priorityName, StringComparison.OrdinalIgnoreCase)); - if (priorityGroup == null || _packageScrollView.Contains(priorityGroup)) - continue; - - _packageScrollView.Add(priorityGroup); - } - - // The rest - foreach (var group in packageGroups) - { - if (!_packageScrollView.Contains(group)) - _packageScrollView.Add(group); - } - } - - private void SetupFilteringToolbar(List packageGroups) - { - _packageListToolbar.SetPackageGroups(packageGroups); - _packageListToolbar.Sort(PackageSorting.Name); - _packageListToolbar.SetEnabled(true); - } - - private void DownloadAndSetThumbnails() - { - foreach (var package in _packages) - { - DownloadAndSetThumbnail(package); - } - } - - private async void DownloadAndSetThumbnail(IPackage package) - { - var response = await _packageDownloadingService.GetPackageThumbnail(package); - if (!response.Success) - return; - - package.UpdateIcon(response.Thumbnail); - } - - private void ShowPackagesView() - { - _packageScrollView.style.display = DisplayStyle.Flex; - _packageListToolbar.style.display = DisplayStyle.Flex; - } - - private void OnSceneChange(Scene _, Scene __) - { - DownloadAndSetThumbnails(); - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/PackageListView.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/PackageListView.cs.meta deleted file mode 100644 index ccae9d2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Scripts/UI/Views/PackageListView.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 3c499c2d0a5e8fd4b9984184c59893e7 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles.meta deleted file mode 100644 index 6040ca4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: f9398c14296d30f479b9de5f3ec3b827 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView.meta deleted file mode 100644 index 03dac6e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 7564d91cabdce1344ba4a0fca25e13d5 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/Style.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/Style.uss deleted file mode 100644 index d97cb7a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/Style.uss +++ /dev/null @@ -1,134 +0,0 @@ -/* Logo */ - -.asset-store-logo { - width: 90%; - height: 32px; - - align-self: center; - - margin: 40px 0; - - -unity-background-scale-mode: scale-to-fit; -} - -/* Cloud Login */ - -.cloud-button-login { - align-self: center; - - width: 75%; -} - -.cloud-button-login-label { - -unity-text-align: middle-center; - white-space: normal; - - min-height: 24px; - padding-right: 4px; -} - -.cloud-label-or { - align-self: center; - - -unity-text-align: middle-center; - - margin: 10px 0; -} - -/* Error Section */ - -.error-container { - flex-direction: row; - flex-shrink: 0; - - align-self: center; - - min-width: 300px; - max-width: 300px; - - margin: 5px 0 5px 1px; -} - -.error-container > Image { - flex-direction: row; - - width: 32px; - height: 32px; - - margin: 5px 10px; -} - -.error-container > Label { - flex-grow: 1; - flex-shrink: 1; - - -unity-text-align: middle-left; - white-space: normal; - - margin-right: 5px; - padding: 2px 0; -} - -/* Credentials Login */ - -.credentials-container { - align-self: center; - - width: 75%; - - padding: 15px; -} - -.credentials-input-container { - align-self: center; - - width: 100%; - - margin: 5px 0; -} - -.credentials-input-container > Label { - -unity-text-align: upper-left; - - margin: 2px 0; -} - -.credentials-input-container > TextField { - height: 20px; - margin: 0 1px; -} - -.credentials-button-login { - align-self: center; - - width: 100%; - margin: 10px 0 15px 0; -} - -.credentials-button-login-label { - -unity-text-align: middle-center; - white-space: normal; - - min-height: 24px; - padding-right: 4px; -} - -/* Help Section */ - -.help-section-container { - flex-direction: row; - - justify-content: space-between; - align-self: center; - - width: 75%; - margin: 5px 0; -} - -.help-section-hyperlink-button { - margin: 0 10px; - padding: 0; - - flex-shrink: 1; - white-space: normal; -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/Style.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/Style.uss.meta deleted file mode 100644 index e15c190..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/Style.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 5e05fbdf7dd89a14985a87aa62a03a0e -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeDark.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeDark.uss deleted file mode 100644 index 39e3dfc..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeDark.uss +++ /dev/null @@ -1,44 +0,0 @@ -/* Logo */ - -.asset-store-logo { - background-image: url("../../Icons/publisher-portal-dark.png"); -} - -/* Cloud Login */ - -.cloud-label-or { - color: rgb(200, 200, 200); -} - -/* Error Section */ - -.error-container { - background-color: rgb(63, 63, 63); -} - -.error-container > Image { - --unity-image: resource("console.erroricon@2x"); -} - -/* Credentials Login */ - -.credentials-container { - background-color: rgb(63, 63, 63); -} - -/* Help Section */ - -.help-section-hyperlink-button { - color: rgb(68, 113, 229); - border-color: rgba(0, 0, 0, 0); - background-color: rgba(0, 0, 0, 0); -} - -.help-section-hyperlink-button:hover { - color: rgb(68, 133, 229); - cursor: link; -} - -.help-section-hyperlink-button:active { - color: rgb(68, 93, 229); -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeDark.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeDark.uss.meta deleted file mode 100644 index 525eb0e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeDark.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: bea9503736c358b4e99eac03c0db32b7 -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeLight.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeLight.uss deleted file mode 100644 index 993c2b8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeLight.uss +++ /dev/null @@ -1,44 +0,0 @@ -/* Logo */ - -.asset-store-logo { - background-image: url("../../Icons/publisher-portal-light.png"); -} - -/* Cloud Login */ - -.cloud-label-or { - color: rgb(28, 28, 28); -} - -/* Error Section */ - -.error-container { - background-color: rgb(212, 212, 212); -} - -.error-container > Image { - --unity-image: resource("console.erroricon@2x"); -} - -/* Credentials Login */ - -.credentials-container { - background-color: rgb(212, 212, 212); -} - -/* Help Section */ - -.help-section-hyperlink-button { - color: rgb(68, 113, 229); - border-color: rgba(0, 0, 0, 0); - background-color: rgba(0, 0, 0, 0); -} - -.help-section-hyperlink-button:hover { - color: rgb(68, 133, 229); - cursor: link; -} - -.help-section-hyperlink-button:active { - color: rgb(68, 93, 229); -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeLight.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeLight.uss.meta deleted file mode 100644 index 498f536..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/LoginView/ThemeLight.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 895ecc4cb6c82b144b8423996c89f7ef -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView.meta deleted file mode 100644 index f5446fd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 46d44b66f60dc484897f0afeee574dbe -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/Style.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/Style.uss deleted file mode 100644 index d36598c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/Style.uss +++ /dev/null @@ -1,485 +0,0 @@ -.package-list-view { - flex-grow: 1; -} - -/* Package List Toolbar */ - -.package-list-toolbar { - flex-direction: row; - flex-shrink: 0; - - justify-content: space-between; - - height: 24px; -} - -.package-search-field { - flex-grow: 1; - flex-shrink: 1; - align-items: center; - - margin: 1px; -} - -.package-search-field > #unity-search { - margin-top: 0; -} - -.package-search-field > * > .unity-base-field__input { - font-size: 12px; - - padding-left: 5px; -} - -.package-sort-menu { - flex-shrink: 0.001; - align-self: center; - - height: 21px; - - margin: 1px; - padding: 1px 6px; -} - -/* Loading Spinner */ - -.loading-spinner-box -{ - flex-grow: 1; - flex-shrink: 1; - - justify-content: center; -} - -.loading-spinner-image { - align-self: center; - - width: 16px; - height: 16px; -} - -/* Package Group */ - -.package-group-expander-box { - flex-direction: row; - flex-grow: 0; - flex-shrink: 0; - - align-items: center; - - min-height: 30px; - - margin: 10px 0 2px 0; - padding: 1px 5px; -} - -.package-group-expander -{ - align-self: center; - - width: 30px; - height: 30px; -} - -.package-group-label { - font-size: 14px; - -unity-font-style: bold; -} - -.package-group-content-box { - margin: 0; -} - -.package-group-separator { - height: 2px; - - margin: 5px 15px; - - display: none; -} - -.package-group-info-box { - flex-direction: row; - align-items: center; - font-size: 12px; - margin: 5px; - margin-top: 5px; -} - -.package-group-info-box > Image -{ - flex-direction: row; - flex-shrink: 0; - - width: 32px; - height: 32px; - - margin: 5px 10px; -} - -.package-group-info-box > Label -{ - flex-grow: 1; - flex-shrink: 1; - - -unity-text-align: middle-left; - white-space: normal; - - margin-right: 5px; -} - -/* Package Element */ - -.package-full-box { - flex-direction: column; - flex-shrink: 0; - flex-grow: 0; - - min-width: 280px; -} - -.package-foldout-box { - flex-direction: column; - margin: 0; -} - -.package-foldout-box-expanded { - padding-top: 3px; - top: -2px; -} - -.package-foldout-box-info { - flex-direction: row; - flex-grow: 0; - flex-shrink: 0; - - align-items: center; - justify-content: space-between; - - min-width: 200px; - min-height: 50px; - - margin: 2px; -} - -.package-expander-label-row { - flex-basis: 200px; - flex-direction: row; - flex-grow: 1; -} - -.package-expander { - align-self: center; - - width: 30px; - height: 30px; -} - -.package-image { - flex-shrink: 0; - - width: 48px; - height: 48px; - - margin: 0 5px; -} - -.package-label-info-box { - flex-direction: column; - flex-grow: 1; - flex-shrink: 1; - - align-self: center; -} - -.package-label { - flex-shrink: 1; - - align-self: stretch; - - -unity-text-align: middle-left; - -unity-font-style: bold; - white-space: normal; -} - -.package-info { - font-size: 11px; - -unity-text-align: middle-left; - white-space: normal; -} - -.package-open-in-browser-button { - flex-shrink: 0; - - width: 16px; - height: 16px; - - -unity-background-scale-mode: scale-to-fit; -} - -.package-header-progress-bar { - margin: 0 -6px -1px -6px; - padding: 0 0 2px 0; -} - -.package-header-progress-bar > * > .unity-progress-bar__background { - height: 5px; -} - -/* Package Content Element & its nested elements */ - -.package-content-element { - flex-grow: 1; - flex-shrink: 0; - - overflow: hidden; - - margin: -5px 0px 2px 0px; - padding: 5px 10px 5px 40px; -} - -.package-content-option-box { - flex-direction: row; - - margin-top: 10px; -} - -.package-content-option-label-help-row { - flex-direction: row; - flex-shrink: 0; - - align-self: flex-start; - align-items: center; - justify-content: flex-start; - - width: 115px; -} - -.package-content-option-label-help-row > Label { - -unity-text-align: middle-left; -} - -.package-content-option-label-help-row > Image { - height: 16px; - width: 16px; -} - -.package-content-option-dropdown { - flex-grow: 1; - flex-shrink: 1; - - align-self: stretch; - - margin-right: 0; - margin-left: 3px; -} - -.package-content-option-textfield { - flex-grow: 1; - flex-shrink: 1; - - align-self: stretch; -} - -.package-content-option-button { - margin-right: 0; -} - -.package-content-option-toggle { - flex-shrink: 1; -} - -.package-content-option-toggle > * { - flex-shrink: 1; -} - -.package-content-option-toggle * > .unity-label { - flex-shrink: 1; - overflow: hidden; - text-overflow: ellipsis; - margin-left: 5px; -} - -/* MutliToggleSelection Element */ - -.multi-toggle-box { - flex-grow: 1; - flex-direction: column; -} - -.multi-toggle-box-scrollview { - flex-grow: 1; - - height: 100px; - margin-left: 3px; -} - -.multi-toggle-box-scrollview > .unity-scroll-view__content-viewport -{ - margin-left: 1px; -} - -.multi-toggle-box-scrollview > * > .unity-scroll-view__content-container -{ - padding: 3px 0 5px 0; -} - -.multi-toggle-box-scrollview > * > .unity-scroll-view__vertical-scroller -{ - margin: -1px 0; -} - -.multi-toggle-box-empty-label { - flex-grow: 1; - - font-size: 11px; - -unity-text-align: middle-center; - white-space: normal; - - display: none; -} - -.multi-toggle-box-toolbar { - flex-direction: row; - margin: -1px 0 0 3px; -} - -.multi-toggle-box-toolbar-selecting-box { - flex-grow: 1; - flex-shrink: 1; - flex-direction: row; - - align-items: center; - justify-content: flex-end; - - margin-top: 1px; -} - -.multi-toggle-box-toolbar-selecting-box > Button { - flex-shrink: 1; - width: 75px; - margin-right: 0; -} - -.multi-toggle-box-toolbar-filtering-box { - flex-grow: 1; - flex-direction: row; - - align-items: center; - justify-content: flex-start; - - margin-top: 1px; - margin-left: 1px; -} - -.multi-toggle-box-toolbar-filtering-box > ToolbarMenu { - width: 100px; - margin: 0; -} - -.multi-toggle-box-toggle { - padding: 2px 0 0 5px; -} - -.multi-toggle-box-toggle > * > .unity-label { - margin-left: 5px; -} - -/* Validation Element */ - -.validation-result-box { - flex-direction: row; - - align-items: center; - - font-size: 12px; - - margin-top: 5px; -} - -.validation-result-box > Image { - flex-direction: row; - flex-shrink: 0; - - width: 32px; - height: 32px; - - margin: 5px 10px; -} - -.validation-result-box > Label { - flex-grow: 1; - flex-shrink: 1; - - -unity-text-align: middle-left; - white-space: normal; - - margin-right: 5px; -} - -.validation-result-box > Button { - margin-right: 10px; -} - -.validation-result-view-report-button-container { - flex-shrink: 0; - padding: 0 10px 0 10px; -} - -.validation-result-view-report-button { - margin: 0; - padding: 4px 0 4px 0; -} - -.validation-result-view-report-button:hover { - cursor: link; -} - -/* Uploading Element */ - -.uploading-box { - margin-top: 10px; -} - -.uploading-export-and-upload-container { - flex-direction: row; - flex-wrap: wrap; -} - -.uploading-export-button { - flex-basis: 110px; - flex-grow: 1; - height: 24px; - margin: 1px 2px 0 2px; -} - -.uploading-upload-button { - flex-basis: 110px; - flex-grow: 1; - height: 24px; - margin: 1px 2px 0 2px; -} - -.uploading-progress-container { - flex-direction: row; -} - -.uploading-progress-bar { - flex-grow: 1; - flex-shrink: 1; - - justify-content: center; - - padding: 0; - margin: 0 10px 0 0; -} - -.uploading-progress-bar > * > .unity-progress-bar__background { - height: 22px; -} - -.uploading-cancel-button { - width: 95px; - height: 24px; - margin: 0; -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/Style.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/Style.uss.meta deleted file mode 100644 index 9ac57e4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/Style.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 4b3b52dc166e3e24bb1ce4acd2592f3a -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeDark.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeDark.uss deleted file mode 100644 index a0ef9ed..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeDark.uss +++ /dev/null @@ -1,238 +0,0 @@ -/* Package List Toolbar */ - -.package-list-toolbar { - border-bottom-width: 1px; - border-color: rgb(33, 33, 33); - - background-color: rgb(68, 68, 68); -} - -.package-sort-menu { - color: rgb(238, 238, 238); - - border-width: 1px; - border-radius: 3px; - border-color: rgb(36, 36, 36); - - background-color: rgb(88, 88, 88); -} - -.package-sort-menu:hover { - background-color: rgb(103, 103, 103); -} - -.package-sort-menu:active { - background-color: rgb(73, 73, 73); -} - -/* Loading Spinner */ - -.loading-spinner-image { - --unity-image: resource("WaitSpin00"); -} - -/* Package Group */ - -.package-group-expander-box { - border-width: 0; - border-color: rgba(33, 33, 33, 0); - - background-color: rgba(68, 68, 68, 0); -} - -.package-group-expander { - color: rgb(104, 104, 104); -} - -.package-group-label { - color: rgb(255, 255, 255); -} - -.package-group-separator { - background-color: rgb(48, 48, 48); -} - -.package-group-info-box { - border-width: 1px; - border-color: rgb(33, 33, 33); -} - -.package-group-info-box > Image { - --unity-image: resource("console.infoicon@2x"); -} - -/* Package Element */ - -.package-foldout-box { - border-width: 0; - border-radius: 0; - background-color: rgb(56, 56, 56); -} - -.package-foldout-box:hover { - background-color: rgb(68, 68, 68); -} - -.package-foldout-box-draft:active { - background-color: rgb(48, 48, 48); -} - -.package-foldout-box-expanded { - background-color: rgb(68, 68, 68); -} - -.package-expander { - color: rgb(104, 104, 104); -} - -.package-image { - border-radius: 5px; - background-image: resource("Sprite Icon"); -} - -.package-label { - color: rgb(255, 255, 255); -} - -.package-info { - color: rgb(200, 200, 200); -} - -.package-open-in-browser-button { - border-width: 0; - border-radius: 0; - - background-color: rgba(0, 0, 0, 0); - background-image: url("../../Icons/open-in-browser.png"); - - -unity-background-image-tint-color: rgb(200, 200, 200); -} - -.package-open-in-browser-button:hover { - -unity-background-image-tint-color: rgb(255, 255, 255); -} - -.package-open-in-browser-button:active { - -unity-background-image-tint-color: rgb(155, 155, 155); -} - -.package-header-progress-bar > .unity-progress-bar__container > .unity-progress-bar__background { - border-width: 0; - background-color: rgba(0, 0, 0, 0); -} - -.package-header-progress-bar > .unity-progress-bar__container > .unity-progress-bar__background > .unity-progress-bar__progress { - background-image: none; - background-color: rgb(33, 150, 243); -} - -/* Package Content Element */ - -.package-content-element { - background-color: rgb(68, 68, 68); -} - -.package-content-option-label-help-row > Image { - --unity-image: resource("d__Help@2x"); -} - -.package-content-option-dropdown { - color: rgb(238, 238, 238); - - border-width: 1px; - border-radius: 3px; - border-color: rgb(36, 36, 36); - - background-color: rgb(88, 88, 88); -} - -.package-content-option-dropdown:hover { - background-color: rgb(103, 103, 103); -} - -/* MultiToggleSelection Element */ - -.multi-toggle-box-scrollview { - border-width: 1px; - border-color: rgb(33, 33, 33); - background-color: rgb(58, 58, 58); -} - -.multi-toggle-box-scrollview > * > .unity-scroll-view__vertical-scroller { - border-right-width: 0; -} - -.multi-toggle-box-empty-label { - color: rgb(200, 200, 200); -} - -.multi-toggle-box-toolbar { - border-width: 1px; - border-color: rgb(33, 33, 33); - background-color: rgb(58, 58, 58); -} - -.multi-toggle-box-toolbar-filtering-box > ToolbarMenu { - color: rgb(188, 188, 188); - - border-width: 1px; - border-radius: 3px; - border-color: rgb(36, 36, 36); - - background-color: rgb(88, 88, 88); -} - -/* Validation Element */ - -.validation-result-box { - border-width: 1px; - border-color: rgb(33, 33, 33); -} - -.validation-result-box > Image { - --unity-image: resource("console.infoicon@2x"); -} - -.validation-result-view-report-button { - color: rgb(68, 113, 229); - border-color: rgba(0, 0, 0, 0); - background-color: rgba(0, 0, 0, 0); -} - -.validation-result-view-report-button:hover { - color: rgb(68, 133, 229); -} - -.validation-result-view-report-button:active { - color: rgb(68, 93, 229); -} - -/* Uploading Element */ - -.uploading-export-button { - color: rgb(220, 220, 220); - border-width: 1px; - border-color: rgb(33, 33, 33); -} - -.uploading-upload-button { - color: rgb(220, 220, 220); - border-width: 1px; - border-color: rgb(33, 33, 33); -} - -.uploading-progress-bar > .unity-progress-bar__container > .unity-progress-bar__background { - border-width: 0; - border-radius: 2px; -} - -.uploading-progress-bar > .unity-progress-bar__container > .unity-progress-bar__background > .unity-progress-bar__progress { - background-image: none; - background-color: rgb(33, 150, 243); -} - -.uploading-cancel-button { - color: rgb(220, 220, 220); - border-width: 1px; - border-color: rgb(33, 33, 33); -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeDark.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeDark.uss.meta deleted file mode 100644 index 6e8e7be..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeDark.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 2096f0ee5b05ec643b409ded0d725eb3 -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeLight.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeLight.uss deleted file mode 100644 index d375fca..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeLight.uss +++ /dev/null @@ -1,238 +0,0 @@ -/* Package List Toolbar */ - -.package-list-toolbar { - border-bottom-width: 1px; - border-color: rgb(127, 127, 127); - - background-color: rgb(203, 203, 203); -} - -.package-sort-menu { - color: rgb(9, 9, 9); - - border-width: 1px; - border-radius: 3px; - border-color: rgb(178, 178, 178); - - background-color: rgb(228, 228, 228); -} - -.package-sort-menu:hover { - background-color: rgb(236, 236, 236); -} - -.package-sort-menu:active { - background-color: rgb(220, 220, 220); -} - -/* Loading Spinner */ - -.loading-spinner-image { - --unity-image: resource("WaitSpin00"); -} - -/* Package Group */ - -.package-group-expander-box { - border-width: 0; - border-color: rgba(0, 0, 0, 0); - - background-color: rgba(0, 0, 0, 0); -} - -.package-group-expander { - color: rgb(77, 77, 77); -} - -.package-group-label { - color: rgb(0, 0, 0); -} - -.package-group-separator -{ - background-color: rgb(48, 48, 48); -} - -.package-group-info-box -{ - border-width: 1px; - border-color: rgb(33, 33, 33); -} - -.package-group-info-box > Image -{ - --unity-image: resource("console.infoicon@2x"); -} - -/* Package Element */ - -.package-foldout-box { - border-width: 0; - border-radius: 0; - background-color: rgb(198, 198, 198); -} - -.package-foldout-box:hover { - background-color: rgb(212, 212, 212); -} - -.package-foldout-box-draft:active { - background-color: rgb(180, 180, 180); -} - -.package-foldout-box-expanded { - background-color: rgb(212, 212, 212); -} - -.package-expander { - color: rgb(77, 77, 77); -} - -.package-image { - border-radius: 5px; - background-image: resource("Sprite Icon"); -} - -.package-label { - color: rgb(0, 0, 0); -} - -.package-info { - color: rgb(48, 48, 48); -} - -.package-open-in-browser-button { - border-width: 0; - border-radius: 0; - - background-color: rgba(0, 0, 0, 0); - background-image: url("../../Icons/open-in-browser.png"); - - -unity-background-image-tint-color: rgb(150, 150, 150); -} - -.package-open-in-browser-button:hover { - -unity-background-image-tint-color: rgb(100, 100, 100); -} - -.package-open-in-browser-button:active { - -unity-background-image-tint-color: rgb(50, 50, 50); -} - -.package-header-progress-bar > .unity-progress-bar__container > .unity-progress-bar__background { - border-width: 0; - background-color: rgba(0, 0, 0, 0); -} - -.package-header-progress-bar > .unity-progress-bar__container > .unity-progress-bar__background > .unity-progress-bar__progress { - background-image: none; - background-color: rgb(108, 157, 243); -} - -/* Package Content Element */ - -.package-content-element { - background-color: rgb(212, 212, 212); -} - -.package-content-option-label-help-row > Image { - --unity-image: resource("_Help@2x"); -} - -.package-content-option-dropdown { - color: rgb(9, 9, 9); - - border-width: 1px; - border-radius: 3px; - border-color: rgb(178, 178, 178); - - background-color: rgb(228, 228, 228); -} - -.package-content-option-dropdown:hover { - background-color: rgb(236, 236, 236); -} - -/* MultiToggleSelection Element */ - -.multi-toggle-box-scrollview { - border-width: 1px; - border-color: rgb(33, 33, 33); - background-color: rgb(200, 200, 200); -} - -.multi-toggle-box-scrollview > * > .unity-scroll-view__vertical-scroller { - border-right-width: 0; -} - -.multi-toggle-box-empty-label { - color: rgb(0, 0, 0); -} - -.multi-toggle-box-toolbar { - border-width: 1px; - border-color: rgb(33, 33, 33); - background-color: rgb(200, 200, 200); -} - -.multi-toggle-box-toolbar-filtering-box > ToolbarMenu { - color: rgb(9, 9, 9); - - border-width: 1px; - border-radius: 3px; - border-color: rgb(178, 178, 178); - - background-color: rgb(228, 228, 228); -} - -/* Validation Element */ - -.validation-result-box { - border-width: 1px; - border-color: rgb(33, 33, 33); -} - -.validation-result-box > Image { - --unity-image: resource("console.infoicon@2x"); -} - -.validation-result-view-report-button { - color: rgb(68, 113, 229); - border-color: rgba(0, 0, 0, 0); - background-color: rgba(0, 0, 0, 0); -} - -.validation-result-view-report-button:hover { - color: rgb(68, 133, 229); -} - -.validation-result-view-report-button:active { - color: rgb(68, 93, 229); -} - -/* Uploading Element */ - -.uploading-export-button { - border-width: 1px; - border-color: rgb(33, 33, 33); -} - -.uploading-upload-button { - border-width: 1px; - border-color: rgb(33, 33, 33); -} - -.uploading-progress-bar > .unity-progress-bar__container > .unity-progress-bar__background { - border-width: 0; - border-radius: 2px; -} - -.uploading-progress-bar > .unity-progress-bar__container > .unity-progress-bar__background > .unity-progress-bar__progress { - background-image: none; - background-color: rgb(108, 157, 243); -} - -.uploading-cancel-button { - border-width: 1px; - border-color: rgb(33, 33, 33); -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeLight.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeLight.uss.meta deleted file mode 100644 index 1cc032a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/PackageListView/ThemeLight.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 9b79808cdce73b949abc32c5fada1bda -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/Style.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/Style.uss deleted file mode 100644 index 6a69261..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/Style.uss +++ /dev/null @@ -1,74 +0,0 @@ -.uploader-window-root { - flex-grow: 1; -} - -.uploader-window-root-scrollview { - flex-grow: 1; -} - -.uploader-window-root-scrollview > * > .unity-scroll-view__content-container { - flex-grow: 1; -} - -.uploader-window-root-scrollview > * > .unity-scroll-view__content-viewport { - flex-shrink: 1; -} - -.uploader-window-root-scrollview > * > * > .unity-scroll-view__content-container { - flex-grow: 1; - flex-shrink: 1; -} - -.account-toolbar { - flex-direction: row; - flex-shrink: 0; - - justify-content: space-between; - margin: 0; -} - -.account-toolbar-left-side-container { - flex-grow: 1; - flex-shrink: 0; - flex-basis: 0px; - overflow: hidden; - min-width: 16px; - align-self: center; - flex-direction: row; - margin: 3px 0px 3px 1px; -} - -.account-toolbar-right-side-container { - flex-shrink: 1; - flex-grow: 0; - flex-wrap: wrap; - align-self: center; - flex-direction: row; - margin: 0; -} - -.account-toolbar-user-image { - width: 16px; - height: 16px; - flex-shrink: 0; - margin-right: 1px; -} - -.account-toolbar-email-label { - flex-shrink: 1; - overflow: hidden; - text-overflow: ellipsis; - -unity-font-style: bold; -} - -.account-toolbar-button-refresh { - flex-grow: 1; - min-width: 50px; - margin-right: 1px; -} - -.account-toolbar-button-logout { - flex-grow: 1; - min-width: 50px; - margin-right: 1px; -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/Style.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/Style.uss.meta deleted file mode 100644 index 1a2d462..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/Style.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 6f0343bfa66bbb344bee68a23d24cca8 -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeDark.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeDark.uss deleted file mode 100644 index 7f836d4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeDark.uss +++ /dev/null @@ -1,9 +0,0 @@ -.account-toolbar { - background-color: rgb(68, 68, 68); - border-color: rgb(33, 33, 33); - border-top-width: 1px; -} - -.account-toolbar-user-image { - background-image: url("../Icons/account-dark.png"); -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeDark.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeDark.uss.meta deleted file mode 100644 index 2ebe886..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeDark.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 26d328c2ffac2ff44af266e9c632f2ab -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeLight.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeLight.uss deleted file mode 100644 index 16e3de4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeLight.uss +++ /dev/null @@ -1,9 +0,0 @@ -.account-toolbar { - background-color: rgb(203, 203, 203); - border-color: rgb(127, 127, 127); - border-top-width: 1px; -} - -.account-toolbar-user-image { - background-image: url("../Icons/account-light.png"); -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeLight.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeLight.uss.meta deleted file mode 100644 index 03e9d7c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/Styles/ThemeLight.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a994594cc493b7346b4d4a71d39908dc -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/UploaderWindow.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/UploaderWindow.cs deleted file mode 100644 index f9fffa9..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/UploaderWindow.cs +++ /dev/null @@ -1,232 +0,0 @@ -using AssetStoreTools.Api.Models; -using AssetStoreTools.Uploader.Services; -using AssetStoreTools.Uploader.Services.Analytics; -using AssetStoreTools.Uploader.Services.Api; -using AssetStoreTools.Uploader.UI.Elements; -using AssetStoreTools.Uploader.UI.Views; -using AssetStoreTools.Utility; -using System; -using System.Collections.Generic; -using System.Threading.Tasks; -using UnityEditor; -using UnityEditor.UIElements; -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Uploader -{ - internal class UploaderWindow : AssetStoreToolsWindow - { - private const string DebugPhrase = "debug"; - - // Services - private ICachingService _cachingService; - private IAuthenticationService _authenticationService; - private IPackageDownloadingService _packageDownloadingService; - private IPackageUploadingService _packageUploadingService; - private IAnalyticsService _analyticsService; - private IPackageFactoryService _packageFactoryService; - - // Data - private bool _isQuitting = false; - - // UI - private VisualElement _uploaderWindowRoot; - private ScrollView _rootScrollView; - - private LoginView _loginView; - private PackageListView _packageListView; - private AccountToolbar _accountToolbar; - - protected override string WindowTitle => "Asset Store Uploader"; - - protected override void Init() - { - RegisterServices(); - SetupWindow(); - } - - private void RegisterServices() - { - var uploaderServiceProvider = UploaderServiceProvider.Instance; - _analyticsService = uploaderServiceProvider.GetService(); - _cachingService = uploaderServiceProvider.GetService(); - _authenticationService = uploaderServiceProvider.GetService(); - _packageDownloadingService = uploaderServiceProvider.GetService(); - _packageUploadingService = uploaderServiceProvider.GetService(); - _packageFactoryService = uploaderServiceProvider.GetService(); - } - - private void SetupWindow() - { - minSize = new Vector2(400, 430); - this.SetAntiAliasing(4); - rootVisualElement.styleSheets.Add(StyleSelector.UploaderWindow.UploaderWindowStyle); - rootVisualElement.styleSheets.Add(StyleSelector.UploaderWindow.UploaderWindowTheme); - - if (_cachingService.GetCachedUploaderWindow(out _uploaderWindowRoot)) - { - rootVisualElement.Add(_uploaderWindowRoot); - return; - } - - _uploaderWindowRoot = new VisualElement(); - _uploaderWindowRoot.AddToClassList("uploader-window-root"); - rootVisualElement.Add(_uploaderWindowRoot); - - _rootScrollView = new ScrollView(); - _rootScrollView.AddToClassList("uploader-window-root-scrollview"); - _uploaderWindowRoot.Add(_rootScrollView); - - CreateLoginView(); - CreatePackageListView(); - CreateAccountToolbar(); - EditorApplication.wantsToQuit += OnWantsToQuit; - - _cachingService.CacheUploaderWindow(_uploaderWindowRoot); - - PerformAuthentication(); - } - - private void CreateLoginView() - { - _loginView = new LoginView(_authenticationService); - _loginView.OnAuthenticated += OnAuthenticationSuccess; - _rootScrollView.Add(_loginView); - } - - private void CreatePackageListView() - { - _packageListView = new PackageListView(_packageDownloadingService, _packageFactoryService); - _packageListView.OnInitializeError += PackageViewInitializationError; - _rootScrollView.Add(_packageListView); - } - - private void CreateAccountToolbar() - { - _accountToolbar = new AccountToolbar(); - _accountToolbar.OnRefresh += RefreshPackages; - _accountToolbar.OnLogout += LogOut; - _uploaderWindowRoot.Add(_accountToolbar); - } - - private void PerformAuthentication() - { - ShowAuthenticationView(); - _loginView.LoginWithSessionToken(); - } - - private async void OnAuthenticationSuccess(User user) - { - _accountToolbar.SetUser(user); - _accountToolbar.DisableButtons(); - - ShowAccountPackageView(); - await _packageListView.LoadPackages(true); - - _accountToolbar.EnableButtons(); - } - - private async Task RefreshPackages() - { - _packageUploadingService.StopAllUploadinng(); - _packageDownloadingService.StopDownloading(); - - await _packageListView.LoadPackages(false); - } - - private void LogOut() - { - _packageUploadingService.StopAllUploadinng(); - _packageDownloadingService.StopDownloading(); - - _authenticationService.Deauthenticate(); - _packageDownloadingService.ClearPackageData(); - - _accountToolbar.SetUser(null); - ShowAuthenticationView(); - } - - private void PackageViewInitializationError(Exception e) - { - _loginView.DisplayError(e.Message); - LogOut(); - } - - private void ShowAuthenticationView() - { - HideElement(_accountToolbar); - HideElement(_packageListView); - ShowElement(_loginView); - } - - private void ShowAccountPackageView() - { - HideElement(_loginView); - ShowElement(_accountToolbar); - ShowElement(_packageListView); - } - - private void ShowElement(params VisualElement[] elements) - { - foreach (var e in elements) - e.style.display = DisplayStyle.Flex; - } - - private void HideElement(params VisualElement[] elements) - { - foreach (var e in elements) - e.style.display = DisplayStyle.None; - } - - private void OnDestroy() - { - if (!_isQuitting && _packageUploadingService.IsUploading) - { - EditorUtility.DisplayDialog("Notice", "Assets are still being uploaded to the Asset Store. " + - "If you wish to check on the progress, please re-open the Asset Store Uploader window", "OK"); - } - } - - private bool OnWantsToQuit() - { - if (!_packageUploadingService.IsUploading) - return true; - - _isQuitting = EditorUtility.DisplayDialog("Notice", "Assets are still being uploaded to the Asset Store. " + - "Would you still like to close Unity Editor?", "Yes", "No"); - - return _isQuitting; - } - - #region Debug Utility - - private readonly List _debugBuffer = new List(); - - private void OnGUI() - { - CheckForDebugMode(); - } - - private void CheckForDebugMode() - { - Event e = Event.current; - - if (e.type != EventType.KeyDown || e.keyCode == KeyCode.None) - return; - - _debugBuffer.Add(e.keyCode.ToString().ToLower()[0]); - if (_debugBuffer.Count > DebugPhrase.Length) - _debugBuffer.RemoveAt(0); - - if (string.Join(string.Empty, _debugBuffer.ToArray()) != DebugPhrase) - return; - - ASDebug.DebugModeEnabled = !ASDebug.DebugModeEnabled; - ASDebug.Log($"DEBUG MODE ENABLED: {ASDebug.DebugModeEnabled}"); - _debugBuffer.Clear(); - } - - #endregion - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/UploaderWindow.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/UploaderWindow.cs.meta deleted file mode 100644 index ef78266..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Uploader/UploaderWindow.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 7b5319699cc84194a9a768ad33b86c21 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility.meta deleted file mode 100644 index 9a2bdff..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 3dfd03e520c145b45a32c7e2915fe3cb -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASDebug.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASDebug.cs deleted file mode 100644 index 16fc4c8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASDebug.cs +++ /dev/null @@ -1,65 +0,0 @@ -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Utility -{ - internal static class ASDebug - { - private enum LogType - { - Info, - Warning, - Error - } - - private static string FormatInfo(object message) => $"[AST Info] {message}"; - private static string FormatWarning(object message) => $"[AST Warning] {message}"; - private static string FormatError(object message) => $"[AST Error] {message}"; - - - private static bool s_debugModeEnabled = EditorPrefs.GetBool(Constants.Debug.DebugModeKey); - - public static bool DebugModeEnabled - { - get => s_debugModeEnabled; - set { s_debugModeEnabled = value; EditorPrefs.SetBool(Constants.Debug.DebugModeKey, value); } - } - - public static void Log(object message) - { - LogMessage(message, LogType.Info); - } - - public static void LogWarning(object message) - { - LogMessage(message, LogType.Warning); - } - - public static void LogError(object message) - { - LogMessage(message, LogType.Error); - } - - private static void LogMessage(object message, LogType type) - { - if (!DebugModeEnabled) - return; - - switch (type) - { - case LogType.Info: - Debug.Log(FormatInfo(message)); - break; - case LogType.Warning: - Debug.LogWarning(FormatWarning(message)); - break; - case LogType.Error: - Debug.LogError(FormatError(message)); - break; - default: - Debug.Log(message); - break; - } - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASDebug.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASDebug.cs.meta deleted file mode 100644 index 2f4aab7..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASDebug.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 478caa497d99100429a0509fa487bfe4 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsPreferences.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsPreferences.cs deleted file mode 100644 index 73ad2bd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsPreferences.cs +++ /dev/null @@ -1,134 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Reflection; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Utility -{ - internal class ASToolsPreferences - { - private static ASToolsPreferences s_instance; - public static ASToolsPreferences Instance => s_instance ?? (s_instance = new ASToolsPreferences()); - - public static event Action OnSettingsChange; - - private ASToolsPreferences() - { - Load(); - } - - private void Load() - { - CheckForUpdates = PlayerPrefs.GetInt("AST_CheckForUpdates", 1) == 1; - LegacyVersionCheck = PlayerPrefs.GetInt("AST_LegacyVersionCheck", 1) == 1; - UploadVersionCheck = PlayerPrefs.GetInt("AST_UploadVersionCheck", 1) == 1; - DisplayHiddenMetaDialog = PlayerPrefs.GetInt("AST_HiddenFolderMetaCheck", 1) == 1; - EnableSymlinkSupport = PlayerPrefs.GetInt("AST_EnableSymlinkSupport", 0) == 1; - UseLegacyExporting = PlayerPrefs.GetInt("AST_UseLegacyExporting", 0) == 1; - } - - public void Save(bool triggerSettingsChange = false) - { - PlayerPrefs.SetInt("AST_CheckForUpdates", CheckForUpdates ? 1 : 0); - PlayerPrefs.SetInt("AST_LegacyVersionCheck", LegacyVersionCheck ? 1 : 0); - PlayerPrefs.SetInt("AST_UploadVersionCheck", UploadVersionCheck ? 1 : 0); - PlayerPrefs.SetInt("AST_HiddenFolderMetaCheck", DisplayHiddenMetaDialog ? 1 : 0); - PlayerPrefs.SetInt("AST_EnableSymlinkSupport", EnableSymlinkSupport ? 1 : 0); - PlayerPrefs.SetInt("AST_UseLegacyExporting", UseLegacyExporting ? 1 : 0); - PlayerPrefs.Save(); - - if (triggerSettingsChange) - OnSettingsChange?.Invoke(); - } - - /// - /// Periodically check if an update for the Asset Store Publishing Tools is available - /// - public bool CheckForUpdates; - - /// - /// Check if legacy Asset Store Tools are in the Project - /// - public bool LegacyVersionCheck; - - /// - /// Enables a DisplayDialog when hidden folders are found to be missing meta files - /// - public bool DisplayHiddenMetaDialog; - - /// - /// Check if the package has been uploaded from a correct Unity version at least once - /// - public bool UploadVersionCheck; - - /// - /// Enables Junction symlink support - /// - public bool EnableSymlinkSupport; - - /// - /// Enables legacy exporting for Folder Upload workflow - /// - public bool UseLegacyExporting; - } - - internal class ASToolsPreferencesProvider : SettingsProvider - { - private const string SettingsPath = "Project/Asset Store Tools"; - - private class Styles - { - public static readonly GUIContent CheckForUpdatesLabel = EditorGUIUtility.TrTextContent("Check for Updates", "Periodically check if an update for the Asset Store Publishing Tools is available."); - public static readonly GUIContent LegacyVersionCheckLabel = EditorGUIUtility.TrTextContent("Legacy ASTools Check", "Enable Legacy Asset Store Tools version checking."); - public static readonly GUIContent UploadVersionCheckLabel = EditorGUIUtility.TrTextContent("Upload Version Check", "Check if the package has been uploader from a correct Unity version at least once."); - public static readonly GUIContent DisplayHiddenMetaDialogLabel = EditorGUIUtility.TrTextContent("Display Hidden Folder Meta Dialog", "Show a DisplayDialog when hidden folders are found to be missing meta files.\nNote: this only affects hidden folders ending with a '~' character"); - public static readonly GUIContent EnableSymlinkSupportLabel = EditorGUIUtility.TrTextContent("Enable Symlink Support", "Enable Junction Symlink support. Note: folder selection validation will take longer."); - public static readonly GUIContent UseLegacyExportingLabel = EditorGUIUtility.TrTextContent("Use Legacy Exporting", "Enabling this option uses native Unity methods when exporting packages for the Folder Upload workflow.\nNote: individual package dependency selection when choosing to 'Include Package Manifest' is unavailable when this option is enabled."); - public static readonly GUIContent UseCustomPreviewsLabel = EditorGUIUtility.TrTextContent("Enable High Quality Previews (experimental)", "Override native asset preview retrieval with higher-quality preview generation"); - } - - public static void OpenSettings() - { - SettingsService.OpenProjectSettings(SettingsPath); - } - - private ASToolsPreferencesProvider(string path, SettingsScope scopes, IEnumerable keywords = null) - : base(path, scopes, keywords) { } - - public override void OnGUI(string searchContext) - { - var preferences = ASToolsPreferences.Instance; - - EditorGUI.BeginChangeCheck(); - using (CreateSettingsWindowGUIScope()) - { - preferences.CheckForUpdates = EditorGUILayout.Toggle(Styles.CheckForUpdatesLabel, preferences.CheckForUpdates); - preferences.LegacyVersionCheck = EditorGUILayout.Toggle(Styles.LegacyVersionCheckLabel, preferences.LegacyVersionCheck); - preferences.UploadVersionCheck = EditorGUILayout.Toggle(Styles.UploadVersionCheckLabel, preferences.UploadVersionCheck); - preferences.DisplayHiddenMetaDialog = EditorGUILayout.Toggle(Styles.DisplayHiddenMetaDialogLabel, preferences.DisplayHiddenMetaDialog); - preferences.EnableSymlinkSupport = EditorGUILayout.Toggle(Styles.EnableSymlinkSupportLabel, preferences.EnableSymlinkSupport); - preferences.UseLegacyExporting = EditorGUILayout.Toggle(Styles.UseLegacyExportingLabel, preferences.UseLegacyExporting); - } - - if (EditorGUI.EndChangeCheck()) - { - ASToolsPreferences.Instance.Save(true); - } - } - - [SettingsProvider] - public static SettingsProvider CreateAssetStoreToolsSettingProvider() - { - var provider = new ASToolsPreferencesProvider(SettingsPath, SettingsScope.Project, GetSearchKeywordsFromGUIContentProperties()); - return provider; - } - - private IDisposable CreateSettingsWindowGUIScope() - { - var unityEditorAssembly = Assembly.GetAssembly(typeof(EditorWindow)); - var type = unityEditorAssembly.GetType("UnityEditor.SettingsWindow+GUIScope"); - return Activator.CreateInstance(type) as IDisposable; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsPreferences.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsPreferences.cs.meta deleted file mode 100644 index 56807b0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsPreferences.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: b75179c8d22a35b42a543d6fa7857ce0 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsUpdater.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsUpdater.cs deleted file mode 100644 index 698b974..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsUpdater.cs +++ /dev/null @@ -1,250 +0,0 @@ -using AssetStoreTools.Api; -using System; -using System.Linq; -using System.Threading.Tasks; -using UnityEditor; -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Utility -{ - [InitializeOnLoad] - internal class ASToolsUpdater : AssetStoreToolsWindow - { - protected override string WindowTitle => "Asset Store Tools Update Check"; - - private static IAssetStoreApi _api; - - private VisualElement _loadingContainer; - private VisualElement _versionInfoContainer; - - private Image _loadingImage; - private double _lastTimeSinceStartup; - private double _timeSinceLoadingImageChange; - private int _loadingImageIndex; - - private static bool _updateCheckPerformed - { - get - { - return SessionState.GetBool("AST_UpdateChecked", false); - } - set - { - SessionState.SetBool("AST_UpdateChecked", value); - } - } - - static ASToolsUpdater() - { - _api = new AssetStoreApi(new AssetStoreClient()); - // Retrieving cached SessionState/PlayerPrefs values is not allowed from an instance field initializer - EditorApplication.update += CheckForUpdatesAfterEditorUpdate; - } - - private static async void CheckForUpdatesAfterEditorUpdate() - { - EditorApplication.update -= CheckForUpdatesAfterEditorUpdate; - - if (!ShouldCheckForUpdates()) - return; - - await CheckForUpdates((success, currentVersion, latestVersion) => - { - if (success && currentVersion < latestVersion) - { - AssetStoreTools.OpenUpdateChecker(); - } - }); - } - - private static bool ShouldCheckForUpdates() - { - if (!ASToolsPreferences.Instance.CheckForUpdates) - return false; - - return _updateCheckPerformed == false; - } - - private static async Task CheckForUpdates(Action OnUpdatesChecked) - { - _updateCheckPerformed = true; - var latestVersionResult = await _api.GetLatestAssetStoreToolsVersion(); - if (!latestVersionResult.Success) - { - OnUpdatesChecked?.Invoke(false, null, null); - return; - } - - Version currentVersion = null; - Version latestVersion = null; - - try - { - var latestVersionStr = latestVersionResult.Version; - var currentVersionStr = PackageUtility.GetAllPackages().FirstOrDefault(x => x.name == "com.unity.asset-store-tools").version; - - currentVersion = new Version(currentVersionStr); - latestVersion = new Version(latestVersionStr); - } - catch - { - OnUpdatesChecked?.Invoke(false, null, null); - } - - OnUpdatesChecked?.Invoke(true, currentVersion, latestVersion); - } - - protected override void Init() - { - rootVisualElement.styleSheets.Add(StyleSelector.UpdaterWindow.UpdaterWindowStyle); - rootVisualElement.styleSheets.Add(StyleSelector.UpdaterWindow.UpdaterWindowTheme); - - SetupLoadingSpinner(); - _ = CheckForUpdates(OnVersionsRetrieved); - } - - private void OnVersionsRetrieved(bool success, Version currentVersion, Version latestVersion) - { - if (_loadingContainer != null) - _loadingContainer.style.display = DisplayStyle.None; - - if (success) - { - SetupVersionInfo(currentVersion, latestVersion); - } - else - { - SetupFailInfo(); - } - } - - private void SetupLoadingSpinner() - { - _loadingContainer = new VisualElement(); - _loadingContainer.AddToClassList("updater-loading-container"); - _loadingImage = new Image(); - EditorApplication.update += LoadingSpinLoop; - - _loadingContainer.Add(_loadingImage); - rootVisualElement.Add(_loadingContainer); - } - - private void SetupVersionInfo(Version currentVersion, Version latestVersion) - { - _versionInfoContainer = new VisualElement(); - _versionInfoContainer.AddToClassList("updater-info-container"); - - AddDescriptionLabels(currentVersion, latestVersion); - AddUpdateButtons(currentVersion, latestVersion); - AddCheckForUpdatesToggle(); - - rootVisualElement.Add(_versionInfoContainer); - } - - private void AddDescriptionLabels(Version currentVersion, Version latestVersion) - { - var descriptionText = currentVersion < latestVersion ? - "An update to the Asset Store Publishing Tools is available. Updating to the latest version is highly recommended." : - "Asset Store Publishing Tools are up to date!"; - - var labelContainer = new VisualElement(); - labelContainer.AddToClassList("updater-info-container-labels"); - var descriptionLabel = new Label(descriptionText); - descriptionLabel.AddToClassList("updater-info-container-labels-description"); - - var currentVersionRow = new VisualElement(); - currentVersionRow.AddToClassList("updater-info-container-labels-row"); - var latestVersionRow = new VisualElement(); - latestVersionRow.AddToClassList("updater-info-container-labels-row"); - - var currentVersionLabel = new Label("Current version:"); - currentVersionLabel.AddToClassList("updater-info-container-labels-row-identifier"); - var latestVersionLabel = new Label("Latest version:"); - latestVersionLabel.AddToClassList("updater-info-container-labels-row-identifier"); - - var currentVersionLabelValue = new Label(currentVersion.ToString()); - var latestVersionLabelValue = new Label(latestVersion.ToString()); - - currentVersionRow.Add(currentVersionLabel); - currentVersionRow.Add(currentVersionLabelValue); - latestVersionRow.Add(latestVersionLabel); - latestVersionRow.Add(latestVersionLabelValue); - - labelContainer.Add(descriptionLabel); - labelContainer.Add(currentVersionRow); - labelContainer.Add(latestVersionRow); - - _versionInfoContainer.Add(labelContainer); - } - - private void AddUpdateButtons(Version currentVersion, Version latestVersion) - { - if (currentVersion >= latestVersion) - return; - - var buttonContainer = new VisualElement(); - buttonContainer.AddToClassList("updater-info-container-buttons"); - var latestVersionButton = new Button(() => Application.OpenURL(Constants.Updater.AssetStoreToolsUrl)) { text = "Get the latest version" }; - var skipVersionButton = new Button(Close) { text = "Skip for now" }; - - buttonContainer.Add(latestVersionButton); - buttonContainer.Add(skipVersionButton); - - _versionInfoContainer.Add(buttonContainer); - } - - private void AddCheckForUpdatesToggle() - { - var toggleContainer = new VisualElement(); - toggleContainer.AddToClassList("updater-info-container-toggle"); - var checkForUpdatesToggle = new Toggle() { text = "Check for Updates", value = ASToolsPreferences.Instance.CheckForUpdates }; - checkForUpdatesToggle.RegisterValueChangedCallback(OnCheckForUpdatesToggleChanged); - - toggleContainer.Add(checkForUpdatesToggle); - _versionInfoContainer.Add(toggleContainer); - } - - private void OnCheckForUpdatesToggleChanged(ChangeEvent evt) - { - ASToolsPreferences.Instance.CheckForUpdates = evt.newValue; - ASToolsPreferences.Instance.Save(); - } - - private void SetupFailInfo() - { - var failContainer = new VisualElement(); - failContainer.AddToClassList("updater-fail-container"); - - var failImage = new Image(); - var failDescription = new Label("Asset Store Publishing Tools could not retrieve information about the latest version."); - - failContainer.Add(failImage); - failContainer.Add(failDescription); - - rootVisualElement.Add(failContainer); - } - - private void LoadingSpinLoop() - { - var currentTimeSinceStartup = EditorApplication.timeSinceStartup; - var deltaTime = EditorApplication.timeSinceStartup - _lastTimeSinceStartup; - _lastTimeSinceStartup = currentTimeSinceStartup; - - _timeSinceLoadingImageChange += deltaTime; - if (_timeSinceLoadingImageChange < 0.075) - return; - - _timeSinceLoadingImageChange = 0; - - _loadingImage.image = EditorGUIUtility.IconContent($"WaitSpin{_loadingImageIndex++:00}").image; - if (_loadingImageIndex > 11) - _loadingImageIndex = 0; - } - - private void OnDestroy() - { - EditorApplication.update -= LoadingSpinLoop; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsUpdater.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsUpdater.cs.meta deleted file mode 100644 index d0e4183..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ASToolsUpdater.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 2ac370b9d2279ed4c9faec7134ba2759 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/CacheUtil.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/CacheUtil.cs deleted file mode 100644 index a596352..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/CacheUtil.cs +++ /dev/null @@ -1,266 +0,0 @@ -using System.IO; -using CacheConstants = AssetStoreTools.Constants.Cache; - -namespace AssetStoreTools.Utility -{ - internal static class CacheUtil - { - public static bool GetFileFromTempCache(string fileName, out string filePath) - { - return GetCacheFile(CacheConstants.TempCachePath, fileName, out filePath); - } - - public static bool GetFileFromPersistentCache(string fileName, out string filePath) - { - return GetCacheFile(CacheConstants.PersistentCachePath, fileName, out filePath); - } - - public static bool GetFileFromProjectPersistentCache(string projectPath, string fileName, out string filePath) - { - return GetCacheFile(Path.Combine(projectPath, CacheConstants.PersistentCachePath), fileName, out filePath); - } - - private static bool GetCacheFile(string rootPath, string fileName, out string filePath) - { - filePath = Path.Combine(rootPath, fileName); - return File.Exists(filePath); - } - - public static void CreateFileInTempCache(string fileName, object content, bool overwrite) - { - CreateCacheFile(CacheConstants.TempCachePath, fileName, content, overwrite); - } - - public static void CreateFileInPersistentCache(string fileName, object content, bool overwrite) - { - CreateCacheFile(CacheConstants.PersistentCachePath, fileName, content, overwrite); - } - - private static void CreateCacheFile(string rootPath, string fileName, object content, bool overwrite) - { - if (!Directory.Exists(rootPath)) - Directory.CreateDirectory(rootPath); - - var fullPath = Path.Combine(rootPath, fileName); - - bool willUpdate = false; - if (File.Exists(fullPath)) - { - if (overwrite) - { - File.Delete(fullPath); - willUpdate = true; - } - else - return; - } - - switch (content) - { - case byte[] bytes: - File.WriteAllBytes(fullPath, bytes); - break; - default: - File.WriteAllText(fullPath, content.ToString()); - break; - } - - var keyword = willUpdate ? "Updating" : "Creating"; - ASDebug.Log($"{keyword} cache file: '{fullPath}'"); - } - - public static void DeleteFileFromTempCache(string fileName) - { - DeleteFileFromCache(CacheConstants.TempCachePath, fileName); - } - - public static void DeleteFileFromPersistentCache(string fileName) - { - DeleteFileFromCache(CacheConstants.PersistentCachePath, fileName); - } - - private static void DeleteFileFromCache(string rootPath, string fileName) - { - var path = Path.Combine(rootPath, fileName); - if (File.Exists(path)) - File.Delete(path); - } - - //private static void CreateFileInPersistentCache(string fileName, object content, bool overwrite) - //{ - // CreateCacheFile(CacheConstants.PersistentCachePath, fileName, content, overwrite); - //} - - //private static void CreateCacheFile(string rootPath, string fileName, object content, bool overwrite) - //{ - // if (!Directory.Exists(rootPath)) - // Directory.CreateDirectory(rootPath); - - // var fullPath = Path.Combine(rootPath, fileName); - - // if (File.Exists(fullPath)) - // { - // if (overwrite) - // File.Delete(fullPath); - // else - // return; - // } - - // switch (content) - // { - // case byte[] bytes: - // File.WriteAllBytes(fullPath, bytes); - // break; - // default: - // File.WriteAllText(fullPath, content.ToString()); - // break; - // } - // ASDebug.Log($"Creating cached file: '{fullPath}'"); - //} - - //public static void ClearTempCache() - //{ - // if (!File.Exists(Path.Combine(CacheConstants.TempCachePath, CacheConstants.PackageDataFile))) - // return; - - - // // Cache consists of package data and package texture thumbnails. We don't clear - // // texture thumbnails here since they are less likely to change. They are still - // // deleted and redownloaded every project restart (because of being stored in the 'Temp' folder) - // var fullPath = Path.Combine(CacheConstants.TempCachePath, CacheConstants.PackageDataFile); - // ASDebug.Log($"Deleting cached file '{fullPath}'"); - // File.Delete(fullPath); - //} - - //public static void CachePackageMetadata(List data) - //{ - // var serializerSettings = new JsonSerializerSettings() - // { - // ContractResolver = Package.CachedPackageResolver.Instance, - // Formatting = Formatting.Indented - // }; - - // CreateFileInTempCache(CacheConstants.PackageDataFile, JsonConvert.SerializeObject(data, serializerSettings), true); - //} - - //public static void UpdatePackageMetadata(Package data) - //{ - // if (!GetCachedPackageMetadata(out var cachedData)) - // return; - - // var index = cachedData.FindIndex(x => x.PackageId.Equals(data.PackageId)); - // if (index == -1) - // { - // cachedData.Add(data); - // } - // else - // { - // cachedData.RemoveAt(index); - // cachedData.Insert(index, data); - // } - - // CachePackageMetadata(cachedData); - //} - - //public static bool GetCachedPackageMetadata(out List data) - //{ - // data = new List(); - // var path = Path.Combine(CacheConstants.TempCachePath, CacheConstants.PackageDataFile); - // if (!File.Exists(path)) - // return false; - - // try - // { - // var serializerSettings = new JsonSerializerSettings() - // { - // ContractResolver = Package.CachedPackageResolver.Instance - // }; - - // data = JsonConvert.DeserializeObject>(File.ReadAllText(path, Encoding.UTF8), serializerSettings); - // return true; - // } - // catch - // { - // return false; - // } - //} - - //public static void CacheTexture(string packageId, Texture2D texture) - //{ - // CreateFileInTempCache($"{packageId}.png", texture.EncodeToPNG(), true); - //} - - //public static bool GetCachedTexture(string packageId, out Texture2D texture) - //{ - // texture = new Texture2D(1, 1); - // var path = Path.Combine(CacheConstants.TempCachePath, $"{packageId}.png"); - // if (!File.Exists(path)) - // return false; - - // texture.LoadImage(File.ReadAllBytes(path)); - // return true; - //} - - //public static void CacheWorkflowStateData(string packageId, WorkflowStateData data) - //{ - // var fileName = $"{packageId}-workflowStateData.asset"; - // CreateFileInPersistentCache(fileName, JsonConvert.SerializeObject(data, Formatting.Indented), true); - //} - - //public static bool GetCachedWorkflowStateData(string packageId, out WorkflowStateData data) - //{ - // data = null; - // var path = Path.Combine(CacheConstants.PersistentCachePath, $"{packageId}-workflowStateData.asset"); - // if (!File.Exists(path)) - // return false; - - // data = JsonConvert.DeserializeObject(File.ReadAllText(path, Encoding.UTF8)); - // return true; - //} - - //public static void CacheValidationStateData(ValidationStateData data) - //{ - // var serializerSettings = new JsonSerializerSettings() - // { - // ContractResolver = ValidationStateDataContractResolver.Instance, - // Formatting = Formatting.Indented, - // TypeNameHandling = TypeNameHandling.Auto, - // Converters = new List() { new StringEnumConverter() } - // }; - - // CreateFileInPersistentCache(CacheConstants.ValidationResultFile, JsonConvert.SerializeObject(data, serializerSettings), true); - //} - - //public static bool GetCachedValidationStateData(out ValidationStateData data) - //{ - // return GetCachedValidationStateData(Constants.RootProjectPath, out data); - //} - - //public static bool GetCachedValidationStateData(string projectPath, out ValidationStateData data) - //{ - // data = null; - // var path = Path.Combine(projectPath, CacheConstants.PersistentCachePath, CacheConstants.ValidationResultFile); - // if (!File.Exists(path)) - // return false; - - // try - // { - // var serializerSettings = new JsonSerializerSettings() - // { - // ContractResolver = ValidationStateDataContractResolver.Instance, - // Formatting = Formatting.Indented, - // TypeNameHandling = TypeNameHandling.Auto, - // Converters = new List() { new StringEnumConverter() } - // }; - - // data = JsonConvert.DeserializeObject(File.ReadAllText(path, Encoding.UTF8), serializerSettings); - // return true; - // } - // catch (System.Exception e) - // { - // UnityEngine.Debug.LogException(e); - // return false; - // } - //} - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/CacheUtil.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/CacheUtil.cs.meta deleted file mode 100644 index fca787f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/CacheUtil.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 2e5fee0cad7655f458d9b600f4ae6d02 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/FileUtility.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/FileUtility.cs deleted file mode 100644 index 5e545f8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/FileUtility.cs +++ /dev/null @@ -1,207 +0,0 @@ -using System.Collections.Generic; -using System.IO; -using System.Linq; -using UnityEditor; - -namespace AssetStoreTools.Utility -{ - internal static class FileUtility - { - private class RenameInfo - { - public string OriginalName; - public string CurrentName; - } - - public static string AbsolutePathToRelativePath(string path, bool allowSymlinks) - { - if (!File.Exists(path) && !Directory.Exists(path)) - return path; - - string convertedPath = path.Replace("\\", "/"); - - var allPackages = PackageUtility.GetAllPackages(); - foreach (var package in allPackages) - { - if (Path.GetFullPath(package.resolvedPath) != Path.GetFullPath(convertedPath) - && !Path.GetFullPath(convertedPath).StartsWith(Path.GetFullPath(package.resolvedPath) + Path.DirectorySeparatorChar)) - continue; - - convertedPath = Path.GetFullPath(convertedPath) - .Replace(Path.GetFullPath(package.resolvedPath), package.assetPath) - .Replace("\\", "/"); - - return convertedPath; - } - - if (convertedPath.StartsWith(Constants.RootProjectPath)) - { - convertedPath = convertedPath.Substring(Constants.RootProjectPath.Length); - } - else - { - if (allowSymlinks && SymlinkUtil.FindSymlinkFolderRelative(convertedPath, out var symlinkPath)) - convertedPath = symlinkPath; - } - - return convertedPath; - } - - public static void CopyDirectory(string sourceDir, string destinationDir, bool recursive) - { - // Get information about the source directory - var dir = new DirectoryInfo(sourceDir); - - // Check if the source directory exists - if (!dir.Exists) - throw new DirectoryNotFoundException($"Source directory not found: {dir.FullName}"); - - // Cache directories before we start copying - DirectoryInfo[] dirs = dir.GetDirectories(); - - // Create the destination directory - Directory.CreateDirectory(destinationDir); - - // Get the files in the source directory and copy to the destination directory - foreach (FileInfo file in dir.GetFiles()) - { - string targetFilePath = Path.Combine(destinationDir, file.Name); - file.CopyTo(targetFilePath); - } - - // If recursive and copying subdirectories, recursively call this method - if (recursive) - { - foreach (DirectoryInfo subDir in dirs) - { - string newDestinationDir = Path.Combine(destinationDir, subDir.Name); - CopyDirectory(subDir.FullName, newDestinationDir, true); - } - } - } - - public static bool ShouldHaveMeta(string assetPath) - { - if (string.IsNullOrEmpty(assetPath)) - return false; - - // Meta files never have other metas - if (assetPath.EndsWith(".meta", System.StringComparison.OrdinalIgnoreCase)) - return false; - - // File System entries ending with '~' are hidden in the context of ADB - if (assetPath.EndsWith("~")) - return false; - - // File System entries whose names start with '.' are hidden in the context of ADB - var assetName = assetPath.Replace("\\", "/").Split('/').Last(); - if (assetName.StartsWith(".")) - return false; - - return true; - } - - public static bool IsMissingMetaFiles(IEnumerable sourcePaths) - { - foreach (var sourcePath in sourcePaths) - { - if (!Directory.Exists(sourcePath)) - continue; - - var allDirectories = Directory.GetDirectories(sourcePath, "*", SearchOption.AllDirectories); - foreach (var dir in allDirectories) - { - var dirInfo = new DirectoryInfo(dir); - if (!dirInfo.Name.EndsWith("~")) - continue; - - var nestedContent = dirInfo.GetFileSystemInfos("*", SearchOption.AllDirectories); - foreach (var nested in nestedContent) - { - if (!ShouldHaveMeta(nested.FullName)) - continue; - - if (!File.Exists(nested.FullName + ".meta")) - return true; - } - } - } - - return false; - } - - public static void GenerateMetaFiles(IEnumerable sourcePaths) - { - var renameInfos = new List(); - - foreach (var sourcePath in sourcePaths) - { - if (!Directory.Exists(sourcePath)) - continue; - - var hiddenDirectoriesInPath = Directory.GetDirectories(sourcePath, "*", SearchOption.AllDirectories).Where(x => x.EndsWith("~")); - foreach (var hiddenDir in hiddenDirectoriesInPath) - { - var hiddenDirRelative = AbsolutePathToRelativePath(hiddenDir, ASToolsPreferences.Instance.EnableSymlinkSupport); - if (!hiddenDirRelative.StartsWith("Assets/") && !hiddenDirRelative.StartsWith("Packages/")) - { - ASDebug.LogWarning($"Path {sourcePath} is not part of the Asset Database and will be skipped"); - continue; - } - - renameInfos.Add(new RenameInfo() { CurrentName = hiddenDirRelative, OriginalName = hiddenDirRelative }); - } - } - - if (renameInfos.Count == 0) - return; - - try - { - EditorApplication.LockReloadAssemblies(); - - // Order paths from longest to shortest to avoid having to rename them multiple times - renameInfos = renameInfos.OrderByDescending(x => x.OriginalName.Length).ToList(); - - try - { - AssetDatabase.StartAssetEditing(); - foreach (var renameInfo in renameInfos) - { - renameInfo.CurrentName = renameInfo.OriginalName.TrimEnd('~'); - Directory.Move(renameInfo.OriginalName, renameInfo.CurrentName); - } - } - finally - { - AssetDatabase.StopAssetEditing(); - AssetDatabase.Refresh(ImportAssetOptions.ForceSynchronousImport); - AssetDatabase.ReleaseCachedFileHandles(); - } - - // Restore the original path names in reverse order - renameInfos = renameInfos.OrderBy(x => x.OriginalName.Length).ToList(); - - try - { - AssetDatabase.StartAssetEditing(); - foreach (var renameInfo in renameInfos) - { - Directory.Move(renameInfo.CurrentName, renameInfo.OriginalName); - if (File.Exists($"{renameInfo.CurrentName}.meta")) - File.Delete($"{renameInfo.CurrentName}.meta"); - } - } - finally - { - AssetDatabase.StopAssetEditing(); - AssetDatabase.Refresh(ImportAssetOptions.ForceSynchronousImport); - } - } - finally - { - EditorApplication.UnlockReloadAssemblies(); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/FileUtility.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/FileUtility.cs.meta deleted file mode 100644 index db285bb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/FileUtility.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 80819cf6868374d478a8a38ebaba8e27 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/LegacyToolsRemover.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/LegacyToolsRemover.cs deleted file mode 100644 index c9df7c2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/LegacyToolsRemover.cs +++ /dev/null @@ -1,86 +0,0 @@ -using System; -using System.IO; -using System.Reflection; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Utility -{ - [InitializeOnLoad] - internal class LegacyToolsRemover - { - private const string MessagePart1 = "A legacy version of Asset Store Tools " + - "was detected at the following path:\n"; - private const string MessagePart2 = "\n\nHaving both the legacy and the latest version installed at the same time is not supported " + - "and might prevent the latest version from functioning properly.\n\nWould you like the legacy version to be removed automatically?"; - - static LegacyToolsRemover() - { - try - { - if (Application.isBatchMode) - return; - - CheckAndRemoveLegacyTools(); - } - catch { } - } - - private static void CheckAndRemoveLegacyTools() - { - if (!ASToolsPreferences.Instance.LegacyVersionCheck || !ProjectContainsLegacyTools(out string path)) - return; - - var relativePath = path.Substring(Application.dataPath.Length - "Assets".Length).Replace("\\", "/"); - var result = EditorUtility.DisplayDialog("Asset Store Tools", MessagePart1 + relativePath + MessagePart2, "Yes", "No"); - - // If "No" - do nothing - if (!result) - return; - - // If "Yes" - remove legacy tools - File.Delete(path); - File.Delete(path + ".meta"); - RemoveEmptyFolders(Path.GetDirectoryName(path)?.Replace("\\", "/")); - AssetDatabase.Refresh(); - - // We could also optionally prevent future execution here - // but the ProjectContainsLegacyTools() function runs in less - // than a milisecond on an empty project - } - - private static bool ProjectContainsLegacyTools(out string path) - { - path = null; - - foreach (Assembly assembly in AppDomain.CurrentDomain.GetAssemblies()) - { - if (assembly.ManifestModule.Name == "AssetStoreTools.dll") - { - path = assembly.Location; - break; - } - } - - if (string.IsNullOrEmpty(path)) - return false; - return true; - } - - private static void RemoveEmptyFolders(string directory) - { - if (directory.EndsWith(Application.dataPath)) - return; - - if (Directory.GetFiles(directory).Length == 0 && Directory.GetDirectories(directory).Length == 0) - { - var parentPath = Path.GetDirectoryName(directory).Replace("\\", "/"); - - Directory.Delete(directory); - File.Delete(directory + ".meta"); - - RemoveEmptyFolders(parentPath); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/LegacyToolsRemover.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/LegacyToolsRemover.cs.meta deleted file mode 100644 index c16ca0a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/LegacyToolsRemover.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 46ead42026b1f0b4e94153e1a7e10d12 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/PackageUtility.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/PackageUtility.cs deleted file mode 100644 index a384f7a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/PackageUtility.cs +++ /dev/null @@ -1,170 +0,0 @@ -#if !UNITY_2021_1_OR_NEWER -using System; -using System.Reflection; -#endif -using Newtonsoft.Json.Linq; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using UnityEditor; -using UnityEditor.PackageManager; -using UnityEngine; -using PackageInfo = UnityEditor.PackageManager.PackageInfo; - -namespace AssetStoreTools.Utility -{ - internal static class PackageUtility - { - public class PackageInfoSampleMetadata - { - public string DisplayName; - public string Description; - public string Path; - } - - public class PackageInfoUnityVersionMetadata - { - /// - /// Major bit of the Unity version, e.g. 2021.3 - /// - public string Version; - /// - /// Minor bit of the Unity version, e.g. 0f1 - /// - public string Release; - - public override string ToString() - { - if (string.IsNullOrEmpty(Version)) - return Release; - - if (string.IsNullOrEmpty(Release)) - return Release; - - return $"{Version}.{Release}"; - } - } - - /// - /// Returns a package identifier, consisting of package name and package version - /// - /// - /// - public static string GetPackageIdentifier(this PackageInfo package) - { - return $"{package.name}-{package.version}"; - } - - public static PackageInfo[] GetAllPackages() - { -#if !UNITY_2021_1_OR_NEWER - var method = typeof(PackageInfo).GetMethod("GetAll", BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Static, null, new Type[0], null); - var packages = method?.Invoke(null, null) as PackageInfo[]; -#else - var packages = PackageInfo.GetAllRegisteredPackages(); -#endif - return packages; - } - - public static PackageInfo[] GetAllLocalPackages() - { - var packages = GetAllPackages(); - var localPackages = packages.Where(x => x.source == PackageSource.Embedded || x.source == PackageSource.Local) - .Where(x => x.isDirectDependency).ToArray(); - return localPackages; - } - - public static PackageInfo[] GetAllRegistryPackages() - { - var packages = GetAllPackages(); - var registryPackages = packages.Where(x => x.source == PackageSource.Registry || x.source == PackageSource.BuiltIn) - .OrderBy(x => string.Compare(x.type, "module", System.StringComparison.OrdinalIgnoreCase) == 0) - .ThenBy(x => x.name).ToArray(); - - return registryPackages; - } - - public static bool GetPackageByManifestPath(string packageManifestPath, out PackageInfo package) - { - package = null; - - if (string.IsNullOrEmpty(packageManifestPath)) - return false; - - var fileInfo = new FileInfo(packageManifestPath); - if (!fileInfo.Exists) - return false; - - var allPackages = GetAllPackages(); - - package = allPackages.FirstOrDefault(x => Path.GetFullPath(x.resolvedPath).Equals(fileInfo.Directory.FullName)); - return package != null; - } - - public static bool GetPackageByPackageName(string packageName, out PackageInfo package) - { - package = null; - - if (string.IsNullOrEmpty(packageName)) - return false; - - return GetPackageByManifestPath($"Packages/{packageName}/package.json", out package); - } - - public static TextAsset GetManifestAsset(this PackageInfo packageInfo) - { - return AssetDatabase.LoadAssetAtPath($"{packageInfo.assetPath}/package.json"); - } - - public static List GetSamples(this PackageInfo packageInfo) - { - var samples = new List(); - - var packageManifest = packageInfo.GetManifestAsset(); - var json = JObject.Parse(packageManifest.text); - - if (!json.ContainsKey("samples") || json["samples"].Type != JTokenType.Array) - return samples; - - var sampleList = json["samples"].ToList(); - foreach (JObject sample in sampleList) - { - var displayName = string.Empty; - var description = string.Empty; - var path = string.Empty; - - if (sample.ContainsKey("displayName")) - displayName = sample["displayName"].ToString(); - if (sample.ContainsKey("description")) - description = sample["description"].ToString(); - if (sample.ContainsKey("path")) - path = sample["path"].ToString(); - - if (!string.IsNullOrEmpty(displayName) || !string.IsNullOrEmpty(description) || !string.IsNullOrEmpty(path)) - samples.Add(new PackageInfoSampleMetadata() { DisplayName = displayName, Description = description, Path = path }); - } - - return samples; - } - - public static PackageInfoUnityVersionMetadata GetUnityVersion(this PackageInfo packageInfo) - { - var packageManifest = packageInfo.GetManifestAsset(); - var json = JObject.Parse(packageManifest.text); - - var unityVersion = string.Empty; - var unityRelease = string.Empty; - - if (json.ContainsKey("unity")) - unityVersion = json["unity"].ToString(); - if (json.ContainsKey("unityRelease")) - unityRelease = json["unityRelease"].ToString(); - - return new PackageInfoUnityVersionMetadata() - { - Version = unityVersion, - Release = unityRelease - }; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/PackageUtility.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/PackageUtility.cs.meta deleted file mode 100644 index 6ce8b3d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/PackageUtility.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 605ea62f8b11d674a95a53f895df4c67 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ServiceProvider.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ServiceProvider.cs deleted file mode 100644 index 9751081..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ServiceProvider.cs +++ /dev/null @@ -1,113 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; - -namespace AssetStoreTools.Utility -{ - internal abstract class ServiceProvider - { - private Dictionary _services = new Dictionary(); - private Dictionary> _queuedServices = new Dictionary>(); - - protected class MissingServiceDependencyException : Exception - { - public Type ServiceType { get; private set; } - public Type MissingDependencyType { get; private set; } - - public MissingServiceDependencyException(Type serviceType, Type missingDependencyType) - { - ServiceType = serviceType; - MissingDependencyType = missingDependencyType; - } - } - - protected ServiceProvider() - { - RegisterServices(); - CreateRegisteredServices(); - } - - protected abstract void RegisterServices(); - - protected void Register() where TService : Service where TInstance : TService - { - Register(() => CreateServiceInstance(typeof(TInstance))); - } - - protected void Register(Func initializer) where TService : Service - { - _queuedServices.Add(typeof(TService), initializer); - } - - private void CreateRegisteredServices() - { - if (_queuedServices.Count == 0) - return; - - var createdAnyService = false; - var missingServices = new List(); - - foreach (var service in _queuedServices) - { - try - { - var instance = service.Value.Invoke(); - _services.Add(service.Key, instance); - createdAnyService = true; - } - catch (MissingServiceDependencyException e) - { - missingServices.Add(e); - } - } - - foreach (var createdService in _services) - { - _queuedServices.Remove(createdService.Key); - } - - if (!createdAnyService) - { - var message = string.Join(", ", missingServices.Select(x => $"{x.ServiceType} depends on {x.MissingDependencyType}")); - throw new Exception("Could not create the following services due to missing dependencies: " + message); - } - - // Recursively register remaining queued services that may have failed - // due to missing depenedencies that are now registered - CreateRegisteredServices(); - } - - private Service CreateServiceInstance(Type concreteType) - { - if (concreteType.IsAbstract) - throw new Exception($"Cannot create an instance of an abstract class {concreteType}"); - - var constructor = concreteType.GetConstructors().First(); - var expectedParameters = constructor.GetParameters(); - var parametersToUse = new List(); - - foreach (var parameter in expectedParameters) - { - if (!_services.ContainsKey(parameter.ParameterType)) - throw new MissingServiceDependencyException(concreteType, parameter.ParameterType); - - parametersToUse.Add(_services[parameter.ParameterType]); - } - - return (Service)constructor.Invoke(parametersToUse.ToArray()); - } - - public T GetService() where T : Service - { - return (T)GetService(typeof(T)); - } - - public object GetService(Type type) - { - if (!_services.ContainsKey(type)) - throw new Exception($"Service of type {type} is not registered"); - - return _services[type]; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ServiceProvider.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ServiceProvider.cs.meta deleted file mode 100644 index 847bd4b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/ServiceProvider.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 2fcadafa6431d1647a82d35e6e4a13c5 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/StyleSelector.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/StyleSelector.cs deleted file mode 100644 index 1076bca..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/StyleSelector.cs +++ /dev/null @@ -1,55 +0,0 @@ -using System; -using UnityEditor; -using UnityEngine.UIElements; -using WindowStyles = AssetStoreTools.Constants.WindowStyles; - -namespace AssetStoreTools.Utility -{ - internal static class StyleSelector - { - private static StyleSheet GetStylesheet(string rootPath, string filePath) - { - var path = $"{rootPath}/{filePath}.uss"; - var sheet = AssetDatabase.LoadAssetAtPath(path); - if (sheet == null) - throw new Exception($"Stylesheet '{path}' was not found"); - return sheet; - } - - private static StyleSheet GetStylesheetTheme(string rootPath, string filePath) - { - var suffix = !EditorGUIUtility.isProSkin ? "Light" : "Dark"; - return GetStylesheet(rootPath, filePath + suffix); - } - - public static class UploaderWindow - { - public static StyleSheet UploaderWindowStyle => GetStylesheet(WindowStyles.UploaderStylesPath, "Style"); - public static StyleSheet UploaderWindowTheme => GetStylesheetTheme(WindowStyles.UploaderStylesPath, "Theme"); - - public static StyleSheet LoginViewStyle => GetStylesheet(WindowStyles.UploaderStylesPath, "LoginView/Style"); - public static StyleSheet LoginViewTheme => GetStylesheetTheme(WindowStyles.UploaderStylesPath, "LoginView/Theme"); - - public static StyleSheet PackageListViewStyle => GetStylesheet(WindowStyles.UploaderStylesPath, "PackageListView/Style"); - public static StyleSheet PackageListViewTheme => GetStylesheetTheme(WindowStyles.UploaderStylesPath, "PackageListView/Theme"); - } - - public static class ValidatorWindow - { - public static StyleSheet ValidatorWindowStyle => GetStylesheet(WindowStyles.ValidatorStylesPath, "Style"); - public static StyleSheet ValidatorWindowTheme => GetStylesheetTheme(WindowStyles.ValidatorStylesPath, "Theme"); - } - - public static class PreviewGeneratorWindow - { - public static StyleSheet PreviewGeneratorWindowStyle => GetStylesheet(WindowStyles.PreviewGeneratorStylesPath, "Style"); - public static StyleSheet PreviewGeneratorWindowTheme => GetStylesheetTheme(WindowStyles.PreviewGeneratorStylesPath, "Theme"); - } - - public static class UpdaterWindow - { - public static StyleSheet UpdaterWindowStyle => GetStylesheet(WindowStyles.UpdaterStylesPath, "Style"); - public static StyleSheet UpdaterWindowTheme => GetStylesheetTheme(WindowStyles.UpdaterStylesPath, "Theme"); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/StyleSelector.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/StyleSelector.cs.meta deleted file mode 100644 index d4ab01c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/StyleSelector.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 8b066ce502a289a4ca311a86fbf83f45 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles.meta deleted file mode 100644 index 0175b81..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: f730eb0b8c48c434d93cc60a0b8aff40 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater.meta deleted file mode 100644 index 315b99b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 5367435d9abe935438f4d7b588a55488 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/Style.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/Style.uss deleted file mode 100644 index 1ee89cd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/Style.uss +++ /dev/null @@ -1,76 +0,0 @@ -.updater-loading-container { - flex-grow: 1; - align-items: center; - justify-content: center; -} - -.updater-loading-container > Image { - width: 16px; - height: 16px; -} - -.updater-info-container { - flex-grow: 1; - margin: 0 5px 5px 5px; -} - -.updater-info-container-labels { - flex-grow: 1; - margin-bottom: 10px; - margin-top: 5px; -} - -.updater-info-container-labels-description { - flex-grow: 0.5; - margin-bottom: 5px; - white-space: normal; - -unity-text-align: middle-left; -} - -.updater-info-container-labels-row { - flex-direction: row; -} - -.updater-info-container-labels-row-identifier { - -unity-font-style: bold; -} - -.updater-info-container-buttons { - flex-direction: row; - margin-bottom: 5px; -} - -.updater-info-container-buttons > Button { - flex-grow: 1; - flex-shrink: 1; - flex-basis: 100%; - height: 25px; -} - -.updater-info-container-toggle { - align-self: flex-end; -} - -.updater-info-container-toggle > Toggle > VisualElement > Label { - margin-left: 5px; -} - -.updater-fail-container { - flex-grow: 1; - flex-direction: row; - margin: 0 5px 5px 5px; - justify-content: center; - align-items: center; -} - -.updater-fail-container > Image { - flex-shrink: 0; - width: 36px; - height: 36px; - margin-right: 5px; -} - -.updater-fail-container > Label { - flex-shrink: 1; - white-space: normal; -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/Style.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/Style.uss.meta deleted file mode 100644 index 3ba3542..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/Style.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 23112eed1f211274c94028490f81007c -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeDark.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeDark.uss deleted file mode 100644 index 3510f8a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeDark.uss +++ /dev/null @@ -1,3 +0,0 @@ -.updater-fail-container > Image { - --unity-image: resource("console.erroricon@2x"); -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeDark.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeDark.uss.meta deleted file mode 100644 index 9fad31b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeDark.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 0cbf43b8dabcd1242b32ed3ed2167a54 -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeLight.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeLight.uss deleted file mode 100644 index 3510f8a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeLight.uss +++ /dev/null @@ -1,3 +0,0 @@ -.updater-fail-container > Image { - --unity-image: resource("console.erroricon@2x"); -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeLight.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeLight.uss.meta deleted file mode 100644 index 0cdf6fd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/Styles/Updater/ThemeLight.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: d453bb92cd1f35943b1c5f652837ada9 -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/SymlinkUtil.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/SymlinkUtil.cs deleted file mode 100644 index 93da1ee..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/SymlinkUtil.cs +++ /dev/null @@ -1,67 +0,0 @@ -using System.IO; - -namespace AssetStoreTools.Utility -{ - internal static class SymlinkUtil - { - private const FileAttributes FolderSymlinkAttributes = FileAttributes.Directory | FileAttributes.ReparsePoint; - - public static bool FindSymlinkFolderRelative(string folderPathAbsolute, out string relativePath) - { - // Get directory info for path outside of the project - var absoluteInfo = new DirectoryInfo(folderPathAbsolute); - - // Get all directories within the project - var allFolderPaths = Directory.GetDirectories("Assets", "*", SearchOption.AllDirectories); - foreach (var path in allFolderPaths) - { - var fullPath = path.Replace("\\", "/"); - - // Get directory info for one of the paths within the project - var relativeInfo = new DirectoryInfo(fullPath); - - // Check if project's directory is a symlink - if (!relativeInfo.Attributes.HasFlag(FolderSymlinkAttributes)) - continue; - - // Compare metadata of outside directory with a directories within the project - if (!CompareDirectories(absoluteInfo, relativeInfo)) - continue; - - // Found symlink within the project, assign it - relativePath = fullPath; - return true; - } - - relativePath = string.Empty; - return false; - } - - private static bool CompareDirectories(DirectoryInfo directory, DirectoryInfo directory2) - { - var contents = directory.EnumerateFileSystemInfos("*", SearchOption.AllDirectories).GetEnumerator(); - var contents2 = directory2.EnumerateFileSystemInfos("*", SearchOption.AllDirectories).GetEnumerator(); - - while (true) - { - var firstNext = contents.MoveNext(); - var secondNext = contents2.MoveNext(); - - if (firstNext != secondNext) - return false; - - if (!firstNext && !secondNext) - break; - - var equals = contents.Current?.Name == contents2.Current?.Name - && contents.Current?.LastWriteTime == contents2.Current?.LastWriteTime; - - if (!equals) - return false; - } - - return true; - } - - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/SymlinkUtil.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/SymlinkUtil.cs.meta deleted file mode 100644 index 43c8aaf..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Utility/SymlinkUtil.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 92092535fd064bb1843017f98db213e1 -timeCreated: 1659013521 \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator.meta deleted file mode 100644 index e27c1ef..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 980c7bb65c02d464684c2220c57fcd75 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons.meta deleted file mode 100644 index 7f4c321..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 8490c57c02b441e4dab99565da835c99 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/error.png b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/error.png deleted file mode 100644 index 8d294bc199d18c75542a22f1a5872e3c9276b863..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1057 zcmV++1m63JP)@~0drDELIAGL9O(c600d`2O+f$vv5yP|(KsZ6^2^#hdO&5KnE9eQDBXEOeMR{%G zspMeu0=BHg(nxvv-U~RfVtf9~NFI5FUUvkOEga=U@SZ znozvE32Pf?@=))96QVOnexKstdJHwFB|vJtXkN*qw7>^MBPqgO9T655z`ODJh13&a zApwFhKBI;Ra|;lh@fiz>FqZ(q8lSO%2*v^gZ+ym_A{Ys*$#KcCtbW4o)+#pXrBOz zF4&~P6AA@z_{-nm#pSlP$>Hl?)^iDs2v0)5afdgkY(bVoL7@qU83Ek)_GmCPQLW^r z{M5xFG5Ypn0mlkv&(XmV`Lmg;2I^uTJwY2 z6m+oPk^kQV2Lus>Lx+yqyF#kLIFn-%-xL8CgeNKl`0nq~$OBB;SOQzZ-2`Sax?59< zW7cbtYzp8;G+&hOyyF%C_ytJ*Zk6t9G$LSzUjP&@As{@2K%?BvlOzIW_yr*CFvsp4 z`~ql49bADXj&!x z+e{okt9(>1G*cv%=H%j!yFv+)?w#DeDy!I-17j!;G5STvQND>M-}m(Atp z3`GPV3n%k)`xe2%(%D*bf)BX^o&h^audeZm+N;Mirt^8K?iiIfxXS6rY8nd?=;D{l bA7Fw1SKskfA=so700000NkvXXu0mjfJ)q0> diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/error.png.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/error.png.meta deleted file mode 100644 index 4217052..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/error.png.meta +++ /dev/null @@ -1,128 +0,0 @@ -fileFormatVersion: 2 -guid: 0cc0ccdb7de3e964ab553ce3c299d83c -TextureImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 11 - mipmaps: - mipMapMode: 0 - enableMipMap: 1 - sRGBTexture: 1 - linearTexture: 0 - fadeOut: 0 - borderMipMap: 0 - mipMapsPreserveCoverage: 0 - alphaTestReferenceValue: 0.5 - mipMapFadeDistanceStart: 1 - mipMapFadeDistanceEnd: 3 - bumpmap: - convertToNormalMap: 0 - externalNormalMap: 0 - heightScale: 0.25 - normalMapFilter: 0 - isReadable: 0 - streamingMipmaps: 0 - streamingMipmapsPriority: 0 - grayScaleToAlpha: 0 - generateCubemap: 6 - cubemapConvolution: 0 - seamlessCubemap: 0 - textureFormat: 1 - maxTextureSize: 2048 - textureSettings: - serializedVersion: 2 - filterMode: 2 - aniso: 0 - mipBias: 0 - wrapU: 1 - wrapV: 1 - wrapW: 1 - nPOTScale: 0 - lightmap: 0 - compressionQuality: 50 - spriteMode: 1 - spriteExtrude: 0 - spriteMeshType: 1 - alignment: 0 - spritePivot: {x: 0.5, y: 0.5} - spritePixelsToUnits: 100 - spriteBorder: {x: 0, y: 0, z: 0, w: 0} - spriteGenerateFallbackPhysicsShape: 0 - alphaUsage: 1 - alphaIsTransparency: 1 - spriteTessellationDetail: -1 - textureType: 8 - textureShape: 1 - singleChannelComponent: 0 - maxTextureSizeSet: 0 - compressionQualitySet: 0 - textureFormatSet: 0 - applyGammaDecoding: 0 - platformSettings: - - serializedVersion: 3 - buildTarget: DefaultTexturePlatform - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Standalone - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: iPhone - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Android - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - spriteSheet: - serializedVersion: 2 - sprites: [] - outline: [] - physicsShape: [] - bones: [] - spriteID: 5e97eb03825dee720800000000000000 - internalID: 0 - vertices: [] - indices: - edges: [] - weights: [] - secondaryTextures: [] - spritePackingTag: - pSDRemoveMatte: 0 - pSDShowRemoveMatteOption: 0 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/error_d.png b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/error_d.png deleted file mode 100644 index 451f64037adef0edb0178cc7a335c513faa0f444..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1024 zcmV+b1poVqP)@~0drDELIAGL9O(c600d`2O+f$vv5yPccK~#7F?VIgU z+dvS8-#dv6Kg`5b5K#f7gQS4~6+j1}1E7LH1#v1cR1i`@D8U^>Gd43!EPJyjI3~vW zvZdP-h-ZfJ$K4?9>$}zN-JU{2412v#0dPvd9)Ik^4Y2}liDAP5V6L1B1)7{@VcP)mT+_$2v>hhN2uoAI<(wy_u1fm=12j+WbXX9;wYTTt7B|snO)^Dz5;=>5xAc0$t*v8z z{R$Z(v;=m@$7U5v2ZAd(s=^fD8;c->S;EsK8Q)hiPG$-`T*~+Zxb?bA6osZ`VXFiB z8p6E0zkgrQEG+=U1^62T+qsQN5WKHxqNSi;8?$Td<620>5Pggg;igt!1j`2cnODS(blfy|iSLmrUgMSz@q zpgRI&<^vw`0D~6++LRA?5rFf7==oP11MI>BegshJY`D1@*^lf1BOVqf@POj2D1s+= z6Xa@66!XUD0X#Xu5FTOW57>D4#LpD4nEC))Bj5=y0%X+(p!sd_N+?I$(fJUa@D}-H zR+HJJ;itiO$PsH(dkY~RYkV*B+7HL$frCns{QF_s^$a+N5W0eKGonU{psT={=|CS& zCO7PeL@pX6$*8nb7?$^G0ON;D#d+!k=RshC5V5IH$aE^GY8qOQ#P_Svq}e&eG|Fla|+Tbhg%-pv@gjZVh3~%28e8)Bl5p uFzb07(;q3v$LG^!EM7qUGMW5B1N;Ldf$_%L+dGi}0000@~0drDELIAGL9O(c600d`2O+f$vv5yPN!?I71%@Y_u0eJ0f zj!SN-0;hD`1X+`A31I;Ojiiw+w)U&C!Da-Se|n~Sx(9@m$@l8T4FjqYumorq0Yni| z=B0$9za1hBq(l?I9?)NXdVamJA^U%S(H=mGAf!Oyrd|b!FHp#X`Hn_~g`tP89K)+o zrQHS1XcHjcYvgme_YDAfL~omi6mZ4BreVk{U6zqpfXC?gBGM!=I);JgNrgxxK;ioP z1_(TPypGS}S;TPX;uXXsmH^NHtQRc{UeePlWB?YzFknB9H3*0ZkGf^a9%Q8R3@@~N zPmV=KB$5Se-qc%k!4YH`8%{^1c2l*vvH)9e>K%#j4XgolpPjp%_O~i+l>{i<9Fob) zGOQKYAMIXL!diu{0X*{S*Lg;kH*f1N!&`@`AFHp^aceY{wC z@!DY9$D`6Ot)Q0z1#ta5ySk?daP%Y1Tn;NiaYEn}xW9+X52y1C<|l#M0t*7rqE}10 zgUcw@pg?J63b5((=zpLB08a(W`gGf@v`p_mGZrwmps^;M?;^+s|Iqz*)GtHcxz0qg zQwvy^g-;^Z?&fxXTeshpr4)+m)~ppwE#Q94o14rpe9gOnt?zK>*S>9wQ&3{o3Ld6_ zfD_0tWa@*_ZhL7bZTpiBk1nXa+jKE>1mGNA*5^Jg&ikugcTHLhKnctjdX%?>i2#`O za93i>tZ2>-8~B1ByeUwHjKZdG-OKZ^cD#s3*|bTJ2mC1b!c3dLz^2OR(-euchLP15 z^KXCrT#Uz<*{v@7_&bG!=OlWqK|~DOt_rHslpvExlSVbvwK=9A(}ST6Wm*HWX#o_W zDVu)mDNLn0UIdGfF?it{?*1IQ@VOCSbkp}y5JE=J zCz8)sY363E^bol;=7;@s&<5q7(gi0V_tiHi>OP;dIy$GVm>fWe#VS8d!gMVQD{R&f z0=H51`Dh4jr8)jw;T}tgb-5X~Sn=z;qKAqQA>7qD`s4vko&p0%5l;jzRV``KO*7mL zVIV-p72sh{9R`cQbvmllEOeAs^Uxw@l5lr5*cX&oyoR{sqTSSRuU(^#G=2Yi64UpP zLiX`_k9=w_zE6!(iuNe{Q9qIQP*d^wZn$goAO*w1{sYbvKKRN<%&=MtT zTaGO25A?bPeTP4GgP1?u9(xAYyY))3;kyq(Fqns8G$mV1d ziLGIT+(e|h!04;?scqx2ZWpNsY4U1MyS(ElS1GLl^YFJp4FfLOjX^f(a_kc498oL* zJT@tIr-zfL6M{z_nkuFAWh4@SVQa`4cm!zI9`lQn^jR&-dUozV_Zx@A0(eZOMHN!D z2z?#*&?bPN!rQ~Ir6p_hw3<{5=Ue4&()P8N#?nbD0{C$)LzEEhvKve(e0^Su0Sf4k hh3J}J{`425$p0a7^S$}ds;U40002ovPDHLkV1kdV^ArF8 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/success.png.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/success.png.meta deleted file mode 100644 index c08b383..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/success.png.meta +++ /dev/null @@ -1,128 +0,0 @@ -fileFormatVersion: 2 -guid: 832e106a677623145b3d8dbe015e31a0 -TextureImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 11 - mipmaps: - mipMapMode: 0 - enableMipMap: 1 - sRGBTexture: 1 - linearTexture: 0 - fadeOut: 0 - borderMipMap: 0 - mipMapsPreserveCoverage: 0 - alphaTestReferenceValue: 0.5 - mipMapFadeDistanceStart: 1 - mipMapFadeDistanceEnd: 3 - bumpmap: - convertToNormalMap: 0 - externalNormalMap: 0 - heightScale: 0.25 - normalMapFilter: 0 - isReadable: 0 - streamingMipmaps: 0 - streamingMipmapsPriority: 0 - grayScaleToAlpha: 0 - generateCubemap: 6 - cubemapConvolution: 0 - seamlessCubemap: 0 - textureFormat: 1 - maxTextureSize: 2048 - textureSettings: - serializedVersion: 2 - filterMode: 2 - aniso: 0 - mipBias: 0 - wrapU: 1 - wrapV: 1 - wrapW: 1 - nPOTScale: 0 - lightmap: 0 - compressionQuality: 50 - spriteMode: 1 - spriteExtrude: 0 - spriteMeshType: 1 - alignment: 0 - spritePivot: {x: 0.5, y: 0.5} - spritePixelsToUnits: 100 - spriteBorder: {x: 0, y: 0, z: 0, w: 0} - spriteGenerateFallbackPhysicsShape: 0 - alphaUsage: 1 - alphaIsTransparency: 1 - spriteTessellationDetail: -1 - textureType: 8 - textureShape: 1 - singleChannelComponent: 0 - maxTextureSizeSet: 0 - compressionQualitySet: 0 - textureFormatSet: 0 - applyGammaDecoding: 0 - platformSettings: - - serializedVersion: 3 - buildTarget: DefaultTexturePlatform - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Standalone - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: iPhone - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Android - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - spriteSheet: - serializedVersion: 2 - sprites: [] - outline: [] - physicsShape: [] - bones: [] - spriteID: 5e97eb03825dee720800000000000000 - internalID: 0 - vertices: [] - indices: - edges: [] - weights: [] - secondaryTextures: [] - spritePackingTag: - pSDRemoveMatte: 0 - pSDShowRemoveMatteOption: 0 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/success_d.png b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/success_d.png deleted file mode 100644 index 094a810f9ec5788ff713a0780fd3010c81151c37..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1617 zcmV-X2Cn&uP)@~0drDELIAGL9O(c600d`2O+f$vv5yPJwrV6PtsY1GBCgamFnMqO^cj*jON|Q1bQs)l2 z^8g8#KfsJ!2GDKZ+eMLN-Rbu3_LLL;%m^LQo}_*E_U-$10%hZ`N%~ud=&r*P5(@Oc zm;;m?9w!x?5QZobfim#dc*2h%yzSA6W+sGEO{m%-g4azr#+?9s zIR|fcmyW)n#~jKbq(=kMRm+uT6c@l`CjKrR(uxD9>t{s;Q9}{-R(Bz4FX-qIJ?>$0 z+=CFG(syrT>wX8#H?NSBd>X)p%~Q{5eb-S9$Z%e5<6wUI4+$0e#6=s6KT(T#z`v{M}}- zoec<1 z8j&mjw)VhJn0DA-*qncxv^&Jx0KLygwC*S7*_8|hS<&@_I6ooY26)ji?#$#Fiax!W zSbH$K1pMV4QkxyzIfRT`3d2jls6JnPi93m23X8N9I=xqhmw?x0!zWR7I6nZfs~-Xf z_9xO(5VJ$OT3-XE#_)A_;Qx6z^pd~4LD?otyEUu@0~*k+qw14aQDbECOmNnQhyqwK ztOb1mc)~}u3DG!Do@Dpt0GueXL8#r{p%DP*@T$J{Io=HX*k8$-6yKqPjG!u6`}bYQrRcT>O|c zAgXSt%b8#Q^e}ZCd#?&R$Vzvn?vW?3j%q@w@9XrfP5Uo7cQBYpyAjxvGU1sw1Jio#cH*hderx3ml8Jwuns;$SGFn(M%cUQs{3LQ`P*%JDxUqg0iyRj02daVX@Mr65X_!mUXq4`t^wa;I2v@T1xz*}l;iFWGE!q0 z765C3b&=5;J0XRc`bhJ-M4 zLe9-_9gCee^#a+bd&y*<8Dlshc9?sJxQ3R`7i++F|t+p$AnL$JcVL+@#`G?SFgsVe%) zr%#@-zh9vF=IAz&QAd^GZW90eYun-3?ik^0&cpe)Bn38%Rl941t5V;MZKR69&IY_o z)jCS`jg^#K&Cy4cPXImGcQ@{<#Q#G__Yv5X(i13l-(c&qjm?iJn-sBa;Je5swJa!d zjee%9{y7?dwNQX!8Zd}XVRh>zYeYvIIgaQC8lH>bP5^@hOPl&WKGS|DQ4GF$`iQo+ zqh1=zCFKZU5ObI5IyWT2I8%~4GcYQckZX1N8C0#Jq6KQ#P5f~2H%jDRfoMCn-b@k~ P00000NkvXXu0mjfDn|lL diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/success_d.png.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/success_d.png.meta deleted file mode 100644 index 6741130..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/success_d.png.meta +++ /dev/null @@ -1,128 +0,0 @@ -fileFormatVersion: 2 -guid: 3dc139a2b2a28a54a8f39e266fc0af9c -TextureImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 11 - mipmaps: - mipMapMode: 0 - enableMipMap: 1 - sRGBTexture: 1 - linearTexture: 0 - fadeOut: 0 - borderMipMap: 0 - mipMapsPreserveCoverage: 0 - alphaTestReferenceValue: 0.5 - mipMapFadeDistanceStart: 1 - mipMapFadeDistanceEnd: 3 - bumpmap: - convertToNormalMap: 0 - externalNormalMap: 0 - heightScale: 0.25 - normalMapFilter: 0 - isReadable: 0 - streamingMipmaps: 0 - streamingMipmapsPriority: 0 - grayScaleToAlpha: 0 - generateCubemap: 6 - cubemapConvolution: 0 - seamlessCubemap: 0 - textureFormat: 1 - maxTextureSize: 2048 - textureSettings: - serializedVersion: 2 - filterMode: 2 - aniso: 0 - mipBias: 0 - wrapU: 1 - wrapV: 1 - wrapW: 1 - nPOTScale: 0 - lightmap: 0 - compressionQuality: 50 - spriteMode: 1 - spriteExtrude: 0 - spriteMeshType: 1 - alignment: 0 - spritePivot: {x: 0.5, y: 0.5} - spritePixelsToUnits: 100 - spriteBorder: {x: 0, y: 0, z: 0, w: 0} - spriteGenerateFallbackPhysicsShape: 0 - alphaUsage: 1 - alphaIsTransparency: 1 - spriteTessellationDetail: -1 - textureType: 8 - textureShape: 1 - singleChannelComponent: 0 - maxTextureSizeSet: 0 - compressionQualitySet: 0 - textureFormatSet: 0 - applyGammaDecoding: 0 - platformSettings: - - serializedVersion: 3 - buildTarget: DefaultTexturePlatform - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Standalone - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: iPhone - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Android - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - spriteSheet: - serializedVersion: 2 - sprites: [] - outline: [] - physicsShape: [] - bones: [] - spriteID: 5e97eb03825dee720800000000000000 - internalID: 0 - vertices: [] - indices: - edges: [] - weights: [] - secondaryTextures: [] - spritePackingTag: - pSDRemoveMatte: 0 - pSDShowRemoveMatteOption: 0 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/undefined.png b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/undefined.png deleted file mode 100644 index a587baa45ab11888902d103b690a2f579aeb55c6..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1561 zcmV+!2Il#RP)@~0drDELIAGL9O(c600d`2O+f$vv5yPWQ-qQ%nF9AAlQF?j#xpwgD@+IvjXE4jJ<;39e7rN;^&`{cfhP*`0(-jk$Xvt zgP=<^AY_T;o<`H3g6i$8l=-`aLdXOiVx$h8xhvrw)}JPD;c?1e~3n?P9a1k~2Jn zKoKC}NR5fH2w-4?e}BVQSET@&h{`x>7@2@E@4AnV$1N`QdTD9t|JBvi|9S^pU0wZo ze}7M6%Q|qn_>`4B=ob5%o0|tC{AM%)5Zw>7uiL=GqwVR_ z%X3d)na%ZO8DDioE-r; zc@rleb_b?nct5BLBvlQI{K5wbD?`Q%Ct%o}2Qh8Pl!hOw1YsGAhAJVF0Qh_jOz%m@ znZClu;o_B+dIwml;Q%Cjl@5voXomk$GJNFtm2m@HTmT70%o!RgI!Jz%o(@I=^mD$c zWO-Q!nWQkpRq3WHraZwhjmE@-j7rA)X)~VK-rlaNpZSIfMV+_}V1NKb{3@rcror@i z%3h@uyf$8=aM;yu9YV+jD1F|269J6&2zV>+74U4qz=)V2xo;aJedvu_AqBv|UFq)g zQI~e(34M+G!r@|}PzYtRT?Ir1KFSK|0XAM3f3>Grx2Qh)5v(jg1ZI z*_wJpsQ@?j6Ssj2xWeBUsko3v;N~8i_Cp;zo#TxDlKc@Zr#iJw0uK)l#(E(qP^>~Z zFjAUC_*o2o{m_p)qZ{Ae-ntGFoR7k9JvBSz|P z%qnw$%8j9~OU#qpZ}^^3!iN=VF- z)Qo`Hu4zAQXAm?-$h*6{Kh%r>^^B5fKW%q(3(5e%j+7y04pO$;SyqpzqK>jOooXNx zED48vM@kb_N}3;Hf-CIz9h8tg;b57|PAcQj0nn)C$H&KOhgp*31`7)dHvIsphA#FF zfHrfw-^l|I4332#@2HGJH&qM(HhbJUdeFbZ@7ZUPHcEm75+FwZN!rxoKvYjt0Qx;vxTUxjT@z%7CEwMN zj`PH9t9g${B+tonM;Q;)ql_o4nx%0v_6|iBNRmfB=XKRr=+75fR7B z8WRyf=-%8foO^?aMCJ)J94>Xh$=jrf*u(?`2;T6TrXu1rJV0y&^y1>;;x7a-w%xmv zlA+%!KW4kzG+xM>3IV;KG75zPm!>)eN}Jc`b(!8@US9U5-Kg;citj8D^E^DF00000 LNkvXXu0mjfE@~0drDELIAGL9O(c600d`2O+f$vv5yP!L61qvbnXHd(nK6-M0ZLRq)TUxM$#x%=r1t+1*WPbRje-%RYjv$=rWb*D(M2v z=v5+Jx-g~n^f}a$LqdB25CkZI_L(68VwV8!-LrS^-n~1aQbxI4wx_43ox8icCH%A} zCMNhP;J4jd57#_gYvJSJr;Fq9&CQM5Xf!;PA|_M{SY2IpaCmN6R@pCT40!l7ai5)o zgM+3@7>OwWEnS$InW^GMU*cy$r33Hw_O=FQyibZ5Ln~lJg8R`zm#JS~UTzJmh)FdB z*4Njop!x4O{T`n$)abxxEl*BPmgnc^Tj%HJ$0{abF<@h3!v+nvaq6gSz`MG-`YsL| z237!D9dv)K2BSNzdJ}BvSoi;qj*kB6t+2AP@)cUt#%YO$6BKuNuA+k@$R-Tsn*sha zm;%<;)_C)mQR-4)2+=^x?4V^@Dh4#u9R18l%D^)>_xAQ`Dk35)04-mKP(Oy%(}LIb z_xInc1Oeq!0aQdKLiIYH{~|)YXbQl?|5hO_ke1+nkQEpT-$n2*T)fM(kUHTCh|uz+ zHwE8PBLtkSDij`Oi$a+Yr~n9G(*{pMZ0nl@qObug62sx36uGZRxS zQ*F{p$-=u?6P^IgD>%49aRD>ZZBxMm1;FB00{T?D&#R1r@5X7hQ0&lf`Y-l%fe@o2 z(kM#^>AsZVX|H3}#{m4X8qoT+tP4-0-#=A30=hEo zm}4mFV?mbz+UGVJzAX292~ku-S61=%s;c8hH)!}Y$E zuD;n|7z>#Ct}+fC=9d`jX&JldQ-EfHxSRyP;9ZuTBfeWub_@HyKh*yq9-vcAo5~Ds zevtasql51jl-+W8c=%wE#265Pd(0dlDUevg_`0n!1|~@YgPu$UaL|fr9TH8K?|F&WOo@+J-DQHsFgv`o zfuqtnEq9{)hu&-$?RzosmYIlY>VCL-KLK<2j^T}Yex>LQmb@po%q+#(GNWRo?Z@6U z6>-zTNI>O6sV_#dX{r~@D<&HrQ4z6Py%$668^qA(E-o&1qDdT!N40m5bC#dc>OWu= zd#F67#J0|Mc6g=Ci1w77GrFWa&{Q^0qicMN1G|Tl#O7(-qrokBX>7&srwe@kxN!C{?|-9QR5?S!Zrk)7b(5~0000@~0drDELIAGL9O(c600d`2O+f$vv5yPCK-7Tf=r0c-Pk}4} zDbZg@m;x~alB2&okSqmq1aL%uAwdd63}B1?@_=#_JOc?iqi>eG1UG;*TkaCJ0rAAT z%anr0J}`^D7MMm~(HBb>Q}AGSv+A4G3e|GiLQXj``|+BQkt_`Y}}&fmTjA@3L<-^wh>Sjc+qcZ~ zqqv1q0tHb9uxI|2G{h)@f;a+F#{T3{H#e5?OXWxkf(=N&(u>;C7;iu%1>pq9Wd8ZF zJ?a3PA}9zlfM@KZwzQ>HixCur5x^0BvR*JrFP8%;@HRj&^RMJv2iO!yfj{Kx*ty#_jEmB|ia`927JfARGPSWP1}FgM=IuG~OJg z+r6J4i9ga6Ov-B$gBBEcTK!Ov5<(vj9=i2SHS)N_`|qjY&T{<_$T#ojQ$sG;A|Oxn zX=wgjnr~k`Aki^@k3f3Hsi9!o0O_%BZjl4MJj3pAxVE`^K%yuwj2TBDrJ7uT8$Uui z`U5ysz$kmb)Fup*aPZchy(D z52W5UJt^k(tRSb%jG&+(nIfcC=CZdr!MftaoO~zi$yYKIAl<(Bm3%!uPIqgM%1X}t zjiRA3V2@yjrRMAM9Tg3g_0iP-UFO`40qPodRRvutGbQz*DouAzbdK-FKc)*IQ=ypx z1kYi2bcu(*KUE(#%HdaS!11Zsdi0m3MnTQrQc>mA)1vGT7ki%c0W64H00000NkvXX Hu0mjf^t1iH diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/warning.png.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/warning.png.meta deleted file mode 100644 index 05dd39d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/warning.png.meta +++ /dev/null @@ -1,128 +0,0 @@ -fileFormatVersion: 2 -guid: 83d0e58aa5f608a4b8232fbacca5ca89 -TextureImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 11 - mipmaps: - mipMapMode: 0 - enableMipMap: 1 - sRGBTexture: 1 - linearTexture: 0 - fadeOut: 0 - borderMipMap: 0 - mipMapsPreserveCoverage: 0 - alphaTestReferenceValue: 0.5 - mipMapFadeDistanceStart: 1 - mipMapFadeDistanceEnd: 3 - bumpmap: - convertToNormalMap: 0 - externalNormalMap: 0 - heightScale: 0.25 - normalMapFilter: 0 - isReadable: 0 - streamingMipmaps: 0 - streamingMipmapsPriority: 0 - grayScaleToAlpha: 0 - generateCubemap: 6 - cubemapConvolution: 0 - seamlessCubemap: 0 - textureFormat: 1 - maxTextureSize: 2048 - textureSettings: - serializedVersion: 2 - filterMode: 2 - aniso: 0 - mipBias: 0 - wrapU: 1 - wrapV: 1 - wrapW: 1 - nPOTScale: 0 - lightmap: 0 - compressionQuality: 50 - spriteMode: 1 - spriteExtrude: 0 - spriteMeshType: 1 - alignment: 0 - spritePivot: {x: 0.5, y: 0.5} - spritePixelsToUnits: 100 - spriteBorder: {x: 0, y: 0, z: 0, w: 0} - spriteGenerateFallbackPhysicsShape: 0 - alphaUsage: 1 - alphaIsTransparency: 1 - spriteTessellationDetail: -1 - textureType: 8 - textureShape: 1 - singleChannelComponent: 0 - maxTextureSizeSet: 0 - compressionQualitySet: 0 - textureFormatSet: 0 - applyGammaDecoding: 0 - platformSettings: - - serializedVersion: 3 - buildTarget: DefaultTexturePlatform - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Standalone - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: iPhone - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - - serializedVersion: 3 - buildTarget: Android - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 0 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 0 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - spriteSheet: - serializedVersion: 2 - sprites: [] - outline: [] - physicsShape: [] - bones: [] - spriteID: 5e97eb03825dee720800000000000000 - internalID: 0 - vertices: [] - indices: - edges: [] - weights: [] - secondaryTextures: [] - spritePackingTag: - pSDRemoveMatte: 0 - pSDShowRemoveMatteOption: 0 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/warning_d.png b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Icons/warning_d.png deleted file mode 100644 index 553bb16d81ff583b4f190471c02e74418503bd29..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1185 zcmV;S1YY}zP)@~0drDELIAGL9O(c600d`2O+f$vv5yP_5f**n>aBm==3+_%^ zy}N_MGSk!3UDd1d63Aw{hoN4*s;-*uRfvq!JuF=I@sd8S(NAiwDd0>ibTf^e2OH=i zA`~Lx%UiTt3P<$Rg^DS?L54>UpWzIV5RHK2U8IS|sm1s)G|mSaE3rsO5DE04qgvw) zXwF=MZA3y80?7O8n8dpaG|)MIgAO7f3IX(xS7?Ykt>*XmK%9W4-p>(B1>ywwct1xB z6^Ihx>-`)tR3J(~i1%|yt3Zr^Q19oER)H7+9Ny0%sR9uKxV)c3QUxstpw|0T?o#vf z3E8;ZO%k-p$aUK-6BTs94EA2Yc%KN^vrOq_z{+&jH|iBkxolBRHlX{S^OC?G0(IUm zGv2^lGh?=UC2|2P0d=uYGT*oL`=c=v8rAo+=K@v&YGZ#`ZCs9Qh(p^rw+h$@aLN2C zacGBYz^wu{0=U+FS`qHm&EZr53jxmSzH*vVs}fEXun^$teeFP!)^1_KrGj7rxU0Uz z@o#adAeexLv7b83aZZ#RDhMK=srQvj2s9voLj^$uaCUqJq)jG=s=%87&)83GgJ#zV z4H2pWZvuS1|LtS-I^Xa66-ps0@FIXa^B0i910gE#A|NF82ba}GCfdJL_EkY+0vO)( zrd4BE00F)#XiR`m<{$rUhd#gt9~CqrfF<^A{eTMV7JXFEhyV`n+d@F=@OHVW3Y-ZL z%=}kKX0VUoOaNo-r8U#?Mg38U&lU@9Pp#04?nI7OExq}6z@WT9~5CR$5UD_z$cPu5qVTbph zL)Ff5X$VAI_oJaI7u--l6z^-C)01B(YJ5NjPK9g#pdE; zBH<4XiTE8_3ASm%DuhsW%H)~?B6z>Iyn*{wgQgn%)yEMf#5RO5t%7SgK-~MAD~(e2~ukJ(o#Sxj_U)6^saoRP(1U9iKTZ z24NIckW79>S@$n4oXXt}A|O|Ridyy2`kyH*R-F`cIV;Esvm#I_F4KgRf?j(Y1IwBd zGQJbjcmtyXb@C2BL*K{yzUfwJu_^lvk{MLsPYDX^00000NkvXXu0mjf String.Compare(x, category, StringComparison.OrdinalIgnoreCase) == 0); - - if (IsInclusiveFilter) - { - if (isCategoryInFilter) - return IsFailFilter ? TestResultStatus.Fail : TestResultStatus.Warning; - else - return IsFailFilter ? TestResultStatus.Warning : TestResultStatus.Fail; - } - else - { - if (isCategoryInFilter) - return IsFailFilter ? TestResultStatus.Warning : TestResultStatus.Fail; - else - return IsFailFilter ? TestResultStatus.Fail : TestResultStatus.Warning; - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Categories/ValidatorCategory.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Categories/ValidatorCategory.cs.meta deleted file mode 100644 index 2690769..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Categories/ValidatorCategory.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: a5e60d3639f24063a4eabc21ea1a04a9 -timeCreated: 1657617578 \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/CurrentProjectValidator.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/CurrentProjectValidator.cs deleted file mode 100644 index 79ef18c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/CurrentProjectValidator.cs +++ /dev/null @@ -1,71 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.TestDefinitions; -using System; -using System.IO; - -namespace AssetStoreTools.Validator -{ - internal class CurrentProjectValidator : ValidatorBase - { - private CurrentProjectValidationSettings _settings; - - public CurrentProjectValidator(CurrentProjectValidationSettings settings) : base(settings) - { - _settings = settings; - } - - protected override void ValidateSettings() - { - if (_settings == null) - throw new Exception("Validation Settings is null"); - - if (_settings.ValidationPaths == null - || _settings.ValidationPaths.Count == 0) - throw new Exception("No validation paths were set"); - - switch (_settings.ValidationType) - { - case ValidationType.Generic: - case ValidationType.UnityPackage: - ValidateUnityPackageSettings(); - break; - default: - throw new NotImplementedException("Undefined validation type"); - } - } - - private void ValidateUnityPackageSettings() - { - var invalidPaths = string.Empty; - foreach (var path in _settings.ValidationPaths) - { - if (!Directory.Exists(path)) - invalidPaths += $"\n{path}"; - } - - if (!string.IsNullOrEmpty(invalidPaths)) - throw new Exception("The following directories do not exist:" + invalidPaths); - } - - protected override ValidationResult GenerateValidationResult() - { - ITestConfig config; - var applicableTests = GetApplicableTests(ValidationType.Generic); - switch (_settings.ValidationType) - { - case ValidationType.Generic: - config = new GenericTestConfig() { ValidationPaths = _settings.ValidationPaths.ToArray() }; - break; - case ValidationType.UnityPackage: - applicableTests.AddRange(GetApplicableTests(ValidationType.UnityPackage)); - config = new GenericTestConfig() { ValidationPaths = _settings.ValidationPaths.ToArray() }; - break; - default: - return new ValidationResult() { Status = ValidationStatus.Failed, Exception = new Exception("Undefined validation type") }; - } - - var validationResult = RunTests(applicableTests, config); - return validationResult; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/CurrentProjectValidator.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/CurrentProjectValidator.cs.meta deleted file mode 100644 index ca8fe3d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/CurrentProjectValidator.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 3a6371dcfa8545c478545b4a43433599 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data.meta deleted file mode 100644 index 3b40063..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 1c2a38ded8e054c4088aff1db7224f66 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/CurrentProjectValidationSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/CurrentProjectValidationSettings.cs deleted file mode 100644 index 6b83057..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/CurrentProjectValidationSettings.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System.Collections.Generic; -using System.Linq; - -namespace AssetStoreTools.Validator.Data -{ - internal class CurrentProjectValidationSettings : ValidationSettings - { - public List ValidationPaths; - public ValidationType ValidationType; - - public CurrentProjectValidationSettings() - { - Category = string.Empty; - ValidationPaths = new List(); - } - - public override int GetHashCode() - { - return base.GetHashCode(); - } - - public override bool Equals(object obj) - { - if (obj == null || obj.GetType() != typeof(CurrentProjectValidationSettings)) - return false; - - var other = (CurrentProjectValidationSettings)obj; - return Category == other.Category - && ValidationType == other.ValidationType - && ValidationPaths.OrderBy(x => x).SequenceEqual(other.ValidationPaths.OrderBy(x => x)); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/CurrentProjectValidationSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/CurrentProjectValidationSettings.cs.meta deleted file mode 100644 index cf2630a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/CurrentProjectValidationSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 9e4a4a4aa3f501847b1abb1e08505f9b -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ExternalProjectValidationSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ExternalProjectValidationSettings.cs deleted file mode 100644 index f770cd4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ExternalProjectValidationSettings.cs +++ /dev/null @@ -1,7 +0,0 @@ -namespace AssetStoreTools.Validator.Data -{ - internal class ExternalProjectValidationSettings : ValidationSettings - { - public string PackagePath; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ExternalProjectValidationSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ExternalProjectValidationSettings.cs.meta deleted file mode 100644 index a7a30e0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ExternalProjectValidationSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: f79c895f4bb099b4983dd20eef72a7bd -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions.meta deleted file mode 100644 index 7f0bd9a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: d51c5c866dcd449488caa10a40dd3301 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/HighlightObjectAction.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/HighlightObjectAction.cs deleted file mode 100644 index e642904..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/HighlightObjectAction.cs +++ /dev/null @@ -1,31 +0,0 @@ -using Newtonsoft.Json; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator.Data.MessageActions -{ - internal class HighlightObjectAction : IMessageAction - { - public string Tooltip => "Click to highlight the associated object in Hierarchy/Project view"; - public Object Target => _target?.GetObject(); - - [JsonProperty] - private TestResultObject _target; - - public HighlightObjectAction() { } - - public HighlightObjectAction(Object target) - { - _target = new TestResultObject(target); - } - - public void Execute() - { - var targetObject = _target.GetObject(); - if (targetObject == null) - return; - - EditorGUIUtility.PingObject(targetObject); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/HighlightObjectAction.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/HighlightObjectAction.cs.meta deleted file mode 100644 index f9d8e9c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/HighlightObjectAction.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: de24c0a7f8a22c142a224e6abd0ddc68 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/IMessageAction.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/IMessageAction.cs deleted file mode 100644 index ec48b5b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/IMessageAction.cs +++ /dev/null @@ -1,16 +0,0 @@ -using Newtonsoft.Json; -using UnityEngine; - -namespace AssetStoreTools.Validator.Data.MessageActions -{ - internal interface IMessageAction - { - [JsonIgnore] - string Tooltip { get; } - - [JsonIgnore] - Object Target { get; } - - void Execute(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/IMessageAction.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/IMessageAction.cs.meta deleted file mode 100644 index db2e565..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/IMessageAction.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: f1636d7241abdf1498368f841aa818a2 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/OpenAssetAction.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/OpenAssetAction.cs deleted file mode 100644 index fb5dfa5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/OpenAssetAction.cs +++ /dev/null @@ -1,38 +0,0 @@ -using Newtonsoft.Json; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator.Data.MessageActions -{ - internal class OpenAssetAction : IMessageAction - { - public string Tooltip => "Click to open the associated asset"; - public Object Target => _target?.GetObject(); - - [JsonProperty] - private TestResultObject _target; - [JsonProperty] - private int _lineNumber; - - public OpenAssetAction() { } - - public OpenAssetAction(Object target) - { - _target = new TestResultObject(target); - } - - public OpenAssetAction(Object target, int lineNumber) : this(target) - { - _lineNumber = lineNumber; - } - - public void Execute() - { - var targetObject = _target.GetObject(); - if (targetObject == null) - return; - - AssetDatabase.OpenAsset(targetObject, _lineNumber); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/OpenAssetAction.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/OpenAssetAction.cs.meta deleted file mode 100644 index 83519a6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/MessageActions/OpenAssetAction.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 9fb4fec293bf73f4a8f870c535750613 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResult.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResult.cs deleted file mode 100644 index 21d1dd0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResult.cs +++ /dev/null @@ -1,52 +0,0 @@ -using AssetStoreTools.Validator.Data.MessageActions; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace AssetStoreTools.Validator.Data -{ - internal struct TestResult - { - public TestResultStatus Status; - - [JsonProperty] - private List _messages; - - [JsonIgnore] - public int MessageCount => _messages != null ? _messages.Count : 0; - - public TestResultMessage GetMessage(int index) - { - return _messages[index]; - } - - public void AddMessage(string msg) - { - AddMessage(msg, null, null); - } - - public void AddMessage(string msg, IMessageAction clickAction) - { - AddMessage(msg, clickAction, null); - } - - public void AddMessage(string msg, IMessageAction clickAction, params UnityEngine.Object[] messageObjects) - { - if (_messages == null) - _messages = new List(); - - var message = new TestResultMessage(msg, clickAction); - _messages.Add(message); - - if (messageObjects == null) - return; - - foreach (var obj in messageObjects) - { - if (obj == null) - continue; - - message.AddMessageObject(obj); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResult.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResult.cs.meta deleted file mode 100644 index ec1467f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResult.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 05d7d92bbda6bf44f8ed5fbd0cde57e6 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultMessage.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultMessage.cs deleted file mode 100644 index 7ebe0f5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultMessage.cs +++ /dev/null @@ -1,53 +0,0 @@ -using AssetStoreTools.Validator.Data.MessageActions; -using Newtonsoft.Json; -using System.Collections.Generic; -using Object = UnityEngine.Object; - -namespace AssetStoreTools.Validator.Data -{ - internal class TestResultMessage - { - [JsonIgnore] - public int MessageObjectCount => _messageObjects.Count; - - [JsonProperty] - private string _text; - [JsonProperty] - private List _messageObjects; - [JsonProperty] - private IMessageAction _clickAction; - - public TestResultMessage() { } - - public TestResultMessage(string text) - { - _text = text; - _messageObjects = new List(); - } - - public TestResultMessage(string text, IMessageAction clickAction) : this(text) - { - _clickAction = clickAction; - } - - public string GetText() - { - return _text; - } - - public IMessageAction GetClickAction() - { - return _clickAction; - } - - public void AddMessageObject(Object obj) - { - _messageObjects.Add(new TestResultObject(obj)); - } - - public TestResultObject GetMessageObject(int index) - { - return _messageObjects[index]; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultMessage.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultMessage.cs.meta deleted file mode 100644 index 2f0262f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultMessage.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 0761356c44140ca49917f93b42926471 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultObject.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultObject.cs deleted file mode 100644 index 8b601d5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultObject.cs +++ /dev/null @@ -1,35 +0,0 @@ -using Newtonsoft.Json; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator.Data -{ - internal class TestResultObject - { - [JsonIgnore] - private Object _object; - [JsonProperty] - private string _objectGlobalId; - - public TestResultObject(Object obj) - { - _object = obj; - _objectGlobalId = GlobalObjectId.GetGlobalObjectIdSlow(obj).ToString(); - } - - public Object GetObject() - { - if (_object != null) - return _object; - - if (string.IsNullOrEmpty(_objectGlobalId)) - return null; - - if (!GlobalObjectId.TryParse(_objectGlobalId, out var globalObject)) - return null; - - _object = GlobalObjectId.GlobalObjectIdentifierToObjectSlow(globalObject); - return _object; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultObject.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultObject.cs.meta deleted file mode 100644 index a688e88..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultObject.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: acce8e477b7fe2c4aa430ebdd65ea7d1 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultStatus.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultStatus.cs deleted file mode 100644 index ccda879..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultStatus.cs +++ /dev/null @@ -1,11 +0,0 @@ -namespace AssetStoreTools.Validator.Data -{ - internal enum TestResultStatus - { - Undefined = 0, - Pass = 1, - Fail = 2, - Warning = 3, - VariableSeverityIssue = 4 - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultStatus.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultStatus.cs.meta deleted file mode 100644 index 7e7401a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/TestResultStatus.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: eef1ba0cf35f1304d8929e23b94e7c23 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationResult.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationResult.cs deleted file mode 100644 index 89ae633..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationResult.cs +++ /dev/null @@ -1,24 +0,0 @@ -using AssetStoreTools.Validator.TestDefinitions; -using System; -using System.Collections.Generic; - -namespace AssetStoreTools.Validator.Data -{ - internal class ValidationResult - { - public ValidationStatus Status; - public bool HadCompilationErrors; - public string ProjectPath; - public List Tests; - public Exception Exception; - - public ValidationResult() - { - Status = ValidationStatus.NotRun; - HadCompilationErrors = false; - ProjectPath = string.Empty; - Tests = new List(); - Exception = null; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationResult.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationResult.cs.meta deleted file mode 100644 index da48108..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationResult.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: b15525b8dcf3e654ca2f895472ab7cb1 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationSettings.cs deleted file mode 100644 index 5b51134..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationSettings.cs +++ /dev/null @@ -1,7 +0,0 @@ -namespace AssetStoreTools.Validator.Data -{ - internal abstract class ValidationSettings - { - public string Category; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationSettings.cs.meta deleted file mode 100644 index 7783188..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 33e99d6b6e1e7ef4abd6cd2c0137741a -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationStatus.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationStatus.cs deleted file mode 100644 index f0fb66c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationStatus.cs +++ /dev/null @@ -1,10 +0,0 @@ -namespace AssetStoreTools.Validator.Data -{ - internal enum ValidationStatus - { - NotRun, - RanToCompletion, - Failed, - Cancelled - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationStatus.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationStatus.cs.meta deleted file mode 100644 index 32b6657..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationStatus.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a1f1e1e94faa6284f8d71804ba2bbd24 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationType.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationType.cs deleted file mode 100644 index dd3b51c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationType.cs +++ /dev/null @@ -1,8 +0,0 @@ -namespace AssetStoreTools.Validator.Data -{ - internal enum ValidationType - { - Generic = 0, - UnityPackage = 1 - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationType.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationType.cs.meta deleted file mode 100644 index dca424c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Data/ValidationType.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 079f8963464230145853d86eff935e04 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ExternalProjectValidator.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ExternalProjectValidator.cs deleted file mode 100644 index 3556d1a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ExternalProjectValidator.cs +++ /dev/null @@ -1,259 +0,0 @@ -using AssetStoreTools.Utility; -using AssetStoreTools.Validator.Data; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Threading; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator -{ - internal class ExternalProjectValidator : ValidatorBase - { - private ExternalProjectValidationSettings _settings; - - public ExternalProjectValidator(ExternalProjectValidationSettings settings) : base(settings) - { - _settings = settings; - } - - protected override void ValidateSettings() - { - if (_settings == null) - throw new Exception("Validation Settings is null"); - - if (string.IsNullOrEmpty(_settings.PackagePath) - || !File.Exists(_settings.PackagePath)) - throw new Exception("Package was not found"); - } - - protected override ValidationResult GenerateValidationResult() - { - bool interactiveMode = false; - try - { - // Step 1 - prepare a temporary project - var result = PrepareTemporaryValidationProject(interactiveMode); - - // If preparation was cancelled or setting up project failed - return immediately - if (result.Status == ValidationStatus.Cancelled || result.Status == ValidationStatus.Failed) - return result; - - // Step 2 - load the temporary project and validate the package - result = ValidateTemporaryValidationProject(result, interactiveMode); - - // Step 3 - copy validation results - result = ParseValidationResult(result.ProjectPath); - - return result; - } - catch (Exception e) - { - return new ValidationResult() { Status = ValidationStatus.Failed, Exception = e }; - } - finally - { - EditorUtility.ClearProgressBar(); - } - } - - private ValidationResult PrepareTemporaryValidationProject(bool interactiveMode) - { - EditorUtility.DisplayProgressBar("Validating...", "Preparing the validation project. This may take a while.", 0.3f); - - var result = new ValidationResult(); - var tempProjectPath = Path.Combine(Constants.RootProjectPath, "Temp", GUID.Generate().ToString()).Replace("\\", "/"); - result.ProjectPath = tempProjectPath; - - if (!Directory.Exists(tempProjectPath)) - Directory.CreateDirectory(tempProjectPath); - - // Cannot edit a package.json file that does not yet exist - copy over AST instead - var tempPackagesPath = $"{tempProjectPath}/Packages"; - if (!Directory.Exists(tempPackagesPath)) - Directory.CreateDirectory(tempPackagesPath); - var assetStoreToolsPath = PackageUtility.GetAllPackages().FirstOrDefault(x => x.name == "com.unity.asset-store-tools").resolvedPath.Replace("\\", "/"); - FileUtility.CopyDirectory(assetStoreToolsPath, $"{tempPackagesPath}/com.unity.asset-store-tools", true); - - var logFilePath = $"{tempProjectPath}/preparation.log"; - - // Create the temporary project - var processInfo = new System.Diagnostics.ProcessStartInfo() - { - FileName = Constants.UnityPath, - Arguments = $"-createProject \"{tempProjectPath}\" -logFile \"{logFilePath}\" -importpackage \"{Path.GetFullPath(_settings.PackagePath)}\" -quit" - }; - - if (!interactiveMode) - processInfo.Arguments += " -batchmode"; - - var exitCode = 0; - - using (var process = System.Diagnostics.Process.Start(processInfo)) - { - while (!process.HasExited) - { - if (EditorUtility.DisplayCancelableProgressBar("Validating...", "Preparing the validation project. This may take a while.", 0.3f)) - process.Kill(); - - Thread.Sleep(10); - } - - exitCode = process.ExitCode; - - // Windows and MacOS exit codes - if (exitCode == -1 || exitCode == 137) - { - result.Status = ValidationStatus.Cancelled; - return result; - } - } - - if (exitCode != 0) - { - result.Status = ValidationStatus.Failed; - result.Exception = new Exception($"Setting up the temporary project failed (exit code {exitCode})\n\nMore information can be found in the log file: {logFilePath}"); - } - else - { - result.Status = ValidationStatus.RanToCompletion; - } - - return result; - } - - private ValidationResult ValidateTemporaryValidationProject(ValidationResult result, bool interactiveMode) - { - EditorUtility.DisplayProgressBar("Validating...", "Performing validation...", 0.6f); - - var logFilePath = $"{result.ProjectPath}/validation.log"; - var processInfo = new System.Diagnostics.ProcessStartInfo() - { - FileName = Constants.UnityPath, - Arguments = $"-projectPath \"{result.ProjectPath}\" -logFile \"{logFilePath}\" -executeMethod AssetStoreTools.Validator.ExternalProjectValidator.ValidateProject -category \"{_settings.Category}\"" - }; - - if (!interactiveMode) - processInfo.Arguments += " -batchmode -ignorecompilererrors"; - - var exitCode = 0; - - using (var process = System.Diagnostics.Process.Start(processInfo)) - { - process.WaitForExit(); - exitCode = process.ExitCode; - } - - if (exitCode != 0) - { - result.Status = ValidationStatus.Failed; - result.Exception = new Exception($"Validating the temporary project failed (exit code {exitCode})\n\nMore information can be found in the log file: {logFilePath}"); - } - else - { - result.Status = ValidationStatus.RanToCompletion; - } - - return result; - } - - private ValidationResult ParseValidationResult(string externalProjectPath) - { - if (!CachingService.GetCachedValidatorStateData(externalProjectPath, out var validationStateData)) - throw new Exception("Could not find external project's validation results"); - - var cachedResult = validationStateData.GetResults(); - var cachedTestResults = cachedResult.GetResults(); - var tests = GetApplicableTests(ValidationType.Generic, ValidationType.UnityPackage); - - foreach (var test in tests) - { - if (!cachedTestResults.Any(x => x.Key == test.Id)) - continue; - - var matchingTest = cachedTestResults.First(x => x.Key == test.Id); - test.Result = matchingTest.Value; - } - - var result = new ValidationResult() - { - Status = cachedResult.GetStatus(), - HadCompilationErrors = cachedResult.GetHadCompilationErrors(), - ProjectPath = cachedResult.GetProjectPath(), - Tests = tests - }; - - return result; - } - - public static void OpenExternalValidationProject(string projectPath) - { - var unityPath = Constants.UnityPath; - var logFilePath = $"{projectPath}/editor.log"; - - var processInfo = new System.Diagnostics.ProcessStartInfo() - { - FileName = unityPath, - Arguments = $"-projectPath \"{projectPath}\" -logFile \"{logFilePath}\" -executeMethod AssetStoreTools.AssetStoreTools.ShowAssetStoreToolsValidator" - }; - - using (var process = System.Diagnostics.Process.Start(processInfo)) - { - process.WaitForExit(); - } - } - - // Invoked via Command Line Arguments - private static void ValidateProject() - { - var exitCode = 0; - try - { - // Determine whether to validate Assets folder or Packages folders - var validationPaths = new List(); - var packageDirectories = Directory.GetDirectories("Packages", "*", SearchOption.TopDirectoryOnly) - .Select(x => x.Replace("\\", "/")) - .Where(x => x != "Packages/com.unity.asset-store-tools").ToArray(); - - if (packageDirectories.Length > 0) - validationPaths.AddRange(packageDirectories); - else - validationPaths.Add("Assets"); - - // Parse category - var category = string.Empty; - var args = Environment.GetCommandLineArgs().ToList(); - var categoryIndex = args.IndexOf("-category"); - if (categoryIndex != -1 && categoryIndex + 1 < args.Count) - category = args[categoryIndex + 1]; - - // Run validation - var validationSettings = new CurrentProjectValidationSettings() - { - Category = category, - ValidationPaths = validationPaths, - ValidationType = ValidationType.UnityPackage - }; - - var validator = new CurrentProjectValidator(validationSettings); - var result = validator.Validate(); - - // Display results - AssetStoreTools.ShowAssetStoreToolsValidator(validationSettings, result); - EditorUtility.DisplayDialog("Validation complete", "Package validation complete.\n\nTo resume work in the original project, close this Editor instance", "OK"); - } - catch - { - exitCode = 1; - throw; - } - finally - { - if (Application.isBatchMode) - EditorApplication.Exit(exitCode); - } - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ExternalProjectValidator.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ExternalProjectValidator.cs.meta deleted file mode 100644 index 46e89fb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ExternalProjectValidator.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 2664bbca63a2444498f13beb7e4fa731 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/IValidator.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/IValidator.cs deleted file mode 100644 index bd16b58..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/IValidator.cs +++ /dev/null @@ -1,11 +0,0 @@ -using AssetStoreTools.Validator.Data; - -namespace AssetStoreTools.Validator -{ - internal interface IValidator - { - ValidationSettings Settings { get; } - - ValidationResult Validate(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/IValidator.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/IValidator.cs.meta deleted file mode 100644 index 5a4e713..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/IValidator.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: d49e9393288e0ed418c546e57c4cb425 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services.meta deleted file mode 100644 index 03e4234..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 9315c4052243ab2488208604c11c53c7 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService.meta deleted file mode 100644 index 5d9a1cb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 0a52c1c4a2b7caa458af5b9a212b80a5 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/CachingService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/CachingService.cs deleted file mode 100644 index cff8d95..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/CachingService.cs +++ /dev/null @@ -1,55 +0,0 @@ -using AssetStoreTools.Utility; -using AssetStoreTools.Validator.UI.Data.Serialization; -using Newtonsoft.Json; -using Newtonsoft.Json.Converters; -using System.Collections.Generic; -using System.IO; -using System.Text; - -namespace AssetStoreTools.Validator.Services -{ - internal class CachingService : ICachingService - { - public bool GetCachedValidatorStateData(out ValidatorStateData stateData) - { - return GetCachedValidatorStateData(Constants.RootProjectPath, out stateData); - } - - public bool GetCachedValidatorStateData(string projectPath, out ValidatorStateData stateData) - { - stateData = null; - if (!CacheUtil.GetFileFromProjectPersistentCache(projectPath, Constants.Cache.ValidationResultFile, out var filePath)) - return false; - - try - { - var serializerSettings = new JsonSerializerSettings() - { - ContractResolver = ValidatorStateDataContractResolver.Instance, - TypeNameHandling = TypeNameHandling.Auto, - Converters = new List() { new StringEnumConverter() } - }; - - stateData = JsonConvert.DeserializeObject(File.ReadAllText(filePath, Encoding.UTF8), serializerSettings); - return true; - } - catch - { - return false; - } - } - - public void CacheValidatorStateData(ValidatorStateData stateData) - { - var serializerSettings = new JsonSerializerSettings() - { - ContractResolver = ValidatorStateDataContractResolver.Instance, - Formatting = Formatting.Indented, - TypeNameHandling = TypeNameHandling.Auto, - Converters = new List() { new StringEnumConverter() } - }; - - CacheUtil.CreateFileInPersistentCache(Constants.Cache.ValidationResultFile, JsonConvert.SerializeObject(stateData, serializerSettings), true); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/CachingService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/CachingService.cs.meta deleted file mode 100644 index 00ba6e2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/CachingService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: b2d545f659acb4343bf485ffb20ecf72 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/ICachingService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/ICachingService.cs deleted file mode 100644 index bee25d5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/ICachingService.cs +++ /dev/null @@ -1,11 +0,0 @@ -using AssetStoreTools.Validator.UI.Data.Serialization; - -namespace AssetStoreTools.Validator.Services -{ - internal interface ICachingService : IValidatorService - { - void CacheValidatorStateData(ValidatorStateData stateData); - bool GetCachedValidatorStateData(out ValidatorStateData stateData); - bool GetCachedValidatorStateData(string projectPath, out ValidatorStateData stateData); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/ICachingService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/ICachingService.cs.meta deleted file mode 100644 index 4f5aef4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/ICachingService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a8a3e36c133848447b043a91e709c63e -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/PreviewDatabaseContractResolver.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/PreviewDatabaseContractResolver.cs deleted file mode 100644 index aa495ee..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/PreviewDatabaseContractResolver.cs +++ /dev/null @@ -1,26 +0,0 @@ -using Newtonsoft.Json.Serialization; - -namespace AssetStoreTools.Previews.Services -{ - internal class PreviewDatabaseContractResolver : DefaultContractResolver - { - private static PreviewDatabaseContractResolver _instance; - public static PreviewDatabaseContractResolver Instance => _instance ?? (_instance = new PreviewDatabaseContractResolver()); - - private NamingStrategy _namingStrategy; - - private PreviewDatabaseContractResolver() - { - _namingStrategy = new SnakeCaseNamingStrategy(); - } - - protected override string ResolvePropertyName(string propertyName) - { - var resolvedName = _namingStrategy.GetPropertyName(propertyName, false); - if (resolvedName.StartsWith("_")) - return resolvedName.Substring(1); - - return resolvedName; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/PreviewDatabaseContractResolver.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/PreviewDatabaseContractResolver.cs.meta deleted file mode 100644 index 799994b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/CachingService/PreviewDatabaseContractResolver.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: aee615e9aaf50fb4f989cd4698e8947e -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/IValidatorService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/IValidatorService.cs deleted file mode 100644 index 3ff09b8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/IValidatorService.cs +++ /dev/null @@ -1,4 +0,0 @@ -namespace AssetStoreTools.Validator.Services -{ - internal interface IValidatorService { } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/IValidatorService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/IValidatorService.cs.meta deleted file mode 100644 index 74923b3..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/IValidatorService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 075953f4ab4a65d4fae6e891360df0d0 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation.meta deleted file mode 100644 index bf10d70..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 184dcfbfe1d21454fa8cf49f1c637871 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions.meta deleted file mode 100644 index d6c2cf0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: ed0af5acc22551645ae4cb7d75bd1c36 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IAssetUtilityService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IAssetUtilityService.cs deleted file mode 100644 index a73e3ce..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IAssetUtilityService.cs +++ /dev/null @@ -1,18 +0,0 @@ -using System.Collections.Generic; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator.Services.Validation -{ - internal interface IAssetUtilityService : IValidatorService - { - IEnumerable GetAssetPathsFromAssets(string[] searchPaths, AssetType type); - IEnumerable GetObjectsFromAssets(string[] searchPaths, AssetType type) where T : Object; - IEnumerable GetObjectsFromAssets(string[] searchPaths, AssetType type); - string ObjectToAssetPath(Object obj); - T AssetPathToObject(string assetPath) where T : Object; - Object AssetPathToObject(string assetPath); - AssetImporter GetAssetImporter(string assetPath); - AssetImporter GetAssetImporter(Object asset); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IAssetUtilityService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IAssetUtilityService.cs.meta deleted file mode 100644 index cb8e4df..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IAssetUtilityService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: d28c5ea40f4c9954bae02804e416b898 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IFileSignatureUtilityService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IFileSignatureUtilityService.cs deleted file mode 100644 index 7633ffd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IFileSignatureUtilityService.cs +++ /dev/null @@ -1,7 +0,0 @@ -namespace AssetStoreTools.Validator.Services.Validation -{ - internal interface IFileSignatureUtilityService : IValidatorService - { - ArchiveType GetArchiveType(string filePath); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IFileSignatureUtilityService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IFileSignatureUtilityService.cs.meta deleted file mode 100644 index 132acba..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IFileSignatureUtilityService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 609c423482ecf8844a71166b4ef49cb6 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IMeshUtilityService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IMeshUtilityService.cs deleted file mode 100644 index ba4959e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IMeshUtilityService.cs +++ /dev/null @@ -1,10 +0,0 @@ -using System.Collections.Generic; -using UnityEngine; - -namespace AssetStoreTools.Validator.Services.Validation -{ - internal interface IMeshUtilityService : IValidatorService - { - IEnumerable GetCustomMeshesInObject(GameObject obj); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IMeshUtilityService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IMeshUtilityService.cs.meta deleted file mode 100644 index 952889e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IMeshUtilityService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: acde6f9b97c9cac4b88a84aa9001a0fc -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IModelUtilityService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IModelUtilityService.cs deleted file mode 100644 index fa29424..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IModelUtilityService.cs +++ /dev/null @@ -1,10 +0,0 @@ -using System.Collections.Generic; -using UnityEngine; - -namespace AssetStoreTools.Validator.Services.Validation -{ - internal interface IModelUtilityService : IValidatorService - { - Dictionary> GetImportLogs(params Object[] models); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IModelUtilityService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IModelUtilityService.cs.meta deleted file mode 100644 index 5e464c9..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IModelUtilityService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 91f6bacccdfecb84fb5ab0ba384353b4 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/ISceneUtilityService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/ISceneUtilityService.cs deleted file mode 100644 index d80f184..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/ISceneUtilityService.cs +++ /dev/null @@ -1,13 +0,0 @@ -using UnityEngine; -using UnityEngine.SceneManagement; - -namespace AssetStoreTools.Validator.Services.Validation -{ - internal interface ISceneUtilityService : IValidatorService - { - string CurrentScenePath { get; } - - Scene OpenScene(string scenePath); - GameObject[] GetRootGameObjects(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/ISceneUtilityService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/ISceneUtilityService.cs.meta deleted file mode 100644 index db0e94f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/ISceneUtilityService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: cf5ef331063e5aa4e95dfe3eadedf9af -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IScriptUtilityService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IScriptUtilityService.cs deleted file mode 100644 index 04214c3..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IScriptUtilityService.cs +++ /dev/null @@ -1,14 +0,0 @@ -using System; -using System.Collections.Generic; -using UnityEditor; -using Object = UnityEngine.Object; - -namespace AssetStoreTools.Validator.Services.Validation -{ - internal interface IScriptUtilityService : IValidatorService - { - IReadOnlyDictionary> GetTypeNamespacesFromScriptAssets(IList monoScripts); - IReadOnlyDictionary> GetTypesFromAssemblies(IList assemblies); - IReadOnlyDictionary> GetTypesFromScriptAssets(IList monoScripts); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IScriptUtilityService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IScriptUtilityService.cs.meta deleted file mode 100644 index e5458be..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Abstractions/IScriptUtilityService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: e0a9f88d37222e4428853b6d3d00b1bd -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/AssetUtilityService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/AssetUtilityService.cs deleted file mode 100644 index fb51d8a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/AssetUtilityService.cs +++ /dev/null @@ -1,216 +0,0 @@ -using AssetStoreTools.Utility; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using UnityEditor; -using UnityEditor.Compilation; -using UnityEngine; -using Object = UnityEngine.Object; - -namespace AssetStoreTools.Validator.Services.Validation -{ - internal class AssetUtilityService : IAssetUtilityService - { - public IEnumerable GetAssetPathsFromAssets(string[] searchPaths, AssetType type) - { - string filter = string.Empty; - string[] extensions = null; - - switch (type) - { - // General Types - case AssetType.All: - filter = ""; - break; - case AssetType.Prefab: - filter = "t:prefab"; - break; - case AssetType.Material: - filter = "t:material"; - break; - case AssetType.Model: - filter = "t:model"; - break; - case AssetType.Scene: - filter = "t:scene"; - break; - case AssetType.Texture: - filter = "t:texture"; - break; - case AssetType.Video: - filter = "t:VideoClip"; - break; - // Specific Types - case AssetType.LossyAudio: - filter = "t:AudioClip"; - extensions = new[] { ".mp3", ".ogg" }; - break; - case AssetType.NonLossyAudio: - filter = "t:AudioClip"; - extensions = new[] { ".wav", ".aif", ".aiff" }; - break; - case AssetType.JavaScript: - filter = "t:TextAsset"; - extensions = new[] { ".js" }; - break; - case AssetType.Mixamo: - filter = "t:model"; - extensions = new[] { ".fbx" }; - break; - case AssetType.JPG: - filter = "t:texture"; - extensions = new[] { ".jpg", "jpeg" }; - break; - case AssetType.Executable: - filter = string.Empty; - extensions = new[] { ".exe", ".bat", ".msi", ".apk" }; - break; - case AssetType.Documentation: - filter = string.Empty; - extensions = new[] { ".txt", ".pdf", ".html", ".rtf", ".md" }; - break; - case AssetType.SpeedTree: - filter = string.Empty; - extensions = new[] { ".spm", ".srt", ".stm", ".scs", ".sfc", ".sme", ".st" }; - break; - case AssetType.Shader: - filter = string.Empty; - extensions = new[] { ".shader", ".shadergraph", ".raytrace", ".compute" }; - break; - case AssetType.MonoScript: - filter = "t:script"; - extensions = new[] { ".cs" }; - break; - case AssetType.UnityPackage: - filter = string.Empty; - extensions = new[] { ".unitypackage" }; - break; - case AssetType.PrecompiledAssembly: - var assemblyPaths = GetPrecompiledAssemblies(searchPaths); - return assemblyPaths; - default: - return Array.Empty(); - } - - var guids = AssetDatabase.FindAssets(filter, searchPaths); - var paths = guids.Select(AssetDatabase.GUIDToAssetPath); - - if (extensions != null) - paths = paths.Where(x => extensions.Any(x.ToLower().EndsWith)); - - if (type == AssetType.Mixamo) - paths = paths.Where(IsMixamoFbx); - - paths = paths.Distinct(); - return paths; - } - - public IEnumerable GetObjectsFromAssets(string[] searchPaths, AssetType type) where T : Object - { - var paths = GetAssetPathsFromAssets(searchPaths, type); -#if !AB_BUILDER - var objects = paths.Select(AssetDatabase.LoadAssetAtPath).Where(x => x != null); -#else - var objects = new AssetEnumerator(paths); -#endif - return objects; - } - - public IEnumerable GetObjectsFromAssets(string[] searchPaths, AssetType type) - { - return GetObjectsFromAssets(searchPaths, type); - } - - private IEnumerable GetPrecompiledAssemblies(string[] searchPaths) - { - // Note - for packages, Compilation Pipeline returns full paths, as they appear on disk, not Asset Database - var allDllPaths = CompilationPipeline.GetPrecompiledAssemblyPaths(CompilationPipeline.PrecompiledAssemblySources.UserAssembly); - var rootProjectPath = Application.dataPath.Substring(0, Application.dataPath.Length - "Assets".Length); - var packages = PackageUtility.GetAllLocalPackages(); - - var result = new List(); - foreach (var dllPath in allDllPaths) - { - var absoluteDllPath = Path.GetFullPath(dllPath).Replace("\\", "/"); - foreach (var validationPath in searchPaths) - { - var absoluteValidationPath = Path.GetFullPath(validationPath).Replace("\\", "/"); - if (absoluteDllPath.StartsWith(absoluteValidationPath)) - { - int pathSeparatorLength = 1; - if (absoluteDllPath.StartsWith(Application.dataPath)) - { - var adbPath = $"Assets/{absoluteDllPath.Remove(0, Application.dataPath.Length + pathSeparatorLength)}"; - result.Add(adbPath); - } - else - { - // For non-Asset folder paths (i.e. local and embedded packages), convert disk path to ADB path - var package = packages.FirstOrDefault(x => dllPath.StartsWith(x.resolvedPath.Replace('\\', '/'))); - - if (package == null) - continue; - - var dllPathInPackage = absoluteDllPath.Remove(0, Path.GetFullPath(package.resolvedPath).Length + pathSeparatorLength); - var adbPath = $"Packages/{package.name}/{dllPathInPackage}"; - - result.Add(adbPath); - } - } - } - } - - return result; - } - - private bool IsMixamoFbx(string fbxPath) - { - // Location of Mixamo Header, this is located in every mixamo fbx file exported - //const int mixamoHeader = 0x4c0 + 2; // < this is the original location from A$ Tools, unsure if Mixamo file headers were changed since then - const int mixamoHeader = 1622; - // Length of Mixamo header - const int length = 0xa; - - var fs = new FileStream(fbxPath, FileMode.Open); - // Check if length is further than - if (fs.Length < mixamoHeader) - return false; - - byte[] buffer = new byte[length]; - using (BinaryReader reader = new BinaryReader(fs)) - { - reader.BaseStream.Seek(mixamoHeader, SeekOrigin.Begin); - reader.Read(buffer, 0, length); - } - - string result = System.Text.Encoding.ASCII.GetString(buffer); - return result.Contains("Mixamo"); - } - - public string ObjectToAssetPath(Object obj) - { - return AssetDatabase.GetAssetPath(obj); - } - - public T AssetPathToObject(string assetPath) where T : Object - { - return AssetDatabase.LoadAssetAtPath(assetPath); - } - - public Object AssetPathToObject(string assetPath) - { - return AssetPathToObject(assetPath); - } - - public AssetImporter GetAssetImporter(string assetPath) - { - return AssetImporter.GetAtPath(assetPath); - } - - public AssetImporter GetAssetImporter(Object asset) - { - return GetAssetImporter(ObjectToAssetPath(asset)); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/AssetUtilityService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/AssetUtilityService.cs.meta deleted file mode 100644 index c91088e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/AssetUtilityService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 9634968648d355c47b7cb12aead7abab -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data.meta deleted file mode 100644 index 3256935..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 8dcc2f4da0b6cea4ab4733ebf32edab4 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/ArchiveType.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/ArchiveType.cs deleted file mode 100644 index d225180..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/ArchiveType.cs +++ /dev/null @@ -1,19 +0,0 @@ -namespace AssetStoreTools.Validator.Services.Validation -{ - internal enum ArchiveType - { - None, - TarGz, - Zip, - Rar, - Tar, - TarZip, - Bz2, - LZip, - SevenZip, - GZip, - QuickZip, - Xz, - Wim - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/ArchiveType.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/ArchiveType.cs.meta deleted file mode 100644 index 82f4e85..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/ArchiveType.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 4061cb7aed3883346a66494c23e2e77b -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetEnumerator.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetEnumerator.cs deleted file mode 100644 index 0df889a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetEnumerator.cs +++ /dev/null @@ -1,84 +0,0 @@ -using System; -using System.Collections; -using System.Collections.Generic; -using UnityEditor; -using Object = UnityEngine.Object; - -namespace AssetStoreTools.Validator.Services.Validation -{ - internal class AssetEnumerator : IEnumerator, IEnumerable where T : Object - { - public const int Capacity = 32; - - private Queue _pathQueue; - private Queue _loadedAssetQueue; - - private T _currentElement; - - public AssetEnumerator(IEnumerable paths) - { - _pathQueue = new Queue(paths); - _loadedAssetQueue = new Queue(); - } - - public bool MoveNext() - { - bool hasPathsButHasNoAssets = _pathQueue.Count != 0 && _loadedAssetQueue.Count == 0; - if (hasPathsButHasNoAssets) - { - LoadMore(); - } - - bool dequeued = false; - if (_loadedAssetQueue.Count != 0) - { - _currentElement = _loadedAssetQueue.Dequeue(); - dequeued = true; - } - - return dequeued; - } - - private void LoadMore() - { - int limit = Capacity; - while (limit > 0 && _pathQueue.Count != 0) - { - string path = _pathQueue.Dequeue(); - T asset = AssetDatabase.LoadAssetAtPath(path); - if (asset != null) - { - _loadedAssetQueue.Enqueue(asset); - limit--; - } - } - - // Unload other loose asset references - EditorUtility.UnloadUnusedAssetsImmediate(); - } - - public void Reset() - { - throw new NotSupportedException("Asset Enumerator cannot be reset."); - } - - public T Current => _currentElement; - - object IEnumerator.Current => Current; - - public void Dispose() - { - // No need to dispose - } - - IEnumerator IEnumerable.GetEnumerator() - { - return this; - } - - public IEnumerator GetEnumerator() - { - return this; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetEnumerator.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetEnumerator.cs.meta deleted file mode 100644 index d82fc2f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetEnumerator.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 0859579889cc56f4aa26eb863a1487b9 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetType.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetType.cs deleted file mode 100644 index 2fc188d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetType.cs +++ /dev/null @@ -1,25 +0,0 @@ -namespace AssetStoreTools.Validator.Services.Validation -{ - internal enum AssetType - { - All, - Documentation, - Executable, - JPG, - JavaScript, - LossyAudio, - Material, - Mixamo, - Model, - MonoScript, - NonLossyAudio, - PrecompiledAssembly, - Prefab, - Scene, - Shader, - SpeedTree, - Texture, - UnityPackage, - Video - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetType.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetType.cs.meta deleted file mode 100644 index 3acaf4b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/AssetType.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: b81d00d4ed0a7da4289d4d6248ef9d34 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/LogEntry.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/LogEntry.cs deleted file mode 100644 index 67663be..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/LogEntry.cs +++ /dev/null @@ -1,10 +0,0 @@ -using UnityEngine; - -namespace AssetStoreTools.Validator.Services.Validation -{ - internal class LogEntry - { - public string Message; - public LogType Severity; - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/LogEntry.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/LogEntry.cs.meta deleted file mode 100644 index cad8e06..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/Data/LogEntry.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a1e81104d6b0f4c449ee57503c3b6669 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/FileSignatureUtilityService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/FileSignatureUtilityService.cs deleted file mode 100644 index 2a140f4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/FileSignatureUtilityService.cs +++ /dev/null @@ -1,78 +0,0 @@ -using System.Collections.Generic; -using System.IO; -using System.Linq; -using UnityEngine; - -namespace AssetStoreTools.Validator.Services.Validation -{ - internal class FileSignatureUtilityService : IFileSignatureUtilityService - { - private class FileSignature - { - public byte[] SignatureBytes; - public int Offset; - - public FileSignature(byte[] signatureBytes, int offset) - { - SignatureBytes = signatureBytes; - Offset = offset; - } - } - - private static readonly Dictionary ArchiveSignatures = new Dictionary - { - { new FileSignature(new byte[] { 0x1f, 0x8b }, 0), ArchiveType.TarGz }, - { new FileSignature(new byte[] { 0x50, 0x4b, 0x03, 0x04 }, 0), ArchiveType.Zip }, - { new FileSignature(new byte[] { 0x50, 0x4b, 0x05, 0x06 }, 0), ArchiveType.Zip }, // Empty Zip Archive - { new FileSignature(new byte[] { 0x50, 0x4b, 0x07, 0x08 }, 0), ArchiveType.Zip }, // Spanned Zip Archive - - { new FileSignature(new byte[] { 0x52, 0x61, 0x72, 0x21, 0x1a, 0x07, 0x00 }, 0), ArchiveType.Rar }, // RaR v1.50+ - { new FileSignature(new byte[] { 0x52, 0x61, 0x72, 0x21, 0x1a, 0x07, 0x01, 0x00 }, 0), ArchiveType.Rar }, // RaR v5.00+ - { new FileSignature(new byte[] { 0x75, 0x73, 0x74, 0x61, 0x72, 0x00, 0x30, 0x30 }, 257), ArchiveType.Tar }, - { new FileSignature(new byte[] { 0x75, 0x73, 0x74, 0x61, 0x72, 0x20, 0x20, 0x00 }, 257), ArchiveType.Tar }, - { new FileSignature(new byte[] { 0x1f, 0x9d }, 0), ArchiveType.TarZip }, // TarZip LZW algorithm - { new FileSignature(new byte[] { 0x1f, 0xa0 }, 0), ArchiveType.TarZip }, // TarZip LZH algorithm - { new FileSignature(new byte[] { 0x42, 0x5a, 0x68 }, 0), ArchiveType.Bz2 }, - { new FileSignature(new byte[] { 0x4c, 0x5a, 0x49, 0x50 }, 0), ArchiveType.LZip }, - { new FileSignature(new byte[] { 0x37, 0x7a, 0xbc, 0xaf, 0x27, 0x1c }, 0), ArchiveType.SevenZip }, - { new FileSignature(new byte[] { 0x1f, 0x8b }, 0), ArchiveType.GZip }, - { new FileSignature(new byte[] { 0x52, 0x53, 0x56, 0x4b, 0x44, 0x41, 0x54, 0x41 }, 0), ArchiveType.QuickZip }, - { new FileSignature(new byte[] { 0xfd, 0x37, 0x7a, 0x58, 0x5a, 0x00 }, 0), ArchiveType.Xz }, - { new FileSignature(new byte[] { 0x4D, 0x53, 0x57, 0x49, 0x4D, 0x00, 0x00, 0x00, 0xD0, 0x00, 0x00, 0x00, 0x00 }, 0), ArchiveType.Wim } - }; - - public ArchiveType GetArchiveType(string filePath) - { - if (!File.Exists(filePath)) - return ArchiveType.None; - - try - { - using (FileStream stream = new FileStream(filePath, FileMode.Open, FileAccess.Read)) - { - foreach (var kvp in ArchiveSignatures) - { - var fileSignature = kvp.Key; - var archiveType = kvp.Value; - - if (stream.Length < fileSignature.SignatureBytes.Length) - continue; - - var bytes = new byte[fileSignature.SignatureBytes.Length]; - stream.Seek(fileSignature.Offset, SeekOrigin.Begin); - stream.Read(bytes, 0, bytes.Length); - - if (fileSignature.SignatureBytes.SequenceEqual(bytes.Take(fileSignature.SignatureBytes.Length))) - return archiveType; - } - } - } - catch (DirectoryNotFoundException) - { - Debug.LogWarning($"File '{filePath}' exists, but could not be opened for reading. Please make sure the project path lengths are not too long for the Operating System"); - } - - return ArchiveType.None; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/FileSignatureUtilityService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/FileSignatureUtilityService.cs.meta deleted file mode 100644 index fc0dc33..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/FileSignatureUtilityService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 695ed79ad88c3b44b8ae41b650ebe16c -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/MeshUtilityService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/MeshUtilityService.cs deleted file mode 100644 index fba268c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/MeshUtilityService.cs +++ /dev/null @@ -1,26 +0,0 @@ -using System.Collections.Generic; -using System.Linq; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator.Services.Validation -{ - internal class MeshUtilityService : IMeshUtilityService - { - public IEnumerable GetCustomMeshesInObject(GameObject obj) - { - var meshes = new List(); - - var meshFilters = obj.GetComponentsInChildren(true); - var skinnedMeshes = obj.GetComponentsInChildren(true); - - meshes.AddRange(meshFilters.Select(m => m.sharedMesh)); - meshes.AddRange(skinnedMeshes.Select(m => m.sharedMesh)); - - meshes = meshes.Where(m => AssetDatabase.GetAssetPath(m).StartsWith("Assets/") || - AssetDatabase.GetAssetPath(m).StartsWith("Packages/")).ToList(); - - return meshes; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/MeshUtilityService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/MeshUtilityService.cs.meta deleted file mode 100644 index 7c677a2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/MeshUtilityService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 307f5dd7be983e246adbda52ac50ecf3 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ModelUtilityService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ModelUtilityService.cs deleted file mode 100644 index b018991..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ModelUtilityService.cs +++ /dev/null @@ -1,147 +0,0 @@ -#if !UNITY_2022_2_OR_NEWER -using System; -using System.Reflection; -#endif -using System.Collections.Generic; -using System.Linq; -using UnityEditor; -#if UNITY_2022_2_OR_NEWER -using UnityEditor.AssetImporters; -#endif -using UnityEngine; -using Object = UnityEngine.Object; - -namespace AssetStoreTools.Validator.Services.Validation -{ - internal class ModelUtilityService : IModelUtilityService - { - private IAssetUtilityService _assetUtility; - -#if !UNITY_2022_2_OR_NEWER - // Rig fields - private const string RigImportWarningsField = "m_RigImportWarnings"; - private const string RigImportErrorsField = "m_RigImportErrors"; - - // Animation fields - private const string AnimationImportWarningsField = "m_AnimationImportWarnings"; - private const string AnimationImportErrorsField = "m_AnimationImportErrors"; - - private static Editor _modelImporterEditor = null; -#endif - - public ModelUtilityService(IAssetUtilityService assetUtility) - { - _assetUtility = assetUtility; - } - - public Dictionary> GetImportLogs(params Object[] models) - { -#if UNITY_2022_2_OR_NEWER - return GetImportLogsDefault(models); -#else - return GetImportLogsLegacy(models); -#endif - } - -#if UNITY_2022_2_OR_NEWER - private Dictionary> GetImportLogsDefault(params Object[] models) - { - var modelsWithLogs = new Dictionary>(); - - foreach (var model in models) - { - var modelLogs = new List(); - - var importLog = AssetImporter.GetImportLog(_assetUtility.ObjectToAssetPath(model)); - - if (importLog == null) - continue; - - var entries = importLog.logEntries.Where(x => x.flags.HasFlag(ImportLogFlags.Warning) || x.flags.HasFlag(ImportLogFlags.Error)); - foreach (var entry in entries) - { - var severity = entry.flags.HasFlag(ImportLogFlags.Error) ? LogType.Error : LogType.Warning; - modelLogs.Add(new LogEntry() { Message = entry.message, Severity = severity }); - } - - if (modelLogs.Count > 0) - modelsWithLogs.Add(model, modelLogs); - } - - return modelsWithLogs; - } -#endif - -#if !UNITY_2022_2_OR_NEWER - private Dictionary> GetImportLogsLegacy(params Object[] models) - { - var modelsWithLogs = new Dictionary>(); - - foreach (var model in models) - { - var modelLogs = new List(); - - // Load the Model Importer - var modelImporter = _assetUtility.GetAssetImporter(model) as ModelImporter; - - var editorAssembly = AppDomain.CurrentDomain.GetAssemblies().FirstOrDefault(x => x.GetName().Name.Equals("UnityEditor")); - - var modelImporterEditorType = editorAssembly.GetType("UnityEditor.ModelImporterEditor"); - - // Load its Model Importer Editor - Editor.CreateCachedEditorWithContext(new Object[] { modelImporter }, model, modelImporterEditorType, ref _modelImporterEditor); - - // Find the base type - var modelImporterEditorTypeBase = _modelImporterEditor.GetType().BaseType; - - // Get the tabs value - var tabsArrayType = modelImporterEditorTypeBase.GetRuntimeProperties().FirstOrDefault(x => x.Name == "tabs"); - var tabsArray = (Array)tabsArrayType.GetValue(_modelImporterEditor); - - // Get the tabs (Model | Rig | Animation | Materials) - var rigTab = tabsArray.GetValue(1); - var animationTab = tabsArray.GetValue(2); - - var rigErrorsCheckSuccess = CheckFieldForSerializedProperty(rigTab, RigImportErrorsField, out var rigErrors); - var rigWarningsCheckSuccess = CheckFieldForSerializedProperty(rigTab, RigImportWarningsField, out var rigWarnings); - var animationErrorsCheckSuccess = CheckFieldForSerializedProperty(animationTab, AnimationImportErrorsField, out var animationErrors); - var animationWarningsCheckSuccess = CheckFieldForSerializedProperty(animationTab, AnimationImportWarningsField, out var animationWarnings); - - if (!rigErrorsCheckSuccess || !rigWarningsCheckSuccess || !animationErrorsCheckSuccess || !animationWarningsCheckSuccess) - UnityEngine.Debug.LogWarning($"An error was encountered when checking import logs for model '{model.name}'"); - - if (!string.IsNullOrEmpty(rigWarnings)) - modelLogs.Add(new LogEntry() { Message = rigWarnings, Severity = LogType.Warning }); - if (!string.IsNullOrEmpty(rigErrors)) - modelLogs.Add(new LogEntry() { Message = rigErrors, Severity = LogType.Error }); - if (!string.IsNullOrEmpty(animationWarnings)) - modelLogs.Add(new LogEntry() { Message = animationWarnings, Severity = LogType.Warning }); - if (!string.IsNullOrEmpty(animationErrors)) - modelLogs.Add(new LogEntry() { Message = animationErrors, Severity = LogType.Error }); - - if (modelLogs.Count > 0) - modelsWithLogs.Add(model, modelLogs); - } - - return modelsWithLogs; - } - - private static bool CheckFieldForSerializedProperty(object source, string propertyName, out string message) - { - message = string.Empty; - - try - { - var propertyType = source.GetType().GetRuntimeFields().FirstOrDefault(x => x.Name.Equals(propertyName, StringComparison.OrdinalIgnoreCase)); - var propertyValue = propertyType.GetValue(source) as SerializedProperty; - message = propertyValue.stringValue; - return true; - } - catch - { - return false; - } - } -#endif - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ModelUtilityService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ModelUtilityService.cs.meta deleted file mode 100644 index ec4a95a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ModelUtilityService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: c50ca4c87e66f1b478279e5d1db4a08e -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/SceneUtilityService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/SceneUtilityService.cs deleted file mode 100644 index ec7a43b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/SceneUtilityService.cs +++ /dev/null @@ -1,26 +0,0 @@ -using UnityEditor; -using UnityEditor.SceneManagement; -using UnityEngine; -using UnityEngine.SceneManagement; - -namespace AssetStoreTools.Validator.Services.Validation -{ - internal class SceneUtilityService : ISceneUtilityService - { - public string CurrentScenePath => SceneManager.GetActiveScene().path; - - public Scene OpenScene(string scenePath) - { - EditorSceneManager.SaveCurrentModifiedScenesIfUserWantsTo(); - if (string.IsNullOrEmpty(scenePath) || AssetDatabase.LoadAssetAtPath(scenePath) == null) - return EditorSceneManager.NewScene(NewSceneSetup.DefaultGameObjects); - else - return EditorSceneManager.OpenScene(scenePath); - } - - public GameObject[] GetRootGameObjects() - { - return SceneManager.GetSceneByPath(CurrentScenePath).GetRootGameObjects(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/SceneUtilityService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/SceneUtilityService.cs.meta deleted file mode 100644 index 9f20ad4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/SceneUtilityService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 53e8deb0ebfb7ea47956f3a859580cd4 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ScriptUtilityService.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ScriptUtilityService.cs deleted file mode 100644 index 2e85c2a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ScriptUtilityService.cs +++ /dev/null @@ -1,658 +0,0 @@ -using System; -using System.Collections.Concurrent; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Text; -using System.Text.RegularExpressions; -using System.Threading; -using System.Threading.Tasks; -using UnityEditor; -using Object = UnityEngine.Object; - -namespace AssetStoreTools.Validator.Services.Validation -{ - internal class ScriptUtilityService : IScriptUtilityService - { - private const int ScriptTimeoutMs = 10000; - private const string IgnoredAssemblyCharacters = "!@#$%^*&()-+=[]{}\\|;:'\",.<>/?"; - - /// - /// For a given list of script assets, retrieves a list of types and their namespaces - /// - /// - /// A dictionary mapping each script asset with a list of its types. - /// The type tuple contains a name (e.g. class MyClass) and its namespace (e.g. MyNamespace) - /// - public IReadOnlyDictionary> GetTypeNamespacesFromScriptAssets(IList monoScripts) - { - var typesAndNamespaces = new Dictionary>(); - var typeInfos = GetTypeInfosFromScriptAssets(monoScripts); - - foreach (var kvp in typeInfos) - { - var namespacesInScript = new List<(string Name, string Namespace)>(); - foreach (var typeInfo in kvp.Value) - { - bool isValidType = typeInfo.TypeName == ScriptParser.TypeName.Class || typeInfo.TypeName == ScriptParser.TypeName.Struct || - typeInfo.TypeName == ScriptParser.TypeName.Interface || typeInfo.TypeName == ScriptParser.TypeName.Enum; - - if (isValidType) - namespacesInScript.Add(($"{typeInfo.TypeName.ToString().ToLower()} {typeInfo.Name}", typeInfo.Namespace)); - } - - typesAndNamespaces.Add(kvp.Key, namespacesInScript); - } - - return typesAndNamespaces; - } - - /// - /// Scans the given precompiled assembly assets to retrieve a list of their contained types - /// - /// - /// A dictionary mapping each precompiled assembly asset with a list of System.Type objects. - public IReadOnlyDictionary> GetTypesFromAssemblies(IList assemblies) - { - var dllPaths = assemblies.ToDictionary(t => AssetDatabase.GetAssetPath(t), t => t); - var types = new ConcurrentDictionary>(); - var failedDllPaths = new ConcurrentBag(); - - var allAssemblies = AppDomain.CurrentDomain.GetAssemblies(); - - Parallel.ForEach(dllPaths.Keys, - (assemblyPath) => - { - try - { - var assembly = allAssemblies.FirstOrDefault(x => Path.GetFullPath(x.Location).Equals(Path.GetFullPath(assemblyPath), StringComparison.OrdinalIgnoreCase)); - if (assembly == null) - return; - - var assemblyTypes = assembly.GetTypes().Where(x => !IgnoredAssemblyCharacters.Any(c => x.Name.Contains(c))).ToList(); - types.TryAdd(dllPaths[assemblyPath], assemblyTypes); - } - catch - { - failedDllPaths.Add(assemblyPath); - } - }); - - if (failedDllPaths.Count > 0) - { - var message = new StringBuilder("The following precompiled assemblies could not be checked:"); - foreach (var path in failedDllPaths) - message.Append($"\n{path}"); - UnityEngine.Debug.LogWarning(message); - } - - // Types are sorted randomly due to parallelism, therefore need to be sorted before returning - var sortedTypes = dllPaths.Where(x => types.ContainsKey(x.Value)) - .Select(x => new KeyValuePair>(x.Value, types[x.Value])) - .ToDictionary(t => t.Key, t => t.Value); - - return sortedTypes; - } - - /// - /// Scans the given script assets to retrieve a list of their contained types - /// - /// - /// A dictionary mapping each precompiled assembly asset with a list of System.Type objects. - public IReadOnlyDictionary> GetTypesFromScriptAssets(IList monoScripts) - { - var realTypes = new Dictionary>(); - var typeInfos = GetTypeInfosFromScriptAssets(monoScripts); - var assemblies = AppDomain.CurrentDomain.GetAssemblies(); - - foreach (var kvp in typeInfos) - { - var realTypesInScript = new List(); - foreach (var typeInfo in kvp.Value) - { - bool isValidType = typeInfo.TypeName == ScriptParser.TypeName.Class || typeInfo.TypeName == ScriptParser.TypeName.Struct || - typeInfo.TypeName == ScriptParser.TypeName.Interface || typeInfo.TypeName == ScriptParser.TypeName.Enum; - - if (isValidType) - { - var realType = assemblies.Where(a => a.GetType(typeInfo.GetReflectionFriendlyFullName()) != null) - .Select(a => a.GetType(typeInfo.GetReflectionFriendlyFullName())).FirstOrDefault(); - if (realType != null) - realTypesInScript.Add(realType); - } - } - - realTypes.Add(kvp.Key, realTypesInScript); - } - - return realTypes; - } - - /// - /// Scans the given MonoScript assets to retrieve a list of their contained types - /// - /// - /// A dictionary mapping each script asset with a list of TypeInfo objects. - private IReadOnlyDictionary> GetTypeInfosFromScriptAssets(IList monoScripts) - { - var types = new ConcurrentDictionary>(); - var monoScriptContents = new Dictionary(); - var failedScripts = new ConcurrentBag(); - - // A separate dictionary is needed because MonoScript contents cannot be accessed outside of the main thread - foreach (var kvp in monoScripts) - monoScriptContents.Add(kvp, kvp.text); - - var tasks = new List>(); - - try - { - foreach (var kvp in monoScriptContents) - { - var cancellationTokenSource = new CancellationTokenSource(ScriptTimeoutMs); - - var task = Task.Run(() => - { - var parsingTask = new ScriptParser(cancellationTokenSource.Token); - var parsed = parsingTask.GetTypesInScript(kvp.Value, out IList parsedTypes); - if (parsed) - types.TryAdd(kvp.Key, parsedTypes); - else - failedScripts.Add(kvp.Key); - }); - - tasks.Add(new Tuple(task, cancellationTokenSource)); - } - - foreach (var t in tasks) - t.Item1.Wait(); - } - finally - { - foreach (var t in tasks) - t.Item2.Dispose(); - } - - if (failedScripts.Count > 0) - { - var message = new StringBuilder("The following scripts could not be checked:"); - foreach (var s in failedScripts) - message.Append($"\n{AssetDatabase.GetAssetPath(s)}"); - UnityEngine.Debug.LogWarning(message); - } - - // Types are sorted randomly due to parallelism, therefore need to be sorted before returning - var sortedTypes = monoScriptContents.Where(x => types.ContainsKey(x.Key)) - .Select(x => new KeyValuePair>(x.Key, types[x.Key])) - .ToDictionary(t => t.Key, t => t.Value); - - return sortedTypes; - } - - /// - /// A simple script parser class to detect types declared within a script - /// - private class ScriptParser - { - /// - /// Types that can be identified by the script parser - /// - public enum TypeName - { - Undefined, - Namespace, - Class, - Struct, - Interface, - Enum, - IdentationStart, - IdentationEnd - } - - /// - /// A class containing information about each block of a C# script - /// - /// A block in this context is defined as script text that is contained within curly brackets. - /// If it's a type, it may have a preceding name and a namespace - /// - public class BlockInfo - { - public TypeName TypeName = TypeName.Undefined; - public string Name = string.Empty; - public string FullName = string.Empty; - public string Namespace = string.Empty; - public int FoundIndex; - public int StartIndex; - - public BlockInfo ParentBlock; - - public string GetReflectionFriendlyFullName() - { - StringBuilder sb = new StringBuilder(FullName); - for (int i = sb.Length - 1; i >= Namespace.Length + 1; i--) - if (sb[i] == '.') - sb[i] = '+'; - - return sb.ToString(); - } - } - - private CancellationToken _token; - - public ScriptParser(CancellationToken token) - { - _token = token; - } - - public bool GetTypesInScript(string text, out IList types) - { - types = null; - - try - { - var sanitized = SanitizeScript(text); - types = ScanForTypes(sanitized); - return true; - } - catch - { - return false; - } - } - - private string SanitizeScript(string source) - { - var sb = new StringBuilder(source); - - // Remove comments and strings - sb = RemoveStringsAndComments(sb); - - // Replace newlines with spaces - sb.Replace("\r", " ").Replace("\n", " "); - - // Space out the brackets - sb.Replace("{", " { ").Replace("}", " } "); - - // Insert a space at the start for more convenient parsing - sb.Insert(0, " "); - - // Remove repeating spaces - var sanitized = Regex.Replace(sb.ToString(), @"\s{2,}", " "); - - return sanitized; - } - - private StringBuilder RemoveStringsAndComments(StringBuilder sb) - { - void CheckStringIdentifiers(int index, out bool isVerbatim, out bool isInterpolated) - { - isVerbatim = false; - isInterpolated = false; - - string precedingChars = string.Empty; - for (int i = index - 1; i >= 0; i--) - { - if (sb[i] == ' ') - break; - precedingChars += sb[i]; - } - - if (precedingChars.Contains("@")) - isVerbatim = true; - if (precedingChars.Contains("$")) - isInterpolated = true; - } - - bool IsRegion(int index) - { - if (sb.Length - index < "#region".Length) - return false; - if (sb[index] == '#' && sb[index + 1] == 'r' && sb[index + 2] == 'e' && sb[index + 3] == 'g' && sb[index + 4] == 'i' && - sb[index + 5] == 'o' && sb[index + 6] == 'n') - return true; - return false; - } - - var removeRanges = new List>(); - - for (int i = 0; i < sb.Length; i++) - { - _token.ThrowIfCancellationRequested(); - - // Comment code - if (sb[i] == '/') - { - if (sb[i + 1] == '/') - { - for (int j = i + 1; j < sb.Length; j++) - { - _token.ThrowIfCancellationRequested(); - if (sb[j] == '\n' || j == sb.Length - 1) - { - removeRanges.Add(new Tuple(i, j - i + 1)); - i = j; - break; - } - } - } - else if (sb[i + 1] == '*') - { - for (int j = i + 2; j < sb.Length; j++) - { - _token.ThrowIfCancellationRequested(); - if (sb[j] == '/' && sb[j - 1] == '*') - { - removeRanges.Add(new Tuple(i, j - i + 1)); - i = j + 1; - break; - } - } - } - } - // Char code - else if (sb[i] == '\'') - { - for (int j = i + 1; j < sb.Length; j++) - { - _token.ThrowIfCancellationRequested(); - if (sb[j] == '\'') - { - if (sb[j - 1] == '\\') - { - int slashCount = 0; - int k = j - 1; - while (sb[k--] == '\\') - slashCount++; - if (slashCount % 2 != 0) - continue; - } - removeRanges.Add(new Tuple(i, j - i + 1)); - i = j; - break; - } - } - } - // String code - else if (sb[i] == '"') - { - if (sb[i - 1] == '\'' && sb[i + 1] == '\'' || (sb[i - 2] == '\'' && sb[i - 1] == '\\' && sb[i + 1] == '\'')) - continue; - - CheckStringIdentifiers(i, out bool isVerbatim, out bool isInterpolated); - - var bracketCount = 0; - bool interpolationEnd = true; - for (int j = i + 1; j < sb.Length; j++) - { - _token.ThrowIfCancellationRequested(); - if (isInterpolated && (sb[j] == '{' || sb[j] == '}')) - { - if (sb[j] == '{') - { - if (sb[j + 1] != '{') - bracketCount++; - else - j += 1; - } - else if (sb[j] == '}') - { - if (sb[j + 1] != '}') - bracketCount--; - else - j += 1; - } - - if (bracketCount == 0) - interpolationEnd = true; - else - interpolationEnd = false; - - continue; - } - - if (sb[j] == '\"') - { - if (isVerbatim) - { - if (sb[j + 1] != '\"') - { - if (!isInterpolated || isInterpolated && interpolationEnd == true) - { - removeRanges.Add(new Tuple(i, j - i + 1)); - i = j + 1; - break; - } - } - else - j += 1; - } - else - { - bool endOfComment = false; - if (sb[j - 1] != '\\') - endOfComment = true; - else - { - int slashCount = 0; - int k = j - 1; - while (sb[k--] == '\\') - slashCount++; - if (slashCount % 2 == 0) - endOfComment = true; - } - - if (!isInterpolated && endOfComment || (isInterpolated && interpolationEnd && endOfComment)) - { - removeRanges.Add(new Tuple(i, j - i + 1)); - i = j + 1; - break; - } - } - } - } - } - // Region code - else if (IsRegion(i)) - { - i += "#region".Length; - for (int j = i; j < sb.Length; j++) - { - _token.ThrowIfCancellationRequested(); - if (sb[j] == '\n') - { - removeRanges.Add(new Tuple(i, j - i + 1)); - i = j; - break; - } - } - } - } - - for (int i = removeRanges.Count - 1; i >= 0; i--) - sb = sb.Remove(removeRanges[i].Item1, removeRanges[i].Item2); - - return sb; - } - - private IList ScanForTypes(string script) - { - var typeList = new SortedList(); - BlockInfo currentActiveBlock = new BlockInfo(); - - int i = 0; - - BlockInfo nextNamespace = null; - BlockInfo nextClass = null; - BlockInfo nextStruct = null; - BlockInfo nextInterface = null; - BlockInfo nextEnum = null; - - while (i < script.Length) - { - _token.ThrowIfCancellationRequested(); - if (nextNamespace == null) - nextNamespace = FindNextTypeBlock(script, i, TypeName.Namespace); - if (nextClass == null) - nextClass = FindNextTypeBlock(script, i, TypeName.Class); - if (nextStruct == null) - nextStruct = FindNextTypeBlock(script, i, TypeName.Struct); - if (nextInterface == null) - nextInterface = FindNextTypeBlock(script, i, TypeName.Interface); - if (nextEnum == null) - nextEnum = FindNextTypeBlock(script, i, TypeName.Enum); - - var nextIdentationIncrease = FindNextTypeBlock(script, i, TypeName.IdentationStart); - var nextIdentationDecrease = FindNextTypeBlock(script, i, TypeName.IdentationEnd); - - if (!TryFindClosestBlock(out var closestBlock, nextNamespace, nextClass, - nextStruct, nextInterface, nextEnum, nextIdentationIncrease, nextIdentationDecrease)) - break; - - switch (closestBlock) - { - case var _ when closestBlock == nextIdentationIncrease: - closestBlock.ParentBlock = currentActiveBlock; - currentActiveBlock = closestBlock; - break; - case var _ when closestBlock == nextIdentationDecrease: - if (currentActiveBlock.TypeName != TypeName.Undefined) - typeList.Add(currentActiveBlock.StartIndex, currentActiveBlock); - currentActiveBlock = currentActiveBlock.ParentBlock; - break; - case var _ when closestBlock == nextNamespace: - closestBlock.Namespace = currentActiveBlock.TypeName == TypeName.Namespace ? currentActiveBlock.FullName : currentActiveBlock.Namespace; - closestBlock.FullName = string.IsNullOrEmpty(currentActiveBlock.FullName) ? closestBlock.Name : $"{currentActiveBlock.FullName}.{closestBlock.Name}"; - closestBlock.ParentBlock = currentActiveBlock; - currentActiveBlock = closestBlock; - nextNamespace = null; - break; - case var _ when closestBlock == nextClass: - case var _ when closestBlock == nextStruct: - case var _ when closestBlock == nextInterface: - case var _ when closestBlock == nextEnum: - closestBlock.FullName = string.IsNullOrEmpty(currentActiveBlock.FullName) ? closestBlock.Name : $"{currentActiveBlock.FullName}.{closestBlock.Name}"; - closestBlock.Namespace = currentActiveBlock.TypeName == TypeName.Namespace ? currentActiveBlock.FullName : currentActiveBlock.Namespace; - closestBlock.ParentBlock = currentActiveBlock; - currentActiveBlock = closestBlock; - switch (closestBlock) - { - case var _ when closestBlock == nextClass: - nextClass = null; - break; - case var _ when closestBlock == nextStruct: - nextStruct = null; - break; - case var _ when closestBlock == nextInterface: - nextInterface = null; - break; - case var _ when closestBlock == nextEnum: - nextEnum = null; - break; - } - break; - } - - i = closestBlock.StartIndex; - } - - return typeList.Select(x => x.Value).ToList(); - } - - private bool TryFindClosestBlock(out BlockInfo closestBlock, params BlockInfo[] blocks) - { - closestBlock = null; - for (int i = 0; i < blocks.Length; i++) - { - if (blocks[i].FoundIndex == -1) - continue; - - if (closestBlock == null || closestBlock.FoundIndex > blocks[i].FoundIndex) - closestBlock = blocks[i]; - } - - return closestBlock != null; - } - - private BlockInfo FindNextTypeBlock(string text, int startIndex, TypeName blockType) - { - string typeKeyword; - switch (blockType) - { - case TypeName.Namespace: - typeKeyword = "namespace"; - break; - case TypeName.Class: - typeKeyword = "class"; - break; - case TypeName.Struct: - typeKeyword = "struct"; - break; - case TypeName.Interface: - typeKeyword = "interface"; - break; - case TypeName.Enum: - typeKeyword = "enum"; - break; - case TypeName.IdentationStart: - var identationStart = text.IndexOf("{", startIndex); - return new BlockInfo() { FoundIndex = identationStart, StartIndex = identationStart + 1, TypeName = TypeName.Undefined }; - case TypeName.IdentationEnd: - var identationEnd = text.IndexOf("}", startIndex); - return new BlockInfo() { FoundIndex = identationEnd, StartIndex = identationEnd + 1, TypeName = TypeName.Undefined }; - default: - throw new ArgumentException("Invalid block type provided"); - } - - int start = -1; - int blockStart = -1; - string name = string.Empty; - while (startIndex < text.Length) - { - _token.ThrowIfCancellationRequested(); - start = text.IndexOf($" {typeKeyword} ", startIndex); - if (start == -1) - return new BlockInfo { FoundIndex = -1 }; - - // Check if the caught type keyword matches the type definition - var openingBracket = text.IndexOf("{", start); - if (openingBracket == -1) - return new BlockInfo { FoundIndex = -1 }; - - var declaration = text.Substring(start, openingBracket - start); - var split = declaration.Split(' '); - - // Namespace detection - if (typeKeyword == "namespace") - { - // Expected result: [null] [namespace] [null] - if (split.Length == 4) - { - name = split[2]; - blockStart = openingBracket + 1; - break; - } - else - startIndex = openingBracket + 1; - } - // Class, Interface, Struct, Enum detection - else - { - // Expected result: [null] [keywordName] [typeName] ... [null] - // Skip any keywords that only contains [null] [keywordName] [null] - if (split.Length != 3) - { - name = split[2]; - blockStart = openingBracket + 1; - break; - } - else - startIndex = openingBracket + 1; - } - } - - var info = new BlockInfo() { FoundIndex = start, StartIndex = blockStart, Name = name, TypeName = blockType }; - return info; - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ScriptUtilityService.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ScriptUtilityService.cs.meta deleted file mode 100644 index 76d8018..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/Validation/ScriptUtilityService.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 9db4298044e2add44bc3aa6ba898d7c3 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/ValidatorServiceProvider.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/ValidatorServiceProvider.cs deleted file mode 100644 index 0407f8f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/ValidatorServiceProvider.cs +++ /dev/null @@ -1,24 +0,0 @@ -using AssetStoreTools.Utility; -using AssetStoreTools.Validator.Services.Validation; - -namespace AssetStoreTools.Validator.Services -{ - internal class ValidatorServiceProvider : ServiceProvider - { - public static ValidatorServiceProvider Instance => _instance ?? (_instance = new ValidatorServiceProvider()); - private static ValidatorServiceProvider _instance; - - private ValidatorServiceProvider() { } - - protected override void RegisterServices() - { - Register(); - Register(); - Register(); - Register(); - Register(); - Register(); - Register(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/ValidatorServiceProvider.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/ValidatorServiceProvider.cs.meta deleted file mode 100644 index d2f5d3d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Services/ValidatorServiceProvider.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 47ac495c61171824abb2b72b1b7ef676 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions.meta deleted file mode 100644 index 7b3ebc2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 462cf5f916fad974a831f6a44aadcc82 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/AutomatedTest.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/AutomatedTest.cs deleted file mode 100644 index fa49d8c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/AutomatedTest.cs +++ /dev/null @@ -1,121 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Reflection; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestDefinitions -{ - internal class AutomatedTest : ValidationTest - { - public AutomatedTest(ValidationTestScriptableObject source) : base(source) { } - - public override void Run(ITestConfig config) - { - Type testClass = null; - MethodInfo testMethod = null; - - try - { - ValidateTestMethod(ref testClass, ref testMethod); - ValidateConfig(config); - } - catch (Exception e) - { - Debug.LogError(e.Message); - return; - } - - object testClassInstance; - try - { - testClassInstance = CreateInstance(testClass, config); - } - catch (Exception e) - { - Debug.LogError($"Could not create an instance of class {testClass}:\n{e}"); - return; - } - - try - { - Result = (TestResult)testMethod.Invoke(testClassInstance, new object[0]); - } - catch (Exception e) - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - result.AddMessage("An exception was caught when running this test case. See Console for more details"); - Debug.LogError($"An exception was caught when running validation for test case '{Title}'\n{e}"); - Result = result; - } - } - - private void ValidateTestMethod(ref Type testClass, ref MethodInfo testMethod) - { - if (TestScript == null || (testClass = TestScript.GetClass()) == null) - throw new Exception($"Cannot run test {Title} - Test Script class was not found"); - - var interfaces = testClass.GetInterfaces(); - if (!interfaces.Contains(typeof(ITestScript))) - throw new Exception($"Cannot run test {Title} - Test Script class is not derived from {nameof(ITestScript)}"); - - testMethod = testClass.GetMethod("Run"); - if (testMethod == null) - throw new Exception($"Cannot run test {Title} - Run() method was not found"); - } - - private void ValidateConfig(ITestConfig config) - { - switch (ValidationType) - { - case ValidationType.Generic: - case ValidationType.UnityPackage: - if (config is GenericTestConfig) - return; - break; - default: - throw new NotImplementedException("Undefined validation type"); - } - - throw new Exception("Config does not match the validation type"); - } - - private object CreateInstance(Type testClass, ITestConfig testConfig) - { - var constructors = testClass.GetConstructors(); - if (constructors.Length != 1) - throw new Exception($"Test class {testClass} should only contain a single constructor"); - - var constructor = constructors[0]; - var expectedParameters = constructor.GetParameters(); - var parametersToUse = new List(); - foreach (var expectedParam in expectedParameters) - { - var paramType = expectedParam.ParameterType; - - if (paramType == testConfig.GetType()) - { - parametersToUse.Add(testConfig); - continue; - } - - if (typeof(IValidatorService).IsAssignableFrom(paramType)) - { - var matchingService = ValidatorServiceProvider.Instance.GetService(paramType); - if (matchingService == null) - throw new Exception($"Service {paramType} is not registered and could not be retrieved"); - - parametersToUse.Add(matchingService); - continue; - } - - throw new Exception($"Invalid parameter type: {paramType}"); - } - - var instance = constructor.Invoke(parametersToUse.ToArray()); - return instance; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/AutomatedTest.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/AutomatedTest.cs.meta deleted file mode 100644 index 14f79c3..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/AutomatedTest.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: b284048af6fef0d49b8c3a37f7083d04 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/GenericTestConfig.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/GenericTestConfig.cs deleted file mode 100644 index 22dfedf..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/GenericTestConfig.cs +++ /dev/null @@ -1,7 +0,0 @@ -namespace AssetStoreTools.Validator.TestDefinitions -{ - internal class GenericTestConfig : ITestConfig - { - public string[] ValidationPaths { get; set; } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/GenericTestConfig.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/GenericTestConfig.cs.meta deleted file mode 100644 index d982131..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/GenericTestConfig.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: ba1ae4e7b45a6c84ca8ad0eb391bf95d -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestConfig.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestConfig.cs deleted file mode 100644 index 5db2e32..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestConfig.cs +++ /dev/null @@ -1,4 +0,0 @@ -namespace AssetStoreTools.Validator.TestDefinitions -{ - internal interface ITestConfig { } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestConfig.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestConfig.cs.meta deleted file mode 100644 index ee42939..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestConfig.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: c7e57766d04022c4dac58caf8ebe339a -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestScript.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestScript.cs deleted file mode 100644 index e705ab8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestScript.cs +++ /dev/null @@ -1,9 +0,0 @@ -using AssetStoreTools.Validator.Data; - -namespace AssetStoreTools.Validator.TestDefinitions -{ - internal interface ITestScript - { - TestResult Run(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestScript.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestScript.cs.meta deleted file mode 100644 index f8c4743..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ITestScript.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 839ef1f3e773ab347b66932d3f810aec -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects.meta deleted file mode 100644 index 1dfe2af..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: d62652f91f698904ea662c6ab252ea59 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/AutomatedTestScriptableObject.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/AutomatedTestScriptableObject.cs deleted file mode 100644 index 31e6498..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/AutomatedTestScriptableObject.cs +++ /dev/null @@ -1,11 +0,0 @@ -#if UNITY_ASTOOLS_DEVELOPMENT -using UnityEngine; -#endif - -namespace AssetStoreTools.Validator.TestDefinitions -{ -#if UNITY_ASTOOLS_DEVELOPMENT - [CreateAssetMenu(fileName = "AutomatedTest", menuName = "Asset Store Validator/Automated Test")] -#endif - internal class AutomatedTestScriptableObject : ValidationTestScriptableObject { } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/AutomatedTestScriptableObject.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/AutomatedTestScriptableObject.cs.meta deleted file mode 100644 index 28f0608..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/AutomatedTestScriptableObject.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: d813ff809ae82f643bf975031305d541 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/Editor.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/Editor.meta deleted file mode 100644 index eebb867..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/Editor.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 7cd52466a2239344d90c3043b7afc1e4 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/Editor/ValidationTestScriptableObjectInspector.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/Editor/ValidationTestScriptableObjectInspector.cs deleted file mode 100644 index 5b28389..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/Editor/ValidationTestScriptableObjectInspector.cs +++ /dev/null @@ -1,196 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Utility; -using System.Linq; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestDefinitions -{ - [CustomEditor(typeof(ValidationTestScriptableObject), true)] - internal class ValidationTestScriptableObjectInspector : UnityEditor.Editor - { - private enum FilterSeverity - { - Warning, - Fail - } - - private enum FilterType - { - UseFilter, - ExcludeFilter - } - - private ValidationTestScriptableObject _data; - private ValidationTestScriptableObject[] _allObjects; - - private SerializedProperty _script; - private SerializedProperty _validationType; - - private SerializedProperty _testScript; - private SerializedProperty _category; - private SerializedProperty _failFilterProperty; - private SerializedProperty _isInclusiveProperty; - private SerializedProperty _appliesToSubCategories; - private SerializedProperty _categoryFilter; - - private bool _hadChanges; - - private void OnEnable() - { - if (target == null) return; - - _data = target as ValidationTestScriptableObject; - - _script = serializedObject.FindProperty("m_Script"); - - _validationType = serializedObject.FindProperty(nameof(ValidationTestScriptableObject.ValidationType)); - - _testScript = serializedObject.FindProperty(nameof(ValidationTestScriptableObject.TestScript)); - _category = serializedObject.FindProperty(nameof(ValidationTestScriptableObject.CategoryInfo)); - _failFilterProperty = _category.FindPropertyRelative(nameof(ValidationTestScriptableObject.CategoryInfo.IsFailFilter)); - _isInclusiveProperty = _category.FindPropertyRelative(nameof(ValidationTestScriptableObject.CategoryInfo.IsInclusiveFilter)); - _appliesToSubCategories = _category.FindPropertyRelative(nameof(ValidationTestScriptableObject.CategoryInfo.AppliesToSubCategories)); - _categoryFilter = _category.FindPropertyRelative(nameof(ValidationTestScriptableObject.CategoryInfo.Filter)); - - _allObjects = ValidatorUtility.GetAutomatedTestCases(ValidatorUtility.SortType.Id); - _hadChanges = false; - } - - public override void OnInspectorGUI() - { - serializedObject.Update(); - - EditorGUILayout.LabelField(GetInspectorTitle(), new GUIStyle(EditorStyles.centeredGreyMiniLabel) { fontSize = 24 }, GUILayout.MinHeight(50)); - - EditorGUI.BeginDisabledGroup(true); - EditorGUILayout.PropertyField(_script); - - EditorGUI.BeginChangeCheck(); - // ID field - EditorGUILayout.IntField("Test Id", _data.Id); - if (!ValidateID()) - EditorGUILayout.HelpBox("ID is already in use", MessageType.Warning); - EditorGUI.EndDisabledGroup(); - - EditorGUILayout.Space(8); - EditorGUILayout.LabelField("Test Data", new GUIStyle(EditorStyles.centeredGreyMiniLabel) { alignment = TextAnchor.MiddleLeft, fontSize = 14, padding = new RectOffset(0, 0, 0, 0) }); - - // Validation Type - var validationType = (ValidationType)EditorGUILayout.EnumPopup("Validation Type", (ValidationType)_validationType.enumValueIndex); - _validationType.enumValueIndex = (int)validationType; - - // Other fields - _data.Title = EditorGUILayout.TextField("Title", _data.Title); - if (string.IsNullOrEmpty(_data.Title)) - EditorGUILayout.HelpBox("Title cannot be empty", MessageType.Warning); - - EditorGUILayout.LabelField("Description"); - GUIStyle myTextAreaStyle = new GUIStyle(EditorStyles.textArea) { wordWrap = true }; - _data.Description = EditorGUILayout.TextArea(_data.Description, myTextAreaStyle); - - // Test script - EditorGUILayout.Space(8); - EditorGUILayout.LabelField("Test Script", new GUIStyle(EditorStyles.centeredGreyMiniLabel) { alignment = TextAnchor.MiddleLeft, fontSize = 14, padding = new RectOffset(0, 0, 0, 0) }); - - EditorGUILayout.PropertyField(_testScript); - if (_testScript.objectReferenceValue != null) - { - var generatedScriptType = (_testScript.objectReferenceValue as MonoScript).GetClass(); - if (generatedScriptType == null || !generatedScriptType.GetInterfaces().Contains(typeof(ITestScript))) - EditorGUILayout.HelpBox($"Test Script does not derive from {nameof(ITestScript)}. Test execution will fail", MessageType.Warning); - } - else if (!string.IsNullOrEmpty(_data.Title)) - { - var generatedScriptName = GenerateTestScriptName(); - EditorGUILayout.LabelField($"Proposed script name: {generatedScriptName}.cs", new GUIStyle("Label") { richText = true }); - EditorGUILayout.Space(); - EditorGUILayout.BeginHorizontal(); - GUILayout.FlexibleSpace(); - if (GUILayout.Button("Generate Test Method Script", GUILayout.MaxWidth(200f))) - { - var generatedScript = ValidatorUtility.GenerateTestScript(generatedScriptName, (ValidationType)_validationType.enumValueIndex); - _testScript.objectReferenceValue = generatedScript; - } - EditorGUILayout.EndHorizontal(); - } - - // Variable Sevetity Options - EditorGUILayout.Space(8); - EditorGUILayout.LabelField("Variable Severity Status Filtering", new GUIStyle(EditorStyles.centeredGreyMiniLabel) { alignment = TextAnchor.MiddleLeft, fontSize = 14, padding = new RectOffset(0, 0, 0, 0) }); - - var filterSeverity = (FilterSeverity)EditorGUILayout.EnumPopup("Fail Type", _failFilterProperty.boolValue ? FilterSeverity.Fail : FilterSeverity.Warning); - _failFilterProperty.boolValue = filterSeverity == FilterSeverity.Fail ? true : false; - var filterType = (FilterType)EditorGUILayout.EnumPopup("Filtering rule", _isInclusiveProperty.boolValue ? FilterType.UseFilter : FilterType.ExcludeFilter); - _isInclusiveProperty.boolValue = filterType == FilterType.UseFilter ? true : false; - - EditorGUILayout.PropertyField(_appliesToSubCategories); - - EditorGUILayout.Space(10); - - EditorGUILayout.BeginHorizontal(GUI.skin.FindStyle("HelpBox")); - EditorGUILayout.LabelField(GetFilterDescription(_failFilterProperty.boolValue, _isInclusiveProperty.boolValue), new GUIStyle(GUI.skin.label) { wordWrap = true, richText = true }); - EditorGUILayout.EndHorizontal(); - - EditorGUILayout.Space(10); - - EditorGUILayout.PropertyField(_categoryFilter); - - if (EditorGUI.EndChangeCheck()) - { - EditorUtility.SetDirty(target); - _hadChanges = true; - } - - _hadChanges = serializedObject.ApplyModifiedProperties() || _hadChanges; - } - - private string GetInspectorTitle() - { - switch (_data) - { - case AutomatedTestScriptableObject _: - return "Automated Test"; - default: - return "Miscellaneous Test"; - } - } - - private string GenerateTestScriptName() - { - var name = _data.Title.Replace(" ", ""); - return name; - } - - private string GetFilterDescription(bool isFailFilter, bool isInclusive) - { - string text = $"When a {TestResultStatus.VariableSeverityIssue} result type is returned from the test method:\n\n"; - if (isFailFilter) - { - if (isInclusive) - return text + "• Categories IN the filter will result in a FAIL.\n• Categories NOT in the filter will result in a WARNING"; - else - return text + "• Categories NOT in the filter will result in a FAIL.\n• Categories IN the filter will result in a WARNING"; - } - else - { - if (isInclusive) - return text + "• Categories IN the filter will result in a WARNING.\n• Categories NOT in the filter will result in a FAIL"; - else - return text + "• Categories NOT in the filter will result in a WARNING.\n• Categories IN the filter will result in a FAIL"; - } - } - - private bool ValidateID() - { - return !_allObjects.Any(x => x.Id == _data.Id && x != _data); - } - - private void OnDisable() - { - if (!_hadChanges) return; - AssetDatabase.SaveAssets(); - AssetDatabase.Refresh(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/Editor/ValidationTestScriptableObjectInspector.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/Editor/ValidationTestScriptableObjectInspector.cs.meta deleted file mode 100644 index 37b320c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/Editor/ValidationTestScriptableObjectInspector.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 06d76b0e6df91eb43ac956f883c4a2da -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/ValidationTestScriptableObject.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/ValidationTestScriptableObject.cs deleted file mode 100644 index 9c2a29f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/ValidationTestScriptableObject.cs +++ /dev/null @@ -1,35 +0,0 @@ -using AssetStoreTools.Validator.Categories; -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Utility; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestDefinitions -{ - internal abstract class ValidationTestScriptableObject : ScriptableObject - { - [SerializeField, HideInInspector] - private bool HasBeenInitialized; - - public int Id; - public string Title; - public string Description; - public ValidatorCategory CategoryInfo; - public ValidationType ValidationType; - public MonoScript TestScript; - - private void OnEnable() - { - // To do: maybe replace with Custom Inspector - if (HasBeenInitialized) - return; - - var existingTestCases = ValidatorUtility.GetAutomatedTestCases(ValidatorUtility.SortType.Id); - if (existingTestCases.Length > 0) - Id = existingTestCases[existingTestCases.Length - 1].Id + 1; - else - Id = 1; - HasBeenInitialized = true; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/ValidationTestScriptableObject.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/ValidationTestScriptableObject.cs.meta deleted file mode 100644 index 66bee1d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/Scriptable Objects/ValidationTestScriptableObject.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 11c2422f057b75a458e184d169a00eb6 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ValidationTest.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ValidationTest.cs deleted file mode 100644 index abb77f6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ValidationTest.cs +++ /dev/null @@ -1,38 +0,0 @@ -using AssetStoreTools.Validator.Categories; -using AssetStoreTools.Validator.Data; -using UnityEditor; - -namespace AssetStoreTools.Validator.TestDefinitions -{ - internal abstract class ValidationTest - { - public int Id; - public string Title; - public string Description; - public MonoScript TestScript; - - public ValidationType ValidationType; - public ValidatorCategory CategoryInfo; - - public TestResult Result; - - protected ValidationTest(ValidationTestScriptableObject source) - { - Id = source.Id; - Title = source.Title; - Description = source.Description; - TestScript = source.TestScript; - CategoryInfo = source.CategoryInfo; - ValidationType = source.ValidationType; - Result = new TestResult(); - } - - public abstract void Run(ITestConfig config); - - public string Slugify(string value) - { - string newValue = value.Replace(' ', '-').ToLower(); - return newValue; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ValidationTest.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ValidationTest.cs.meta deleted file mode 100644 index 5f7071b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Definitions/ValidationTest.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 095d629656748914bb6202598876fdf4 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods.meta deleted file mode 100644 index 5a3363e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: daedaf78228b5184297e7ca334ea2a12 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic.meta deleted file mode 100644 index a9b691e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: ecfb23f95f16d2347a4063411aad8063 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAnimationClips.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAnimationClips.cs deleted file mode 100644 index e7543b0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAnimationClips.cs +++ /dev/null @@ -1,64 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.Linq; -using UnityEditor; -using UnityObject = UnityEngine.Object; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckAnimationClips : ITestScript - { - private static readonly string[] InvalidNames = new[] { "Take 001" }; - - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public CheckAnimationClips(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - var badModels = new Dictionary>(); - var models = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Model); - - foreach (var model in models) - { - var badClips = new List(); - var clips = AssetDatabase.LoadAllAssetsAtPath(_assetUtility.ObjectToAssetPath(model)); - foreach (var clip in clips) - { - if (InvalidNames.Any(x => x.ToLower().Equals(clip.name.ToLower()))) - { - badClips.Add(clip); - } - } - - if (badClips.Count > 0) - badModels.Add(model, badClips); - } - - if (badModels.Count > 0) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following models have animation clips with invalid names. Animation clip names should be unique and reflective of the animation itself"); - foreach (var kvp in badModels) - { - result.AddMessage(_assetUtility.ObjectToAssetPath(kvp.Key), null, kvp.Value.ToArray()); - } - } - else - { - result.AddMessage("No animation clips with invalid names were found!"); - result.Status = TestResultStatus.Pass; - } - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAnimationClips.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAnimationClips.cs.meta deleted file mode 100644 index 4529bdf..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAnimationClips.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 7a28985886f182c4bacc89a44777c742 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAudioClipping.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAudioClipping.cs deleted file mode 100644 index 6f960e9..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAudioClipping.cs +++ /dev/null @@ -1,128 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.Linq; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckAudioClipping : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public CheckAudioClipping(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - // How many peaks above threshold are required for Audio Clips to be considered clipping - const int TOLERANCE = 2; - // Min. amount of consecutive samples above threshold required for peak detection - const int PEAK_STEPS = 1; - // Clipping threshold. More lenient here than Submission Guidelines (-0.3db) due to the problematic nature of - // correctly determining how sensitive the audio clipping flagging should be, as well as to account for any - // distortion introduced when AudioClips are compresssed after importing to Unity. - const float THRESHOLD = -0.05f; - // Samples for 16-bit audio files - const float S16b = 32767f; - float clippingThreshold = (S16b - (S16b / (2 * Mathf.Log10(1 / S16b)) * THRESHOLD)) / S16b; - TestResult result = new TestResult(); - var clippingAudioClips = new Dictionary(); - - var losslessAudioClips = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.NonLossyAudio).Select(x => x as AudioClip).ToList(); - foreach (var clip in losslessAudioClips) - { - var path = AssetDatabase.GetAssetPath(clip.GetInstanceID()); - - if (IsClipping(clip, TOLERANCE, PEAK_STEPS, clippingThreshold)) - clippingAudioClips.Add(clip, path); - } - - var lossyAudioClips = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.LossyAudio).Select(x => x as AudioClip).ToList(); - foreach (var clip in lossyAudioClips) - { - var path = AssetDatabase.GetAssetPath(clip.GetInstanceID()); - - if (IsClipping(clip, TOLERANCE, PEAK_STEPS, clippingThreshold)) - clippingAudioClips.Add(clip, path); - } - - if (clippingAudioClips.Count > 0) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following AudioClips are clipping or are very close to 0db ceiling. Please ensure your exported audio files have at least 0.3db of headroom (should peak at no more than -0.3db):", null, clippingAudioClips.Select(x => x.Key).ToArray()); - } - else - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No clipping audio files were detected."); - } - - return result; - } - - private bool IsClipping(AudioClip clip, int tolerance, int peakTolerance, float clippingThreshold) - { - if (DetectNumPeaksAboveThreshold(clip, peakTolerance, clippingThreshold) >= tolerance) - return true; - - return false; - } - - private int DetectNumPeaksAboveThreshold(AudioClip clip, int peakTolerance, float clippingThreshold) - { - float[] samples = new float[clip.samples * clip.channels]; - var data = clip.GetData(samples, 0); - - float[] samplesLeft = samples.Where((s, i) => i % 2 == 0).ToArray(); - float[] samplesRight = samples.Where((s, i) => i % 2 == 1).ToArray(); - - int peaks = 0; - - peaks = GetPeaksInChannel(samplesLeft, peakTolerance, clippingThreshold) + - GetPeaksInChannel(samplesRight, peakTolerance, clippingThreshold); - - return peaks; - } - - private int GetPeaksInChannel(float[] samples, int peakTolerance, float clippingThreshold) - { - int peaks = 0; - bool evalPeak = false; - int peakSteps = 0; - int step = 0; - - while (step < samples.Length) - { - if (Mathf.Abs(samples[step]) >= clippingThreshold && evalPeak) - { - peakSteps++; - } - - if (Mathf.Abs(samples[step]) >= clippingThreshold && !evalPeak) - { - evalPeak = true; - peakSteps++; - } - - if (Mathf.Abs(samples[step]) < clippingThreshold && evalPeak) - { - evalPeak = false; - if (peakSteps >= peakTolerance) - peaks++; - peakSteps = 0; - } - - step++; - } - - return peaks; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAudioClipping.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAudioClipping.cs.meta deleted file mode 100644 index 06f0892..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckAudioClipping.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: f604db0353da0cb46bb048f5cd37186f -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckColliders.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckColliders.cs deleted file mode 100644 index 5f4499b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckColliders.cs +++ /dev/null @@ -1,55 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.Linq; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckColliders : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - private IMeshUtilityService _meshUtility; - - public CheckColliders(GenericTestConfig config, IAssetUtilityService assetUtility, IMeshUtilityService meshUtility) - { - _config = config; - _assetUtility = assetUtility; - _meshUtility = meshUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var prefabs = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Prefab); - var badPrefabs = new List(); - - foreach (var p in prefabs) - { - var meshes = _meshUtility.GetCustomMeshesInObject(p); - - if (!p.isStatic || !meshes.Any()) - continue; - - var colliders = p.GetComponentsInChildren(true); - if (!colliders.Any()) - badPrefabs.Add(p); - } - - if (badPrefabs.Count == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("All found prefabs have colliders!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following prefabs contain meshes, but colliders were not found", null, badPrefabs.ToArray()); - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckColliders.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckColliders.cs.meta deleted file mode 100644 index c90549a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckColliders.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 308b3d7b7a883b949a14f47cfd5c7ebe -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckCompressedFiles.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckCompressedFiles.cs deleted file mode 100644 index 330c017..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckCompressedFiles.cs +++ /dev/null @@ -1,121 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using UnityObject = UnityEngine.Object; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckCompressedFiles : ITestScript - { - private enum ArchiveResult - { - Allowed, - NotAllowed, - TarGzWithIssues, - ZipWithIssues - } - - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - private IFileSignatureUtilityService _fileSignatureUtility; - - public CheckCompressedFiles(GenericTestConfig config, IAssetUtilityService assetUtility, IFileSignatureUtilityService fileSignatureUtility) - { - _config = config; - _assetUtility = assetUtility; - _fileSignatureUtility = fileSignatureUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var checkedArchives = new Dictionary(); - - // Retrieving assets via GetObjectsFromAssets() is insufficient because - // archives might be renamed and not use the expected extension - var allAssetPaths = _assetUtility.GetAssetPathsFromAssets(_config.ValidationPaths, AssetType.All); - - foreach (var assetPath in allAssetPaths) - { - ArchiveType archiveType; - if ((archiveType = _fileSignatureUtility.GetArchiveType(assetPath)) == ArchiveType.None) - continue; - - var archiveObj = _assetUtility.AssetPathToObject(assetPath); - - switch (archiveType) - { - case ArchiveType.TarGz: - if (assetPath.ToLower().EndsWith(".unitypackage")) - checkedArchives.Add(archiveObj, ArchiveResult.Allowed); - else - checkedArchives.Add(archiveObj, ArchiveResult.TarGzWithIssues); - break; - case ArchiveType.Zip: - if (FileNameContainsKeyword(assetPath, "source") && assetPath.ToLower().EndsWith(".zip")) - checkedArchives.Add(archiveObj, ArchiveResult.Allowed); - else - checkedArchives.Add(archiveObj, ArchiveResult.ZipWithIssues); - break; - default: - checkedArchives.Add(archiveObj, ArchiveResult.NotAllowed); - break; - } - } - - if (checkedArchives.Count == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No archives were found in the package content!"); - return result; - } - - if (checkedArchives.Any(x => x.Value == ArchiveResult.Allowed)) - { - result.Status = TestResultStatus.Warning; - result.AddMessage("The following archives of allowed format were found in the package content.\n" + - "Please make sure they adhere to the nested archive guidelines:", null, - checkedArchives.Where(x => x.Value == ArchiveResult.Allowed).Select(x => x.Key).ToArray()); - } - - if (checkedArchives.Any(x => x.Value == ArchiveResult.TarGzWithIssues)) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following .gz archives were found in the package content.\n" + - " Gz archives are only allowed in form of '.unitypackage' files", null, - checkedArchives.Where(x => x.Value == ArchiveResult.TarGzWithIssues).Select(x => x.Key).ToArray()); - } - - if (checkedArchives.Any(x => x.Value == ArchiveResult.ZipWithIssues)) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following .zip archives were found in the package content.\n" + - " Zip archives should contain the keyword 'source' in the file name", null, - checkedArchives.Where(x => x.Value == ArchiveResult.ZipWithIssues).Select(x => x.Key).ToArray()); - } - - if (checkedArchives.Any(x => x.Value == ArchiveResult.NotAllowed)) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following archives are using formats that are not allowed:", null, - checkedArchives.Where(x => x.Value == ArchiveResult.NotAllowed).Select(x => x.Key).ToArray()); - } - - return result; - } - - private bool FileNameContainsKeyword(string filePath, string keyword) - { - var fileInfo = new FileInfo(filePath); - - if (!fileInfo.Exists) - return false; - - return fileInfo.Name.Remove(fileInfo.Name.Length - fileInfo.Extension.Length).ToLower().Contains(keyword.ToLower()); - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckCompressedFiles.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckCompressedFiles.cs.meta deleted file mode 100644 index 8bd989c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckCompressedFiles.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 84b23febe0d923842aef73b95da5f25b -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckEmptyPrefabs.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckEmptyPrefabs.cs deleted file mode 100644 index 8a87dad..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckEmptyPrefabs.cs +++ /dev/null @@ -1,46 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckEmptyPrefabs : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public CheckEmptyPrefabs(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var prefabs = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Prefab); - var badPrefabs = new List(); - - foreach (var p in prefabs) - { - if (p.GetComponents().Length == 1 && p.transform.childCount == 0) - badPrefabs.Add(p); - } - - if (badPrefabs.Count == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No empty prefabs were found!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following prefabs are empty", null, badPrefabs.ToArray()); - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckEmptyPrefabs.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckEmptyPrefabs.cs.meta deleted file mode 100644 index fafd181..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckEmptyPrefabs.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 8055bed9373283e4793463b90b42f08f -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckFileMenuNames.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckFileMenuNames.cs deleted file mode 100644 index 3f51144..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckFileMenuNames.cs +++ /dev/null @@ -1,153 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.Linq; -using System.Reflection; -using UnityEditor; -using UnityObject = UnityEngine.Object; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckFileMenuNames : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - private IScriptUtilityService _scriptUtility; - - public CheckFileMenuNames(GenericTestConfig config, IAssetUtilityService assetUtility, IScriptUtilityService scriptUtility) - { - _config = config; - _assetUtility = assetUtility; - _scriptUtility = scriptUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var bindingFlags = BindingFlags.Public | BindingFlags.NonPublic | - BindingFlags.Instance | BindingFlags.Static | BindingFlags.DeclaredOnly; - - #region Scripts - - var scripts = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.MonoScript).ToArray(); - var scriptTypes = _scriptUtility.GetTypesFromScriptAssets(scripts); - var affectedScripts = new Dictionary>(); - - foreach (var kvp in scriptTypes) - { - var badMethods = new List(); - foreach (var type in kvp.Value) - { - foreach (var method in type.GetMethods(bindingFlags)) - { - var attributes = method.GetCustomAttributes().ToList(); - if (attributes.Count == 0) - continue; - - var badAttributes = attributes.Where(x => !IsValidMenuItem(x.menuItem)).ToList(); - if (badAttributes.Count > 0) - badMethods.Add($"{string.Join("\n", badAttributes.Select(x => $"\'{x.menuItem}\'"))}\n(for method '{method.Name}')\n"); - } - } - - if (badMethods.Count > 0) - affectedScripts.Add(kvp.Key, badMethods); - } - - #endregion - - #region Precompiled Assemblies - - var assemblies = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.PrecompiledAssembly).ToArray(); - var assemblyTypes = _scriptUtility.GetTypesFromAssemblies(assemblies); - var affectedAssemblies = new Dictionary>(); - - foreach (var kvp in assemblyTypes) - { - var badMethods = new List(); - foreach (var type in kvp.Value) - { - foreach (var method in type.GetMethods(bindingFlags)) - { - var attributes = method.GetCustomAttributes().ToList(); - if (attributes.Count == 0) - continue; - - var badAttributes = attributes.Where(x => !IsValidMenuItem(x.menuItem)).ToList(); - if (badAttributes.Count > 0) - badMethods.Add($"{string.Join("\n", badAttributes.Select(x => (x as MenuItem).menuItem))}\n(Method '{method.Name}')\n"); - } - } - - if (badMethods.Count > 0) - affectedAssemblies.Add(kvp.Key, badMethods); - } - - #endregion - - if (affectedScripts.Count > 0 || affectedAssemblies.Count > 0) - { - if (affectedScripts.Count > 0) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following scripts contain invalid MenuItem names:"); - foreach (var kvp in affectedScripts) - { - var message = string.Empty; - foreach (var type in kvp.Value) - message += type + "\n"; - - message = message.Remove(message.Length - "\n".Length); - result.AddMessage(message, null, kvp.Key); - } - } - - if (affectedAssemblies.Count > 0) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following assemblies contain invalid MenuItem names:"); - foreach (var kvp in affectedAssemblies) - { - var message = string.Empty; - foreach (var type in kvp.Value) - message += type + "\n"; - - message = message.Remove(message.Length - "\n".Length); - result.AddMessage(message, null, kvp.Key); - } - } - } - else - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No MenuItems with invalid names were found!"); - } - - return result; - } - - private bool IsValidMenuItem(string menuItemName) - { - var acceptableMenuItems = new string[] - { - "File", - "Edit", - "Assets", - "GameObject", - "Component", - "Window", - "Help", - "CONTEXT", - "Tools" - }; - - menuItemName = menuItemName.Replace("\\", "/"); - if (acceptableMenuItems.Any(x => menuItemName.ToLower().StartsWith($"{x.ToLower()}/"))) - return true; - - return false; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckFileMenuNames.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckFileMenuNames.cs.meta deleted file mode 100644 index 0e0872b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckFileMenuNames.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: d8e3b12ecc1fcd74d9a9f8d2b549fc63 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLODs.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLODs.cs deleted file mode 100644 index 8b8975c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLODs.cs +++ /dev/null @@ -1,79 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Data.MessageActions; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.Linq; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckLODs : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public CheckLODs(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var prefabs = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Prefab); - var badPrefabs = new Dictionary>(); - - foreach (var p in prefabs) - { - var meshFilters = p.GetComponentsInChildren(true); - var badMeshFilters = new List(); - var lodGroups = p.GetComponentsInChildren(true); - - foreach (var mf in meshFilters) - { - if (mf.name.Contains("LOD") && !IsPartOfLodGroup(mf, lodGroups)) - badMeshFilters.Add(mf); - } - - if (badMeshFilters.Count > 0) - badPrefabs.Add(p, badMeshFilters); - } - - if (badPrefabs.Count == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("All found prefabs are meeting the LOD requirements!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following prefabs do not meet the LOD requirements"); - - foreach (var p in badPrefabs) - { - var resultList = new List(); - resultList.Add(p.Key); - resultList.AddRange(p.Value); - result.AddMessage($"{p.Key.name}.prefab", new OpenAssetAction(p.Key), resultList.ToArray()); - } - - return result; - } - - private bool IsPartOfLodGroup(MeshFilter mf, LODGroup[] lodGroups) - { - foreach (var lodGroup in lodGroups) - { - // If MeshFilter is a child/deep child of a LodGroup AND is referenced in this LOD group - it is valid - if (mf.transform.IsChildOf(lodGroup.transform) && - lodGroup.GetLODs().Any(lod => lod.renderers.Any(renderer => renderer != null && renderer.gameObject == mf.gameObject))) - return true; - } - - return false; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLODs.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLODs.cs.meta deleted file mode 100644 index 060c427..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLODs.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 43b2158602f87704fa7b91561cfc8678 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLineEndings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLineEndings.cs deleted file mode 100644 index adb381c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLineEndings.cs +++ /dev/null @@ -1,77 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System; -using System.Collections.Concurrent; -using System.Threading.Tasks; -using UnityEditor; -using UnityObject = UnityEngine.Object; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckLineEndings : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public CheckLineEndings(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var scripts = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.MonoScript); - - var affectedScripts = new ConcurrentBag(); - var scriptContents = new ConcurrentDictionary(); - - // A separate dictionary is needed because MonoScript contents cannot be accessed outside of the main thread - foreach (var s in scripts) - if (s != null) - scriptContents.TryAdd(s, s.text); - - Parallel.ForEach(scriptContents, (s) => - { - if (HasInconsistentLineEndings(s.Value)) - affectedScripts.Add(s.Key); - }); - - if (affectedScripts.Count > 0) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following scripts have inconsistent line endings:", null, affectedScripts.ToArray()); - } - else - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No scripts with inconsistent line endings were found!"); - } - - return result; - } - - private bool HasInconsistentLineEndings(string text) - { - int crlfEndings = 0; - int lfEndings = 0; - - var split = text.Split(new[] { "\n" }, StringSplitOptions.None); - for (int i = 0; i < split.Length; i++) - { - var line = split[i]; - if (line.EndsWith("\r")) - crlfEndings++; - else if (i != split.Length - 1) - lfEndings++; - } - - if (crlfEndings > 0 && lfEndings > 0) - return true; - return false; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLineEndings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLineEndings.cs.meta deleted file mode 100644 index fb52149..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckLineEndings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 85885005d1c594f42826de3555e98365 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMeshPrefabs.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMeshPrefabs.cs deleted file mode 100644 index 2c37803..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMeshPrefabs.cs +++ /dev/null @@ -1,106 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.Linq; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckMeshPrefabs : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - private IMeshUtilityService _meshUtility; - - public CheckMeshPrefabs(GenericTestConfig config, IAssetUtilityService assetUtility, IMeshUtilityService meshUtility) - { - _config = config; - _assetUtility = assetUtility; - _meshUtility = meshUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var usedModelPaths = new List(); - var prefabs = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Prefab); - var missingMeshReferencePrefabs = new List(); - - // Get all meshes in existing prefabs and check if prefab has missing mesh references - foreach (var p in prefabs) - { - var meshes = _meshUtility.GetCustomMeshesInObject(p); - foreach (var mesh in meshes) - { - string meshPath = _assetUtility.ObjectToAssetPath(mesh); - usedModelPaths.Add(meshPath); - } - - if (HasMissingMeshReferences(p)) - missingMeshReferencePrefabs.Add(p); - } - - // Get all meshes in existing models - var allModelPaths = GetAllModelMeshPaths(_config.ValidationPaths); - - // Get the list of meshes without prefabs - List unusedModels = allModelPaths.Except(usedModelPaths).ToList(); - - if (unusedModels.Count == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("All found prefabs have meshes!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - var models = unusedModels.Select(_assetUtility.AssetPathToObject).ToArray(); - result.AddMessage("The following models do not have associated prefabs", null, models); - - if (missingMeshReferencePrefabs.Count > 0) - result.AddMessage("The following prefabs have missing mesh references", null, missingMeshReferencePrefabs.ToArray()); - - return result; - } - - private IEnumerable GetAllModelMeshPaths(string[] validationPaths) - { - var models = _assetUtility.GetObjectsFromAssets(validationPaths, AssetType.Model); - var paths = new List(); - - foreach (var o in models) - { - var m = (GameObject)o; - var modelPath = _assetUtility.ObjectToAssetPath(m); - var assetImporter = _assetUtility.GetAssetImporter(modelPath); - if (assetImporter is UnityEditor.ModelImporter modelImporter) - { - var clips = modelImporter.clipAnimations.Count(); - var meshes = _meshUtility.GetCustomMeshesInObject(m); - - // Only add if the model has meshes and no clips - if (meshes.Any() && clips == 0) - paths.Add(modelPath); - } - } - - return paths; - } - - private bool HasMissingMeshReferences(GameObject go) - { - var meshes = go.GetComponentsInChildren(true); - var skinnedMeshes = go.GetComponentsInChildren(true); - - if (meshes.Length == 0 && skinnedMeshes.Length == 0) - return false; - - if (meshes.Any(x => x.sharedMesh == null) || skinnedMeshes.Any(x => x.sharedMesh == null)) - return true; - - return false; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMeshPrefabs.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMeshPrefabs.cs.meta deleted file mode 100644 index 3419dd1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMeshPrefabs.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 3c3d0d642ac6a6a48aa124a93dae3734 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinAssets.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinAssets.cs deleted file mode 100644 index 089d95e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinAssets.cs +++ /dev/null @@ -1,66 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckMissingComponentsinAssets : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public CheckMissingComponentsinAssets(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var assets = GetAllAssetsWithMissingComponents(_config.ValidationPaths); - - if (assets.Length == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No assets have missing components!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following assets contain missing components", null, assets); - - return result; - } - - private GameObject[] GetAllAssetsWithMissingComponents(string[] validationPaths) - { - var missingReferenceAssets = new List(); - var prefabObjects = _assetUtility.GetObjectsFromAssets(validationPaths, AssetType.Prefab); - - foreach (var p in prefabObjects) - { - if (p != null && IsMissingReference(p)) - missingReferenceAssets.Add(p); - } - - return missingReferenceAssets.ToArray(); - } - - private bool IsMissingReference(GameObject asset) - { - var components = asset.GetComponentsInChildren(); - - foreach (var c in components) - { - if (!c) - return true; - } - - return false; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinAssets.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinAssets.cs.meta deleted file mode 100644 index d7e72f3..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinAssets.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 22d8f814e2363e34ea220736a4042728 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinScenes.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinScenes.cs deleted file mode 100644 index 3c0ee06..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinScenes.cs +++ /dev/null @@ -1,93 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Data.MessageActions; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.Linq; -using UnityEngine; -using SceneAsset = UnityEditor.SceneAsset; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckMissingComponentsinScenes : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - private ISceneUtilityService _sceneUtility; - - public CheckMissingComponentsinScenes(GenericTestConfig config, IAssetUtilityService assetUtility, ISceneUtilityService sceneUtility) - { - _config = config; - _assetUtility = assetUtility; - _sceneUtility = sceneUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var originalScenePath = _sceneUtility.CurrentScenePath; - - var scenePaths = _assetUtility.GetAssetPathsFromAssets(_config.ValidationPaths, AssetType.Scene); - foreach (var scenePath in scenePaths) - { - var missingComponentGOs = GetMissingComponentGOsInScene(scenePath); - - if (missingComponentGOs.Count == 0) - continue; - - result.Status = TestResultStatus.VariableSeverityIssue; - var message = $"GameObjects with missing components or prefab references found in {scenePath}.\n\nClick this message to open the Scene and see the affected GameObjects:"; - result.AddMessage(message, new OpenAssetAction(_assetUtility.AssetPathToObject(scenePath)), missingComponentGOs.ToArray()); - } - - _sceneUtility.OpenScene(originalScenePath); - - if (result.Status == TestResultStatus.Undefined) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No missing components were found!"); - } - - return result; - } - - private List GetMissingComponentGOsInScene(string path) - { - var missingComponentGOs = new List(); - - var scene = _sceneUtility.OpenScene(path); - - if (!scene.IsValid()) - { - Debug.LogWarning("Unable to get Scene in " + path); - return new List(); - } - - var rootObjects = scene.GetRootGameObjects(); - - foreach (var obj in rootObjects) - { - missingComponentGOs.AddRange(GetMissingComponentGOs(obj)); - } - - return missingComponentGOs; - } - - private List GetMissingComponentGOs(GameObject root) - { - var missingComponentGOs = new List(); - var rootComponents = root.GetComponents(); - - if (UnityEditor.PrefabUtility.GetPrefabInstanceStatus(root) == UnityEditor.PrefabInstanceStatus.MissingAsset || rootComponents.Any(c => !c)) - { - missingComponentGOs.Add(root); - } - - foreach (Transform child in root.transform) - missingComponentGOs.AddRange(GetMissingComponentGOs(child.gameObject)); - - return missingComponentGOs; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinScenes.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinScenes.cs.meta deleted file mode 100644 index 3ff3408..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckMissingComponentsinScenes.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 511e76d0ebcb23d40a7b49dda0e2980f -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelImportLogs.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelImportLogs.cs deleted file mode 100644 index b628aac..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelImportLogs.cs +++ /dev/null @@ -1,64 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.Linq; -using UnityObject = UnityEngine.Object; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckModelImportLogs : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - private IModelUtilityService _modelUtility; - - public CheckModelImportLogs(GenericTestConfig config, IAssetUtilityService assetUtility, IModelUtilityService modelUtility) - { - _config = config; - _assetUtility = assetUtility; - _modelUtility = modelUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var models = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Model); - var importLogs = _modelUtility.GetImportLogs(models.ToArray()); - - var warningModels = new List(); - var errorModels = new List(); - - foreach (var kvp in importLogs) - { - if (kvp.Value.Any(x => x.Severity == UnityEngine.LogType.Error)) - errorModels.Add(kvp.Key); - if (kvp.Value.Any(x => x.Severity == UnityEngine.LogType.Warning)) - warningModels.Add(kvp.Key); - } - - if (warningModels.Count > 0 || errorModels.Count > 0) - { - if (warningModels.Count > 0) - { - result.Status = TestResultStatus.Warning; - result.AddMessage("The following models contain import warnings:", null, warningModels.ToArray()); - } - - if (errorModels.Count > 0) - { - result.Status = TestResultStatus.Warning; - result.AddMessage("The following models contain import errors:", null, errorModels.ToArray()); - } - } - else - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No issues were detected when importing your models!"); - } - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelImportLogs.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelImportLogs.cs.meta deleted file mode 100644 index 884b6cb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelImportLogs.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 98f3ec209166855408eaf4abe5bff591 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelOrientation.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelOrientation.cs deleted file mode 100644 index 82e9dd0..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelOrientation.cs +++ /dev/null @@ -1,71 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.Linq; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckModelOrientation : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - private IMeshUtilityService _meshUtility; - - public CheckModelOrientation(GenericTestConfig config, IAssetUtilityService assetUtility, IMeshUtilityService meshUtility) - { - _config = config; - _assetUtility = assetUtility; - _meshUtility = meshUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var models = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Model); - var badModels = new List(); - - foreach (var m in models) - { - var meshes = _meshUtility.GetCustomMeshesInObject(m); - var assetImporter = _assetUtility.GetAssetImporter(m); - - if (!(assetImporter is UnityEditor.ModelImporter modelImporter)) - continue; - - var clips = modelImporter.clipAnimations.Length; - - // Only check if the model has meshes and no clips - if (!meshes.Any() || clips != 0) - continue; - - Transform[] transforms = m.GetComponentsInChildren(true); - - foreach (var t in transforms) - { - var hasMeshComponent = t.TryGetComponent(out _) || t.TryGetComponent(out _); - - if (t.localRotation == Quaternion.identity || !hasMeshComponent) - continue; - - badModels.Add(m); - break; - } - } - - if (badModels.Count == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("All found models are facing the right way!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following models have incorrect rotation", null, badModels.ToArray()); - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelOrientation.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelOrientation.cs.meta deleted file mode 100644 index 7e8243e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelOrientation.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 56cdcdc41a80fbc46b5b2b83ec8d66d7 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelTypes.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelTypes.cs deleted file mode 100644 index a434a0c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelTypes.cs +++ /dev/null @@ -1,58 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.Linq; -using UnityEditor; -using UnityObject = UnityEngine.Object; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckModelTypes : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public CheckModelTypes(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var allowedExtensions = new string[] { ".fbx", ".dae", ".abc", ".obj" }; - // Should retrieve All assets and not models here since ADB will not recognize certain - // types if appropriate software is not installed (e.g. .blend without Blender) - var allAssetPaths = _assetUtility.GetAssetPathsFromAssets(_config.ValidationPaths, AssetType.All); - var badModels = new List(); - - foreach (var assetPath in allAssetPaths) - { - var importer = _assetUtility.GetAssetImporter(assetPath); - if (importer == null || !(importer is ModelImporter)) - continue; - - if (allowedExtensions.Any(x => importer.assetPath.ToLower().EndsWith(x))) - continue; - - badModels.Add(_assetUtility.AssetPathToObject(assetPath)); - } - - if (badModels.Count == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("All models are of allowed formats!"); - } - else - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following models are of formats that should not be used for Asset Store packages:", null, badModels.ToArray()); - } - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelTypes.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelTypes.cs.meta deleted file mode 100644 index 6f45fa7..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckModelTypes.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 428b1fb838e6f5a469bbfd26ca3fbfd2 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckNormalMapTextures.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckNormalMapTextures.cs deleted file mode 100644 index d911351..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckNormalMapTextures.cs +++ /dev/null @@ -1,94 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckNormalMapTextures : ITestScript - { - public const int TextureCacheLimit = 8; - - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public CheckNormalMapTextures(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var materials = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Material); - var badTextures = new List(); - var badPaths = new List(); - - foreach (var mat in materials) - { - for (int i = 0; i < mat.shader.GetPropertyCount(); i++) - { - if ((mat.shader.GetPropertyFlags(i) & UnityEngine.Rendering.ShaderPropertyFlags.Normal) != 0) - { - var propertyName = mat.shader.GetPropertyName(i); - var assignedTexture = mat.GetTexture(propertyName); - - if (assignedTexture == null) - continue; - - var texturePath = _assetUtility.ObjectToAssetPath(assignedTexture); - var textureImporter = _assetUtility.GetAssetImporter(texturePath) as TextureImporter; - if (textureImporter == null) - continue; - - if (textureImporter.textureType != TextureImporterType.NormalMap && !badTextures.Contains(assignedTexture)) - { - if (badTextures.Count < TextureCacheLimit) - { - badTextures.Add(assignedTexture); - } - else - { - string path = AssetDatabase.GetAssetPath(assignedTexture); - badPaths.Add(path); - } - } - } - } - - EditorUtility.UnloadUnusedAssetsImmediate(); - } - - if (badTextures.Count == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("All normal map textures have the correct texture type!"); - } - else if (badPaths.Count != 0) - { - foreach (Texture texture in badTextures) - { - string path = AssetDatabase.GetAssetPath(texture); - badPaths.Add(path); - } - - string paths = string.Join("\n", badPaths); - - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following textures are not set to type 'Normal Map'", null); - result.AddMessage(paths); - } - else - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following textures are not set to type 'Normal Map'", null, badTextures.ToArray()); - } - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckNormalMapTextures.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckNormalMapTextures.cs.meta deleted file mode 100644 index f996702..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckNormalMapTextures.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: d55cea510248f814eb2194c2b53f88d2 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPackageNaming.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPackageNaming.cs deleted file mode 100644 index 5b9bf46..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPackageNaming.cs +++ /dev/null @@ -1,295 +0,0 @@ -using AssetStoreTools.Utility; -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckPackageNaming : ITestScript - { - private const string ForbiddenCharacters = "~`!@#$%^&*()-_=+[{]}\\|;:'\",<>?/"; - private readonly string[] PathsToCheckForForbiddenCharacters = new string[] - { - "Assets/", - "Assets/Editor/", - "Assets/Plugins/", - "Assets/Resources/", - "Assets/StreamingAssets/", - "Assets/WebGLTemplates/" - }; - - private class PathCheckResult - { - public Object[] InvalidMainPaths; - public Object[] InvalidMainPathContentPaths; - public Object[] InvalidMainPathLeadingUpPaths; - public Object[] InvalidHybridPackages; - public Object[] PotentiallyInvalidContent; - - public bool HasIssues => InvalidMainPaths.Length > 0 - || InvalidMainPathContentPaths.Length > 0 - || InvalidMainPathLeadingUpPaths.Length > 0 - || InvalidHybridPackages.Length > 0 - || PotentiallyInvalidContent.Length > 0; - } - - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - // Constructor also accepts dependency injection of registered IValidatorService types - public CheckPackageNaming(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var checkResult = GetInvalidPathsInAssets(); - - if (checkResult.HasIssues) - { - result.Status = TestResultStatus.Warning; - - if (checkResult.InvalidMainPaths.Length > 0) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following assets appear to be artificially bumped up in the project hierarchy within commonly used folders", null, checkResult.InvalidMainPaths); - } - - if (checkResult.InvalidMainPathContentPaths.Length > 0) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following assets appear to be artificially bumped up in the project hierarchy within commonly used folders", null, checkResult.InvalidMainPathContentPaths); - } - - if (checkResult.InvalidMainPathLeadingUpPaths.Length > 0) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("Despite not being directly validated, this path would be automatically created by the Unity Importer when importing your package", null, checkResult.InvalidMainPathLeadingUpPaths); - } - - if (checkResult.InvalidHybridPackages.Length > 0) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following packages appear to be artificially bumped up in the Package hierarchy with their 'Display Name' configuration", null, checkResult.InvalidHybridPackages); - } - - if (checkResult.PotentiallyInvalidContent.Length > 0) - { - // Do not override previously set severities - result.AddMessage("It is recommended that nested package content refrains from starting with a special character", null, checkResult.PotentiallyInvalidContent); - } - } - else - { - result.Status = TestResultStatus.Pass; - result.AddMessage("All package asset names are valid!"); - } - - return result; - } - - private PathCheckResult GetInvalidPathsInAssets() - { - var allInvalidMainPaths = new List(); - var allInvalidMainContentPaths = new List(); - var allInvalidMainLeadingUpPaths = new List(); - var allInvalidPackagePaths = new List(); - var allInvalidOtherContentPaths = new List(); - - foreach (var validationPath in _config.ValidationPaths) - { - // Is path itself not forbidden e.g.: when validating Assets/_Package, the folder _Package would be invalid - if (!IsDirectMainPathValid(validationPath)) - allInvalidMainPaths.Add(validationPath); - - // Are path contents not forbidden e.g.: when validating Assets/, the folder _Package would be invalid - if (!IsDirectMainPathContentValid(validationPath, out var invalidContentPaths)) - allInvalidMainContentPaths.AddRange(invalidContentPaths); - - // Is the path leading up to this path not forbidden e.g: when validating Assets/_WorkDir/Package, the folder _Workdir would be invalid - if (!IsPathLeadingUpToMainPathValid(validationPath, out var invalidLeadingUpPath)) - allInvalidMainLeadingUpPaths.Add(invalidLeadingUpPath); - - // Is the path pointing to a package valid, e.g.: when validating Packages/com.company.product its display name _Product would be invalid - if (!IsHybridPackageMainPathValid(validationPath, out string invalidPackagePath)) - allInvalidPackagePaths.Add(invalidPackagePath); - } - - var ignoredPaths = new List(); - ignoredPaths.AddRange(allInvalidMainPaths); - ignoredPaths.AddRange(allInvalidMainContentPaths); - ignoredPaths.AddRange(allInvalidMainLeadingUpPaths); - ignoredPaths.AddRange(allInvalidPackagePaths); - - // Mark any other paths that start with a forbidden character - if (!ArePackageContentsValid(ignoredPaths, out var invalidContents)) - allInvalidOtherContentPaths.AddRange(invalidContents); - - return new PathCheckResult() - { - InvalidMainPaths = PathsToObjects(allInvalidMainPaths), - InvalidMainPathContentPaths = PathsToObjects(allInvalidMainContentPaths), - InvalidMainPathLeadingUpPaths = PathsToObjects(allInvalidMainLeadingUpPaths), - InvalidHybridPackages = PathsToObjects(allInvalidPackagePaths), - PotentiallyInvalidContent = PathsToObjects(allInvalidOtherContentPaths) - }; - } - - private bool IsDirectMainPathValid(string validationPath) - { - foreach (var forbiddenPath in PathsToCheckForForbiddenCharacters) - { - var forbiddenPathWithSeparator = forbiddenPath.EndsWith("/") ? forbiddenPath : forbiddenPath + "/"; - if (!validationPath.StartsWith(forbiddenPathWithSeparator)) - continue; - - var truncatedPath = validationPath.Remove(0, forbiddenPathWithSeparator.Length); - var truncatedPathSplit = truncatedPath.Split('/'); - - // It is not a direct main path if it has deeper paths - if (truncatedPathSplit.Length != 1) - continue; - - if (ForbiddenCharacters.Any(x => truncatedPath.StartsWith(x.ToString()))) - return false; - } - - return true; - } - - private bool IsDirectMainPathContentValid(string validationPath, out List invalidContentPaths) - { - invalidContentPaths = new List(); - - var contents = Directory.EnumerateFileSystemEntries(validationPath, "*", SearchOption.AllDirectories) - .Where(x => !x.EndsWith(".meta")) - .Select(GetAdbPath); - - foreach (var contentPath in contents) - { - foreach (var forbiddenPath in PathsToCheckForForbiddenCharacters) - { - var forbiddenPathWithSeparator = forbiddenPath.EndsWith("/") ? forbiddenPath : forbiddenPath + "/"; - if (!contentPath.StartsWith(forbiddenPathWithSeparator)) - continue; - - var truncatedPath = contentPath.Remove(0, forbiddenPathWithSeparator.Length); - var truncatedPathSplit = truncatedPath.Split('/'); - - // Only check the first level of content relative to the forbidden path - if (truncatedPathSplit.Length > 1) - continue; - - if (ForbiddenCharacters.Any(x => truncatedPathSplit[0].StartsWith(x.ToString()))) - invalidContentPaths.Add(contentPath); - } - } - - return invalidContentPaths.Count == 0; - } - - private bool IsPathLeadingUpToMainPathValid(string validationPath, out string invalidLeadingUpPath) - { - invalidLeadingUpPath = string.Empty; - - foreach (var forbiddenPath in PathsToCheckForForbiddenCharacters) - { - var forbiddenPathWithSeparator = forbiddenPath.EndsWith("/") ? forbiddenPath : forbiddenPath + "/"; - if (!validationPath.StartsWith(forbiddenPathWithSeparator)) - continue; - - var truncatedPath = validationPath.Remove(0, forbiddenPathWithSeparator.Length); - var truncatedPathSplit = truncatedPath.Split('/'); - - // It is not a leading up path if it has no deeper path - if (truncatedPathSplit.Length == 1) - continue; - - if (ForbiddenCharacters.Any(x => truncatedPathSplit[0].StartsWith(x.ToString()))) - { - invalidLeadingUpPath = forbiddenPathWithSeparator + truncatedPathSplit[0]; - return false; - } - } - - return true; - } - - private bool IsHybridPackageMainPathValid(string validationPath, out string invalidPackagePath) - { - invalidPackagePath = string.Empty; - - if (!PackageUtility.GetPackageByManifestPath($"{validationPath}/package.json", out var package)) - return true; - - var packageName = package.displayName; - if (ForbiddenCharacters.Any(x => packageName.StartsWith(x.ToString()))) - { - invalidPackagePath = validationPath; - return false; - } - - return true; - } - - private bool ArePackageContentsValid(IEnumerable ignoredPaths, out List invalidContentPaths) - { - invalidContentPaths = new List(); - - foreach (var validationPath in _config.ValidationPaths) - { - var validationPathFolderName = validationPath.Split('/').Last(); - if (!ignoredPaths.Contains(validationPath) && ForbiddenCharacters.Any(x => validationPathFolderName.StartsWith(x.ToString()))) - invalidContentPaths.Add(validationPath); - - var contents = Directory.EnumerateFileSystemEntries(validationPath, "*", SearchOption.AllDirectories) - .Where(x => !x.EndsWith(".meta")) - .Select(GetAdbPath); - - foreach (var contentEntry in contents) - { - if (ignoredPaths.Contains(contentEntry)) - continue; - - var entryName = contentEntry.Split('/').Last(); - if (ForbiddenCharacters.Any(x => entryName.StartsWith(x.ToString()))) - invalidContentPaths.Add(contentEntry); - } - } - - return invalidContentPaths.Count == 0; - } - - private string GetAdbPath(string path) - { - path = path.Replace("\\", "/"); - if (path.StartsWith(Constants.RootProjectPath)) - path = path.Remove(Constants.RootProjectPath.Length); - - return path; - } - - private Object[] PathsToObjects(IEnumerable paths) - { - var objects = new List(); - - foreach (var path in paths) - { - var obj = _assetUtility.AssetPathToObject(path); - if (obj != null) - objects.Add(obj); - } - - return objects.ToArray(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPackageNaming.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPackageNaming.cs.meta deleted file mode 100644 index bf1c234..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPackageNaming.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: afe9e04825c7d904981a54404b222290 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckParticleSystems.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckParticleSystems.cs deleted file mode 100644 index 8e69b10..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckParticleSystems.cs +++ /dev/null @@ -1,76 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Data.MessageActions; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckParticleSystems : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - private ISceneUtilityService _sceneUtility; - - public CheckParticleSystems(GenericTestConfig config, IAssetUtilityService assetUtility, ISceneUtilityService sceneUtility) - { - _config = config; - _assetUtility = assetUtility; - _sceneUtility = sceneUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var originalScenePath = _sceneUtility.CurrentScenePath; - - var scenePaths = _assetUtility.GetAssetPathsFromAssets(_config.ValidationPaths, AssetType.Scene); - - foreach (var path in scenePaths) - { - var badParticleSystems = new List(); - - var scene = _sceneUtility.OpenScene(path); - - if (!scene.IsValid()) - { - Debug.LogWarning("Unable to get Scene in " + path); - continue; - } - -#if UNITY_2023_1_OR_NEWER - var particleSystems = GameObject.FindObjectsByType(FindObjectsInactive.Include, FindObjectsSortMode.None); -#else - var particleSystems = GameObject.FindObjectsOfType(); -#endif - - foreach (var ps in particleSystems) - { - if (PrefabUtility.IsPartOfAnyPrefab(ps.gameObject)) - continue; - badParticleSystems.Add(ps); - } - - if (badParticleSystems.Count == 0) - continue; - - result.Status = TestResultStatus.VariableSeverityIssue; - var message = $"Particle Systems not belonging to any Prefab were found in {path}.\n\nClick this message to open the Scene and see the affected Particle Systems:"; - result.AddMessage(message, new OpenAssetAction(AssetDatabase.LoadAssetAtPath(path)), badParticleSystems.ToArray()); - } - - _sceneUtility.OpenScene(originalScenePath); - - if (result.Status == TestResultStatus.Undefined) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No Particle Systems without Prefabs were found!"); - } - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckParticleSystems.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckParticleSystems.cs.meta deleted file mode 100644 index 66a1881..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckParticleSystems.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 6a623f7988c75884bb17b169ccd3e993 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPathLengths.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPathLengths.cs deleted file mode 100644 index 27750c5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPathLengths.cs +++ /dev/null @@ -1,98 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using AssetStoreTools.Validator.Utility; -using System.Collections.Generic; -using System.Linq; -using UnityEditor; -using UnityObject = UnityEngine.Object; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckPathLengths : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public CheckPathLengths(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - TestResult result = new TestResult(); - - int pathLengthLimit = 140; - // Get all project paths and sort by length so that folders always come before files - var allPaths = ValidatorUtility.GetProjectPaths(_config.ValidationPaths).OrderBy(x => x.Length); - - var filteredDirs = new Dictionary(); - var filteredFiles = new Dictionary(); - - foreach (var path in allPaths) - { - // Truncated path examples: - // Assets/[Scenes/SampleScene.unity] - // Packages/com.example.package/[Editor/EditorScript.cs] - var truncatedPath = path; - if (path.StartsWith("Assets/")) - truncatedPath = path.Remove(0, "Assets/".Length); - else if (path.StartsWith("Packages/")) - { - var splitPath = path.Split('/'); - truncatedPath = string.Join("/", splitPath.Skip(2)); - } - - // Skip paths under the character limit - if (truncatedPath.Length < pathLengthLimit) - continue; - - // Skip children of already added directories - if (filteredDirs.Keys.Any(x => truncatedPath.StartsWith(x))) - continue; - - if (AssetDatabase.IsValidFolder(path)) - { - filteredDirs.Add(truncatedPath, _assetUtility.AssetPathToObject(path)); - continue; - } - - if (!filteredFiles.ContainsKey(truncatedPath)) - filteredFiles.Add(truncatedPath, _assetUtility.AssetPathToObject(path)); - } - - if (filteredDirs.Count == 0 && filteredFiles.Count == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("All package content matches the path limit criteria!"); - return result; - } - - if (filteredDirs.Count > 0) - { - var maxDirLength = filteredDirs.Keys.Aggregate("", (max, cur) => max.Length > cur.Length ? max : cur); - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage($"The following folders exceed the path length limit:"); - foreach (var kvp in filteredDirs) - { - result.AddMessage($"Path length: {kvp.Key.Length} characters", null, kvp.Value); - } - } - - if (filteredFiles.Count > 0) - { - var maxFileLength = filteredFiles.Keys.Aggregate("", (max, cur) => max.Length > cur.Length ? max : cur); - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage($"The following files exceed the path length limit:"); - foreach (var kvp in filteredFiles) - { - result.AddMessage($"Path length: {kvp.Key.Length} characters", null, kvp.Value); - } - } - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPathLengths.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPathLengths.cs.meta deleted file mode 100644 index ff8f8ed..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPathLengths.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: ae379305e9165e84584373a8272c09e7 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPrefabTransforms.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPrefabTransforms.cs deleted file mode 100644 index aa01881..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPrefabTransforms.cs +++ /dev/null @@ -1,71 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.Linq; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckPrefabTransforms : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - private IMeshUtilityService _meshUtility; - - public CheckPrefabTransforms(GenericTestConfig config, IAssetUtilityService assetUtility, IMeshUtilityService meshUtility) - { - _config = config; - _assetUtility = assetUtility; - _meshUtility = meshUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var prefabs = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Prefab); - var badPrefabs = new List(); - var badPrefabsLowOffset = new List(); - - foreach (var p in prefabs) - { - var hasRectTransform = p.TryGetComponent(out RectTransform _); - if (hasRectTransform || !_meshUtility.GetCustomMeshesInObject(p).Any()) - continue; - - var positionString = p.transform.position.ToString("F12"); - var rotationString = p.transform.rotation.eulerAngles.ToString("F12"); - var localScaleString = p.transform.localScale.ToString("F12"); - - var vectorZeroString = Vector3.zero.ToString("F12"); - var vectorOneString = Vector3.one.ToString("F12"); - - if (positionString != vectorZeroString || rotationString != vectorZeroString || localScaleString != vectorOneString) - { - if (p.transform.position == Vector3.zero && p.transform.rotation.eulerAngles == Vector3.zero && p.transform.localScale == Vector3.one) - badPrefabsLowOffset.Add(p); - else - badPrefabs.Add(p); - } - } - - if (badPrefabs.Count == 0 && badPrefabsLowOffset.Count == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("All found prefabs were reset!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - if (badPrefabs.Count > 0) - result.AddMessage("The following prefabs' transforms do not fit the requirements", null, badPrefabs.ToArray()); - if (badPrefabsLowOffset.Count > 0) - result.AddMessage("The following prefabs have unusually low transform values, which might not be accurately displayed " + - "in the Inspector window. Please use the 'Debug' Inspector mode to review the Transform component of these prefabs " + - "or reset the Transform components using the right-click context menu", null, badPrefabsLowOffset.ToArray()); - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPrefabTransforms.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPrefabTransforms.cs.meta deleted file mode 100644 index 60db269..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckPrefabTransforms.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: f712c17a60bf2d049a4e61c8f79e56c2 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckScriptCompilation.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckScriptCompilation.cs deleted file mode 100644 index 034f457..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckScriptCompilation.cs +++ /dev/null @@ -1,30 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.TestDefinitions; -using UnityEditor; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckScriptCompilation : ITestScript - { - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var hasCompilationErrors = EditorUtility.scriptCompilationFailed; - - if (hasCompilationErrors) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("One or more scripts in the project failed to compile.\n" + - "Please check the Console window to see the list of errors"); - } - else - { - result.Status = TestResultStatus.Pass; - result.AddMessage("All scripts in the project compiled successfully!"); - } - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckScriptCompilation.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckScriptCompilation.cs.meta deleted file mode 100644 index 47d2849..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckScriptCompilation.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 59db88f43969db8499299bce7f4fb967 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckShaderCompilation.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckShaderCompilation.cs deleted file mode 100644 index a004feb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckShaderCompilation.cs +++ /dev/null @@ -1,63 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Linq; -using UnityEditor; -using UnityEngine; -#if !UNITY_2023_1_OR_NEWER -using UnityEngine.Experimental.Rendering; -#endif -#if UNITY_2023_1_OR_NEWER -using UnityEngine.Rendering; -#endif - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckShaderCompilation : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public CheckShaderCompilation(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var shaders = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Shader); - var badShaders = shaders.Where(ShaderHasError).ToArray(); - - if (badShaders.Length > 0) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following shader files have errors", null, badShaders); - } - else - { - result.Status = TestResultStatus.Pass; - result.AddMessage("All found Shaders have no compilation errors!"); - } - - return result; - } - - private bool ShaderHasError(Object obj) - { - switch (obj) - { - case Shader shader: - return ShaderUtil.ShaderHasError(shader); - case ComputeShader shader: - return ShaderUtil.GetComputeShaderMessageCount(shader) > 0; - case RayTracingShader shader: - return ShaderUtil.GetRayTracingShaderMessageCount(shader) > 0; - default: - return false; - } - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckShaderCompilation.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckShaderCompilation.cs.meta deleted file mode 100644 index 43f501a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckShaderCompilation.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 7abb278a6082bde4391e0779394cb85b -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTextureDimensions.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTextureDimensions.cs deleted file mode 100644 index d05c1ae..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTextureDimensions.cs +++ /dev/null @@ -1,57 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckTextureDimensions : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public CheckTextureDimensions(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var textures = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Texture); - var badTextures = new List(); - - foreach (var texture in textures) - { - if (Mathf.IsPowerOfTwo(texture.width) && Mathf.IsPowerOfTwo(texture.height)) - continue; - - var importer = _assetUtility.GetAssetImporter(_assetUtility.ObjectToAssetPath(texture)); - - if (importer == null || !(importer is TextureImporter textureImporter) - || textureImporter.textureType == TextureImporterType.Sprite - || textureImporter.textureType == TextureImporterType.GUI) - continue; - - badTextures.Add(texture); - } - - if (badTextures.Count == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("All texture dimensions are a power of 2!"); - } - else - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following texture dimensions are not a power of 2:", null, badTextures.ToArray()); - } - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTextureDimensions.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTextureDimensions.cs.meta deleted file mode 100644 index bc0d1cf..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTextureDimensions.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 073f1dacf3da34d4783140ae9d485d5f -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTypeNamespaces.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTypeNamespaces.cs deleted file mode 100644 index 35c9d4d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTypeNamespaces.cs +++ /dev/null @@ -1,233 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System; -using System.Collections.Generic; -using System.Linq; -using UnityEditor; -using UnityObject = UnityEngine.Object; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckTypeNamespaces : ITestScript - { - private readonly string[] ForbiddenNamespaces = new string[] { "Unity" }; - - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - private IScriptUtilityService _scriptUtility; - - private enum NamespaceEligibility - { - NoNamespace, - Ok, - Forbidden - } - - private class AnalysisResult - { - public Dictionary> TypesWithoutNamespaces; - public Dictionary> ForbiddenNamespaces; - - public bool HasIssues => TypesWithoutNamespaces.Count > 0 - || ForbiddenNamespaces.Count > 0; - } - - public CheckTypeNamespaces(GenericTestConfig config, IAssetUtilityService assetUtility, IScriptUtilityService scriptUtility) - { - _config = config; - _assetUtility = assetUtility; - _scriptUtility = scriptUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var scriptResult = CheckScripts(); - var assemblyResult = CheckAssemblies(); - - if (scriptResult.HasIssues || assemblyResult.HasIssues) - { - result.Status = TestResultStatus.Warning; - - // Error conditions for forbidden namespaces - - if (scriptResult.ForbiddenNamespaces.Count > 0) - { - result.Status = TestResultStatus.Fail; - result.AddMessage("The following scripts contain namespaces starting with a 'Unity' keyword:"); - AddJoinedMessage(result, scriptResult.ForbiddenNamespaces); - } - - if (assemblyResult.ForbiddenNamespaces.Count > 0) - { - result.Status = TestResultStatus.Fail; - result.AddMessage("The following assemblies contain namespaces starting with a 'Unity' keyword:"); - AddJoinedMessage(result, assemblyResult.ForbiddenNamespaces); - } - - // Variable severity conditions for no-namespace types - - if (scriptResult.TypesWithoutNamespaces.Count > 0) - { - if (result.Status != TestResultStatus.Fail) - result.Status = TestResultStatus.VariableSeverityIssue; - - result.AddMessage("The following scripts contain types not nested under a namespace:"); - AddJoinedMessage(result, scriptResult.TypesWithoutNamespaces); - } - - if (assemblyResult.TypesWithoutNamespaces.Count > 0) - { - if (result.Status != TestResultStatus.Fail) - result.Status = TestResultStatus.VariableSeverityIssue; - - result.AddMessage("The following assemblies contain types not nested under a namespace:"); - AddJoinedMessage(result, assemblyResult.TypesWithoutNamespaces); - } - } - else - { - result.Status = TestResultStatus.Pass; - result.AddMessage("All scripts contain valid namespaces!"); - } - - return result; - } - - private AnalysisResult CheckScripts() - { - var scripts = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.MonoScript).ToArray(); - var scriptNamespaces = _scriptUtility.GetTypeNamespacesFromScriptAssets(scripts); - - var scriptsWithoutNamespaces = new Dictionary>(); - var scriptsWithForbiddenNamespaces = new Dictionary>(); - - foreach (var kvp in scriptNamespaces) - { - var scriptAsset = kvp.Key; - var typesInScriptAsset = kvp.Value; - - var typesWithoutNamespace = new List(); - var discouragedNamespaces = new List(); - var forbiddenNamespaces = new List(); - - foreach (var t in typesInScriptAsset) - { - var eligibility = CheckNamespaceEligibility(t.Namespace); - - switch (eligibility) - { - case NamespaceEligibility.NoNamespace: - typesWithoutNamespace.Add(t.Name); - break; - case NamespaceEligibility.Forbidden: - if (!forbiddenNamespaces.Contains(t.Namespace)) - forbiddenNamespaces.Add(t.Namespace); - break; - case NamespaceEligibility.Ok: - break; - } - } - - if (typesWithoutNamespace.Count > 0) - scriptsWithoutNamespaces.Add(scriptAsset, typesWithoutNamespace); - - if (forbiddenNamespaces.Count > 0) - scriptsWithForbiddenNamespaces.Add(scriptAsset, forbiddenNamespaces); - } - - return new AnalysisResult - { - TypesWithoutNamespaces = scriptsWithoutNamespaces, - ForbiddenNamespaces = scriptsWithForbiddenNamespaces - }; - } - - private AnalysisResult CheckAssemblies() - { - var assemblies = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.PrecompiledAssembly).ToList(); - var assemblyTypes = _scriptUtility.GetTypesFromAssemblies(assemblies); - - var assembliesWithoutNamespaces = new Dictionary>(); - var assembliesWithForbiddenNamespaces = new Dictionary>(); - - foreach (var kvp in assemblyTypes) - { - var assemblyAsset = kvp.Key; - var typesInAssembly = kvp.Value; - - var typesWithoutNamespace = new List(); - var discouragedNamespaces = new List(); - var forbiddenNamespaces = new List(); - - foreach (var t in typesInAssembly) - { - var eligibility = CheckNamespaceEligibility(t.Namespace); - - switch (eligibility) - { - case NamespaceEligibility.NoNamespace: - typesWithoutNamespace.Add($"{GetTypeName(t)} {t.Name}"); - break; - case NamespaceEligibility.Forbidden: - if (!forbiddenNamespaces.Contains(t.Namespace)) - forbiddenNamespaces.Add(t.Namespace); - break; - case NamespaceEligibility.Ok: - break; - } - } - - if (typesWithoutNamespace.Count > 0) - assembliesWithoutNamespaces.Add(assemblyAsset, typesWithoutNamespace); - - if (forbiddenNamespaces.Count > 0) - assembliesWithForbiddenNamespaces.Add(assemblyAsset, forbiddenNamespaces); - } - - return new AnalysisResult - { - TypesWithoutNamespaces = assembliesWithoutNamespaces, - ForbiddenNamespaces = assembliesWithForbiddenNamespaces - }; - } - - private NamespaceEligibility CheckNamespaceEligibility(string fullNamespace) - { - if (string.IsNullOrEmpty(fullNamespace)) - return NamespaceEligibility.NoNamespace; - - var split = fullNamespace.Split('.'); - var topLevelNamespace = split[0]; - if (ForbiddenNamespaces.Any(x => topLevelNamespace.StartsWith(x, StringComparison.OrdinalIgnoreCase))) - return NamespaceEligibility.Forbidden; - - return NamespaceEligibility.Ok; - } - - private string GetTypeName(Type type) - { - if (type.IsClass) - return "class"; - if (type.IsInterface) - return "interface"; - if (type.IsEnum) - return "enum"; - if (type.IsValueType) - return "struct"; - - throw new ArgumentException($"Received an unrecognizable type {type}. Type must be either a class, interface, struct or enum"); - } - - private void AddJoinedMessage(TestResult result, Dictionary> assetsWithMessages) - { - foreach (var kvp in assetsWithMessages) - { - var message = string.Join("\n", kvp.Value); - result.AddMessage(message, null, kvp.Key); - } - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTypeNamespaces.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTypeNamespaces.cs.meta deleted file mode 100644 index e18155a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/CheckTypeNamespaces.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 279249fa7ef8c2446b3a9f013eeedbf0 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveExecutableFiles.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveExecutableFiles.cs deleted file mode 100644 index 71f31bc..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveExecutableFiles.cs +++ /dev/null @@ -1,38 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Linq; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class RemoveExecutableFiles : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public RemoveExecutableFiles(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var executables = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Executable).ToArray(); - - if (executables.Length == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No executable files were found!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following executable files were found", null, executables); - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveExecutableFiles.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveExecutableFiles.cs.meta deleted file mode 100644 index 04899bc..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveExecutableFiles.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 8e4450592cc60e54286ad089b66db94d -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJPGFiles.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJPGFiles.cs deleted file mode 100644 index 3a5a4c7..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJPGFiles.cs +++ /dev/null @@ -1,38 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Linq; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class RemoveJPGFiles : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public RemoveJPGFiles(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var jpgs = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.JPG).ToArray(); - - if (jpgs.Length == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No JPG/JPEG textures were found!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following textures are compressed as JPG/JPEG", null, jpgs); - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJPGFiles.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJPGFiles.cs.meta deleted file mode 100644 index bc21513..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJPGFiles.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 5634a12b3a8544c4585bbc280ae59ce2 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJavaScriptFiles.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJavaScriptFiles.cs deleted file mode 100644 index 69a7681..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJavaScriptFiles.cs +++ /dev/null @@ -1,38 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Linq; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class RemoveJavaScriptFiles : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public RemoveJavaScriptFiles(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var javascriptObjects = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.JavaScript).ToArray(); - - if (javascriptObjects.Length == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No UnityScript / JS files were found!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following assets are UnityScript / JS files", null, javascriptObjects); - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJavaScriptFiles.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJavaScriptFiles.cs.meta deleted file mode 100644 index 791abf8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveJavaScriptFiles.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: ab1676bde9afba442b35fd3319c18063 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveLossyAudioFiles.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveLossyAudioFiles.cs deleted file mode 100644 index 6cdc77a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveLossyAudioFiles.cs +++ /dev/null @@ -1,83 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text.RegularExpressions; -using UnityObject = UnityEngine.Object; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class RemoveLossyAudioFiles : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public RemoveLossyAudioFiles(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - string SanitizeForComparison(UnityObject o) - { - Regex alphanumericRegex = new Regex("[^a-zA-Z0-9]"); - string path = _assetUtility.ObjectToAssetPath(o); - path = path.ToLower(); - - int extensionIndex = path.LastIndexOf('.'); - string extension = path.Substring(extensionIndex + 1); - string sanitized = path.Substring(0, extensionIndex); - - int separatorIndex = sanitized.LastIndexOf('/'); - sanitized = sanitized.Substring(separatorIndex); - sanitized = alphanumericRegex.Replace(sanitized, String.Empty); - sanitized = sanitized.Replace(extension, String.Empty); - sanitized = sanitized.Trim(); - - return sanitized; - } - - var lossyAudioObjects = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.LossyAudio).ToArray(); - if (lossyAudioObjects.Length == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No lossy audio files were found!"); - return result; - } - - // Try to find and match variants - var nonLossyAudioObjects = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.NonLossyAudio); - HashSet nonLossyPathSet = new HashSet(); - foreach (var asset in nonLossyAudioObjects) - { - var path = SanitizeForComparison(asset); - nonLossyPathSet.Add(path); - } - - var unmatchedAssets = new List(); - foreach (var asset in lossyAudioObjects) - { - var path = SanitizeForComparison(asset); - if (!nonLossyPathSet.Contains(path)) - unmatchedAssets.Add(asset); - } - - if (unmatchedAssets.Count == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No lossy audio files were found!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following lossy audio files were found without identically named non-lossy variants:", null, unmatchedAssets.ToArray()); - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveLossyAudioFiles.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveLossyAudioFiles.cs.meta deleted file mode 100644 index 729af7f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveLossyAudioFiles.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: b7205a85061273a4eb50586f13f35d35 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveMixamoFiles.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveMixamoFiles.cs deleted file mode 100644 index 17a1cb2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveMixamoFiles.cs +++ /dev/null @@ -1,38 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Linq; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class RemoveMixamoFiles : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public RemoveMixamoFiles(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var mixamoFiles = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Mixamo).ToArray(); - - if (mixamoFiles.Length == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No Mixamo files were found!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following Mixamo files were found", null, mixamoFiles); - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveMixamoFiles.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveMixamoFiles.cs.meta deleted file mode 100644 index 7a1e4f8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveMixamoFiles.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 9df432e52aa958b44bb5e20c13d16552 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveSpeedTreeFiles.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveSpeedTreeFiles.cs deleted file mode 100644 index feef230..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveSpeedTreeFiles.cs +++ /dev/null @@ -1,38 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Linq; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class RemoveSpeedTreeFiles : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public RemoveSpeedTreeFiles(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var speedtreeObjects = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.SpeedTree).ToArray(); - - if (speedtreeObjects.Length == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No SpeedTree assets have been found!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following SpeedTree assets have been found", null, speedtreeObjects); - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveSpeedTreeFiles.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveSpeedTreeFiles.cs.meta deleted file mode 100644 index 855dbe2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveSpeedTreeFiles.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: e06bb7e0aa4f9944abc18281c002dff4 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveVideoFiles.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveVideoFiles.cs deleted file mode 100644 index ae0e5ff..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveVideoFiles.cs +++ /dev/null @@ -1,38 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Linq; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class RemoveVideoFiles : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public RemoveVideoFiles(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var videos = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.Video).ToArray(); - - if (videos.Length == 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No video files were found, looking good!"); - return result; - } - - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("The following video files were found", null, videos); - - return result; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveVideoFiles.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveVideoFiles.cs.meta deleted file mode 100644 index 98aea88..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/Generic/RemoveVideoFiles.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: f99724c71b0de66419b5d6e8e9bfcc2d -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage.meta deleted file mode 100644 index b8fde81..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 016d62b2cd8346a49815615efd1d6e39 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDemoScenes.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDemoScenes.cs deleted file mode 100644 index 6c635c2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDemoScenes.cs +++ /dev/null @@ -1,172 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using Newtonsoft.Json.Linq; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using UnityEditor; -using UnityEngine; -using UnityObject = UnityEngine.Object; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckDemoScenes : ITestScript - { - private class DemoSceneScanResult - { - public List ValidAdbScenes; - public List HybridScenePaths; - public List NestedUnityPackages; - } - - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - private ISceneUtilityService _sceneUtility; - - public CheckDemoScenes(GenericTestConfig config, IAssetUtilityService assetUtility, ISceneUtilityService sceneUtility) - { - _config = config; - _assetUtility = assetUtility; - _sceneUtility = sceneUtility; - } - - public TestResult Run() - { - var result = new TestResult(); - var demoSceneScanResult = CheckForDemoScenes(_config); - - // Valid demo scenes were found in ADB - if (demoSceneScanResult.ValidAdbScenes.Count > 0) - { - result.Status = TestResultStatus.Pass; - result.AddMessage("Demo scenes found", null, demoSceneScanResult.ValidAdbScenes.ToArray()); - return result; - } - - // Valid demo scenes found in UPM package.json - if (demoSceneScanResult.HybridScenePaths.Count > 0) - { - result.Status = TestResultStatus.Pass; - - var upmSampleSceneList = string.Join("\n-", demoSceneScanResult.HybridScenePaths); - upmSampleSceneList = upmSampleSceneList.Insert(0, "-"); - - result.AddMessage($"Demo scenes found:\n{upmSampleSceneList}"); - return result; - } - - // No valid scenes found, but package contains nested .unitypackages - if (demoSceneScanResult.NestedUnityPackages.Count > 0) - { - result.Status = TestResultStatus.Warning; - result.AddMessage("Could not find any valid Demo scenes in the selected validation paths."); - result.AddMessage("The following nested .unitypackage files were found. " + - "If they contain any demo scenes, you can ignore this warning.", null, demoSceneScanResult.NestedUnityPackages.ToArray()); - return result; - } - - // No valid scenes were found and there is nothing pointing to their inclusion in the package - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("Could not find any valid Demo Scenes in the selected validation paths."); - return result; - } - - private DemoSceneScanResult CheckForDemoScenes(GenericTestConfig config) - { - var scanResult = new DemoSceneScanResult(); - scanResult.ValidAdbScenes = CheckForDemoScenesInAssetDatabase(config); - scanResult.HybridScenePaths = CheckForDemoScenesInUpmSamples(config); - scanResult.NestedUnityPackages = CheckForNestedUnityPackages(config); - - return scanResult; - } - - private List CheckForDemoScenesInAssetDatabase(GenericTestConfig config) - { - var scenePaths = _assetUtility.GetAssetPathsFromAssets(config.ValidationPaths, AssetType.Scene).ToArray(); - if (scenePaths.Length == 0) - return new List(); - - var originalScenePath = _sceneUtility.CurrentScenePath; - var validScenePaths = scenePaths.Where(CanBeDemoScene).ToArray(); - _sceneUtility.OpenScene(originalScenePath); - - if (validScenePaths.Length == 0) - return new List(); - - return validScenePaths.Select(x => AssetDatabase.LoadAssetAtPath(x)).ToList(); - } - - private bool CanBeDemoScene(string scenePath) - { - // Check skybox - var sceneSkyboxPath = _assetUtility.ObjectToAssetPath(RenderSettings.skybox).Replace("\\", "").Replace("/", ""); - var defaultSkyboxPath = "Resources/unity_builtin_extra".Replace("\\", "").Replace("/", ""); - - if (!sceneSkyboxPath.Equals(defaultSkyboxPath, StringComparison.OrdinalIgnoreCase)) - return true; - - // Check GameObjects - _sceneUtility.OpenScene(scenePath); - var rootObjects = _sceneUtility.GetRootGameObjects(); - var count = rootObjects.Length; - - if (count == 0) - return false; - - if (count != 2) - return true; - - var cameraGOUnchanged = rootObjects.Any(o => o.TryGetComponent(out _) && o.GetComponents(typeof(Component)).Length == 3); - var lightGOUnchanged = rootObjects.Any(o => o.TryGetComponent(out _) && o.GetComponents(typeof(Component)).Length == 2); - - return !cameraGOUnchanged || !lightGOUnchanged; - } - - private List CheckForDemoScenesInUpmSamples(GenericTestConfig config) - { - var scenePaths = new List(); - - foreach (var path in config.ValidationPaths) - { - if (!File.Exists($"{path}/package.json")) - continue; - - var packageJsonText = File.ReadAllText($"{path}/package.json"); - var json = JObject.Parse(packageJsonText); - - if (!json.ContainsKey("samples") || json["samples"].Type != JTokenType.Array || json["samples"].ToList().Count == 0) - continue; - - foreach (var sample in json["samples"].ToList()) - { - var samplePath = sample["path"].ToString(); - samplePath = $"{path}/{samplePath}"; - if (!Directory.Exists(samplePath)) - continue; - - var sampleScenePaths = Directory.GetFiles(samplePath, "*.unity", SearchOption.AllDirectories); - foreach (var scenePath in sampleScenePaths) - { - // If meta file is not found, the sample will not be included with the exported .unitypackage - if (!File.Exists($"{scenePath}.meta")) - continue; - - if (!scenePaths.Contains(scenePath.Replace("\\", "/"))) - scenePaths.Add(scenePath.Replace("\\", "/")); - } - } - } - - return scenePaths; - } - - private List CheckForNestedUnityPackages(GenericTestConfig config) - { - var unityPackages = _assetUtility.GetObjectsFromAssets(config.ValidationPaths, AssetType.UnityPackage).ToArray(); - return unityPackages.ToList(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDemoScenes.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDemoScenes.cs.meta deleted file mode 100644 index 2707290..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDemoScenes.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: f844c2dfa4669ff4eacf5591b544edaf -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDocumentation.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDocumentation.cs deleted file mode 100644 index 1799c1d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDocumentation.cs +++ /dev/null @@ -1,73 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System; -using System.IO; -using System.Linq; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckDocumentation : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - public CheckDocumentation(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var textFilePaths = _assetUtility.GetAssetPathsFromAssets(_config.ValidationPaths, AssetType.Documentation).ToArray(); - var documentationFilePaths = textFilePaths.Where(CouldBeDocumentation).ToArray(); - - if (textFilePaths.Length == 0) - { - result.Status = TestResultStatus.VariableSeverityIssue; - result.AddMessage("No potential documentation files ('.txt', '.pdf', " + - "'.html', '.rtf', '.md') found within the given path."); - } - else if (documentationFilePaths.Length == 0) - { - result.Status = TestResultStatus.Warning; - var textFileObjects = textFilePaths.Select(_assetUtility.AssetPathToObject).ToArray(); - result.AddMessage("The following files have been found to match the documentation file format," + - " but may not be documentation in content", - null, textFileObjects); - } - else - { - result.Status = TestResultStatus.Pass; - var documentationFileObjects = documentationFilePaths.Select(_assetUtility.AssetPathToObject).ToArray(); - result.AddMessage("Found documentation files", null, documentationFileObjects); - } - - return result; - } - - private bool CouldBeDocumentation(string filePath) - { - if (filePath.EndsWith(".pdf")) - return true; - - using (var fs = File.Open(filePath, FileMode.Open)) - using (var bs = new BufferedStream(fs)) - using (var sr = new StreamReader(bs)) - { - string line; - while ((line = sr.ReadLine()) != null) - { - var mentionsDocumentation = line.IndexOf("documentation", StringComparison.OrdinalIgnoreCase) >= 0; - if (mentionsDocumentation) - return true; - } - } - - return false; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDocumentation.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDocumentation.cs.meta deleted file mode 100644 index f8cea26..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckDocumentation.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 3c8425198983eda4c9b35aa0d59ea33c -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckPackageSize.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckPackageSize.cs deleted file mode 100644 index caa8ac6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckPackageSize.cs +++ /dev/null @@ -1,69 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.TestDefinitions; -using System.IO; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckPackageSize : ITestScript - { - private GenericTestConfig _config; - - public CheckPackageSize(GenericTestConfig config) - { - _config = config; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var packageSize = CalculatePackageSize(_config.ValidationPaths); - float packageSizeInGB = packageSize / (1024f * 1024f * 1024f); - float maxPackageSizeInGB = Constants.Uploader.MaxPackageSizeBytes / (1024f * 1024f * 1024f); - - if (packageSizeInGB - maxPackageSizeInGB >= 0.1f) - { - result.Status = TestResultStatus.Warning; - - result.AddMessage($"The uncompressed size of your package ({packageSizeInGB:0.#} GB) exceeds the maximum allowed package size of {maxPackageSizeInGB:0.#} GB. " + - $"Please make sure that the compressed .unitypackage size does not exceed the size limit."); - } - else - { - result.Status = TestResultStatus.Pass; - result.AddMessage("Your package does not exceed the maximum allowed package size!"); - } - - return result; - } - - private long CalculatePackageSize(string[] assetPaths) - { - long totalSize = 0; - - foreach (var path in assetPaths) - { - totalSize += CalculatePathSize(path); - } - - return totalSize; - } - - private long CalculatePathSize(string path) - { - long size = 0; - - var dirInfo = new DirectoryInfo(path); - if (!dirInfo.Exists) - return size; - - foreach (var file in dirInfo.EnumerateFiles()) - size += file.Length; - - foreach (var nestedDir in dirInfo.EnumerateDirectories()) - size += CalculatePathSize(nestedDir.FullName); - - return size; - } - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckPackageSize.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckPackageSize.cs.meta deleted file mode 100644 index 1909c93..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckPackageSize.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a8601b99f4afa5049954f3a2dd5996d6 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckProjectTemplateAssets.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckProjectTemplateAssets.cs deleted file mode 100644 index eab7aee..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckProjectTemplateAssets.cs +++ /dev/null @@ -1,217 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services.Validation; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.Linq; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator.TestMethods -{ - internal class CheckProjectTemplateAssets : ITestScript - { - private GenericTestConfig _config; - private IAssetUtilityService _assetUtility; - - // Constructor also accepts dependency injection of registered IValidatorService types - public CheckProjectTemplateAssets(GenericTestConfig config, IAssetUtilityService assetUtility) - { - _config = config; - _assetUtility = assetUtility; - } - - public TestResult Run() - { - var result = new TestResult() { Status = TestResultStatus.Undefined }; - - var assets = _assetUtility.GetObjectsFromAssets(_config.ValidationPaths, AssetType.All); - var invalidAssetsByGuid = CheckGuids(assets); - var invalidAssetsByPath = CheckPaths(assets); - - var hasIssues = invalidAssetsByGuid.Length > 0 - || invalidAssetsByPath.Length > 0; - - if (hasIssues) - { - result.Status = TestResultStatus.VariableSeverityIssue; - - if (invalidAssetsByPath.Length > 0) - { - result.AddMessage("The following assets were found to have an asset path which is common to project template asset paths. They should be renamed or moved:", null, invalidAssetsByPath); - } - - if (invalidAssetsByGuid.Length > 0) - { - result.AddMessage("The following assets were found to be using a GUID which is common to project template asset GUIDs. They should be assigned a new GUID:", null, invalidAssetsByGuid); - } - } - else - { - result.Status = TestResultStatus.Pass; - result.AddMessage("No common assets that might cause asset clashing were found!"); - } - - return result; - } - - private Object[] CheckGuids(IEnumerable assets) - { - var clashingAssets = new List(); - foreach (var asset in assets) - { - if (!AssetDatabase.TryGetGUIDAndLocalFileIdentifier(asset, out var guid, out long _)) - continue; - - if (CommonTemplateAssets.Any(x => x.Key.Equals(guid, System.StringComparison.OrdinalIgnoreCase))) - clashingAssets.Add(asset); - } - - return clashingAssets.ToArray(); - } - - private Object[] CheckPaths(IEnumerable assets) - { - var clashingAssets = new List(); - foreach (var asset in assets) - { - var assetPath = AssetDatabase.GetAssetPath(asset); - if (CommonTemplateAssets.Any(x => x.Value.Equals(assetPath, System.StringComparison.OrdinalIgnoreCase))) - clashingAssets.Add(asset); - } - - return clashingAssets.ToArray(); - } - - private Dictionary CommonTemplateAssets = new Dictionary() - { - {"3f9215ea0144899419cfbc0957140d3f", "Assets/DefaultVolumeProfile.asset"}, - {"3d4c13846a3e9bd4c8ccfbd0657ed847", "Assets/DefaultVolumeProfile.asset"}, - {"4cee8bca36f2ab74b8feb832747fa6f4", "Assets/Editor/com.unity.mobile.notifications/NotificationSettings.asset"}, - {"45a04f37e0f48c744acc0874c4a8918a", "Assets/Editor/com.unity.mobile.notifications/NotificationSettings.asset"}, - {"54a3a0570aebe8949bec4966f1376581", "Assets/HDRPDefaultResources/DefaultHDRISky.exr"}, - {"e93c35b24eb03c74284e7dc0b755bfcc", "Assets/HDRPDefaultResources/DefaultHDRPAsset.asset"}, - {"254320a857a30444da2c99496a186368", "Assets/HDRPDefaultResources/DefaultLookDevProfile.asset"}, - {"2bfa7b9d63fa79e4abdc033f54a868d2", "Assets/HDRPDefaultResources/DefaultSceneRoot.prefab"}, - {"f9e3ff5a1b8f49c4fa8686e68d2dadae", "Assets/HDRPDefaultResources/DefaultSceneRoot.prefab"}, - {"d87f7d7815073e840834a16a518c1237", "Assets/HDRPDefaultResources/DefaultSettingsVolumeProfile.asset"}, - {"145290c901d58b343bdeb3b4362c9ff2", "Assets/HDRPDefaultResources/DefaultVFXResources.asset"}, - {"acc11144f57719542b5fa25f02e74afb", "Assets/HDRPDefaultResources/HDRenderPipelineGlobalSettings.asset"}, - {"582adbd84082fdb4faf7cd4beb1ccd14", "Assets/HDRPDefaultResources/HDRPDefaultSettings.asset"}, - {"2801c2ff7303a7543a8727f862f6c236", "Assets/HDRPDefaultResources/Sky and Fog Settings Profile.asset"}, - {"ea5c25297f0c0a04da0eabb1c26a7509", "Assets/HDRPDefaultResources/SkyFogSettingsProfile.asset"}, - {"3590b91b4603b465dbb4216d601bff33", "Assets/InputSystem_Actions.inputactions"}, - {"289c1b55c9541489481df5cc06664110", "Assets/InputSystem_Actions.inputactions"}, - {"dc70d2c4f369241dd99afd7c451b813e", "Assets/InputSystem_Actions.inputactions"}, - {"2bcd2660ca9b64942af0de543d8d7100", "Assets/InputSystem_Actions.inputactions"}, - {"052faaac586de48259a63d0c4782560b", "Assets/InputSystem_Actions.inputactions"}, - {"35845fe01580c41289b024647b1d1c53", "Assets/InputSystem_Actions.inputactions"}, - {"8124e5870f4fd4c779e7a5f994e84ad1", "Assets/OutdoorsScene.unity"}, - {"2dd802e4d37c65149922028d3e973832", "Assets/Presets/AudioCompressedInMemory.preset"}, - {"e18fd6ecd9cdb524ca99844f39b9d9ac", "Assets/Presets/AudioCompressedInMemory.preset"}, - {"86bcce7f5575b54408aa0f3a7d321039", "Assets/Presets/AudioStreaming.preset"}, - {"460e573eb8466884baaa0b8475505f83", "Assets/Presets/AudioStreaming.preset"}, - {"e8537455c6c08bd4e8bf0be3707da685", "Assets/Presets/Defaults/AlbedoTexture_Default.preset"}, - {"7a99f8aa944efe94cb9bd74562b7d5f9", "Assets/Presets/Defaults/AlbedoTexture_Default.preset"}, - {"0cd792cc87e492d43b4e95b205fc5cc6", "Assets/Presets/Defaults/AudioDecompressOnLoad_Default.preset"}, - {"e7689051185d12f4298e1ebb2693a29f", "Assets/Presets/Defaults/AudioDecompressOnLoad.preset"}, - {"463065d4f17d1d94d848aa127b94dd43", "Assets/Presets/Defaults/DirectionalLight_Default.preset"}, - {"c1cf8506f04ef2c4a88b64b6c4202eea", "Assets/Presets/Defaults/DirectionalLight_Default.preset"}, - {"8fa3055e2a1363246838debd20206d37", "Assets/Presets/Defaults/SSSSettings_Default.preset"}, - {"78830bb1431cab940b74be615e2a739f", "Assets/Presets/HDRTexture.preset"}, - {"14a57cf3b9fa1c74b884aa7e0dcf1faa", "Assets/Presets/NormalTexture.preset"}, - {"1d826a4c23450f946b19c20560595a1f", "Assets/Presets/NormalTexture.preset"}, - {"45f7b2e3c78185248b3adbb14429c2ab", "Assets/Presets/UtilityTexture.preset"}, - {"78fae3569c6c66c46afc3d9d4fb0b8d4", "Assets/Presets/UtilityTexture.preset"}, - {"9303d565bd8aa6948ba775e843320e4d", "Assets/Presets/UtilityTexture.preset"}, - {"34f54ff1ff9415249a847506b6f2fec5", "Assets/Scenes/PrefabEditingScene.unity"}, - {"cbfe36cfddfde964d9dfce63a355d5dd", "Assets/Scenes/samplescene.unity"}, - {"2cda990e2423bbf4892e6590ba056729", "Assets/Scenes/SampleScene.unity"}, - {"9fc0d4010bbf28b4594072e72b8655ab", "Assets/Scenes/SampleScene.unity"}, - {"3db1837cc97a95e4c98610966fac2b0b", "Assets/Scenes/SampleScene.unity"}, - {"3fc8acdd13e6c734bafef6554d6fdbcd", "Assets/Scenes/SampleScene.unity"}, - {"8c9cfa26abfee488c85f1582747f6a02", "Assets/Scenes/SampleScene.unity"}, - {"c850ee8c3b14cc8459e7e186857cf567", "Assets/Scenes/SampleScene.unity"}, - {"99c9720ab356a0642a771bea13969a05", "Assets/Scenes/SampleScene.unity"}, - {"d1c3109bdb54ad54c8a2b2838528e640", "Assets/Scenes/SampleScene.unity"}, - {"477cc4148fad3449482a3bc3178594e2", "Assets/Scenes/SampleSceneLightingSettings.lighting"}, - {"4eb578550bc4f824e97f0a72eac1f3a5", "Assets/Scripts/LookWithMouse.cs"}, - {"87f6dfceb3e39a947a312f7eeaa2a113", "Assets/Scripts/PlayerMovement.cs"}, - {"be76e5f14cfee674cb30b491fb72b09b", "Assets/Scripts/SimpleCameraController.cs"}, - {"6547d18b2bc62c94aa5ec1e87434da4e", "Assets/Scripts/SimpleCameraController.cs"}, - {"e8a636f62116c0a40bbfefdf876d4608", "Assets/Scripts/SimpleCameraController.cs"}, - {"14e519c409be4a1428028347410f5677", "Assets/Scripts/SimpleCameraController.cs"}, - {"a04c28107d77d5e42b7155783b8475b6", "Assets/Settings/Cockpit_Renderer.asset"}, - {"ab09877e2e707104187f6f83e2f62510", "Assets/Settings/DefaultVolumeProfile.asset"}, - {"238cd62f6b58cb04e9c94749c4a015a7", "Assets/Settings/DefaultVolumeProfile.asset"}, - {"5a9a2dc462c7bde4f86d0615a19c2c72", "Assets/Settings/DiffusionProfiles/BambooLeaves.asset"}, - {"78322c7f82657514ebe48203160e3f39", "Assets/Settings/Foliage.asset"}, - {"3e2e6bfc59709614ab90c0cd7d755e48", "Assets/Settings/HDRP Balanced.asset"}, - {"36dd385e759c96147b6463dcd1149c11", "Assets/Settings/HDRP High Fidelity.asset"}, - {"168a2336534e4e043b2a210b6f8d379a", "Assets/Settings/HDRP Performant.asset"}, - {"4594f4a3fb14247e192bcca6dc23c8ed", "Assets/Settings/HDRPDefaultResources/DefaultLookDevProfile.asset"}, - {"14b392ee213d25a48b1feddbd9f5a9be", "Assets/Settings/HDRPDefaultResources/DefaultSettingsVolumeProfile.asset"}, - {"879ffae44eefa4412bb327928f1a96dd", "Assets/Settings/HDRPDefaultResources/FoliageDiffusionProfile.asset"}, - {"b9f3086da92434da0bc1518f19f0ce86", "Assets/Settings/HDRPDefaultResources/HDRenderPipelineAsset.asset"}, - {"ac0316ca287ba459492b669ff1317a6f", "Assets/Settings/HDRPDefaultResources/HDRenderPipelineGlobalSettings.asset"}, - {"48e911a1e337b44e2b85dbc65b47a594", "Assets/Settings/HDRPDefaultResources/SkinDiffusionProfile.asset"}, - {"d03ed43fc9d8a4f2e9fa70c1c7916eb9", "Assets/Settings/Lit2DSceneTemplate.scenetemplate"}, - {"65bc7dbf4170f435aa868c779acfb082", "Assets/Settings/Mobile_Renderer.asset"}, - {"5e6cbd92db86f4b18aec3ed561671858", "Assets/Settings/Mobile_RPAsset.asset"}, - {"23cccccf13c3d4170a9b21e52a9bc86b", "Assets/Settings/Mobile/Mobile_High_ScreenRenderer.asset"}, - {"6e8f76111115f44e0a76c2bff3cec258", "Assets/Settings/Mobile/Mobile_Low_Renderer.asset"}, - {"aed30aee6a3ceae4090dadd1934d2ad0", "Assets/Settings/Mobile/Mobile_Low_ScreenRenderer.asset"}, - {"d7686b11d09df481bac3c76ecc5ea626", "Assets/Settings/Mobile/Mobile_Low.asset"}, - {"f288ae1f4751b564a96ac7587541f7a2", "Assets/Settings/PC_Renderer.asset"}, - {"4b83569d67af61e458304325a23e5dfd", "Assets/Settings/PC_RPAsset.asset"}, - {"42b230d443c6d6c4b89c47f97db59121", "Assets/Settings/PC/PC_High_ScreenRenderer.asset"}, - {"13ba41cd2fa191f43890b271bd110ed9", "Assets/Settings/PC/PC_Low_Renderer.asset"}, - {"a73f6fa069dd14a42b40cbb01bae63b4", "Assets/Settings/PC/PC_Low_ScreenRenderer.asset"}, - {"4eb9ff6b5314098428cfa0be7e36ccda", "Assets/Settings/PC/PC_Low.asset"}, - {"573ac53c334415945bf239de2c2f0511", "Assets/Settings/PlayerControllerFPS.prefab"}, - {"7ba2b06fb32e5274aad88925a5b8d3f5", "Assets/Settings/PostProcessVolumeProfile.asset"}, - {"424799608f7334c24bf367e4bbfa7f9a", "Assets/Settings/Renderer2D.asset"}, - {"183cbd347d25080429f42b520742bbd8", "Assets/Settings/SampleScenePostProcessingSettings.asset"}, - {"10fc4df2da32a41aaa32d77bc913491c", "Assets/Settings/SampleSceneProfile.asset"}, - {"a6560a915ef98420e9faacc1c7438823", "Assets/Settings/SampleSceneProfile.asset"}, - {"a123fc0ac58cb774e8592c925f167e7c", "Assets/Settings/SampleSceneSkyandFogSettings.asset"}, - {"26bdddf49760c61438938733f07fa2a2", "Assets/Settings/Skin.asset"}, - {"8ba92e2dd7f884a0f88b98fa2d235fe7", "Assets/Settings/SkyandFogSettingsProfile.asset"}, - {"4a8e21d5c33334b11b34a596161b9360", "Assets/Settings/UniversalRenderer.asset"}, - {"18dc0cd2c080841dea60987a38ce93fa", "Assets/Settings/UniversalRenderPipelineGlobalSettings.asset"}, - {"bdede76083021864d8ff8bf23b2f37f1", "Assets/Settings/UniversalRenderPipelineGlobalSettings.asset"}, - {"19ba41d7c0026c3459d37c2fe90c55a0", "Assets/Settings/UniversalRP-HighQuality.asset"}, - {"a31e9f9f9c9d4b9429ed0d1234e22103", "Assets/Settings/UniversalRP-LowQuality.asset"}, - {"d847b876476d3d6468f5dfcd34266f96", "Assets/Settings/UniversalRP-MediumQuality.asset"}, - {"681886c5eb7344803b6206f758bf0b1c", "Assets/Settings/UniversalRP.asset"}, - {"e634585d5c4544dd297acaee93dc2beb", "Assets/Settings/URP-Balanced-Renderer.asset"}, - {"e1260c1148f6143b28bae5ace5e9c5d1", "Assets/Settings/URP-Balanced.asset"}, - {"c40be3174f62c4acf8c1216858c64956", "Assets/Settings/URP-HighFidelity-Renderer.asset"}, - {"7b7fd9122c28c4d15b667c7040e3b3fd", "Assets/Settings/URP-HighFidelity.asset"}, - {"707360a9c581a4bd7aa53bfeb1429f71", "Assets/Settings/URP-Performant-Renderer.asset"}, - {"d0e2fc18fe036412f8223b3b3d9ad574", "Assets/Settings/URP-Performant.asset"}, - {"b62413aeefabaaa41a4b5a71dd7ae1ac", "Assets/Settings/VolumeProfiles/CinematicProfile.asset"}, - {"ac0c2cad5778d4544b6a690963e02fe3", "Assets/Settings/VolumeProfiles/DefaultVolumeProfile.asset"}, - {"f2d4d916a6612574cad220d125febbf2", "Assets/Settings/VolumeProfiles/LowQualityVolumeProfile.asset"}, - {"cef078630d63d0442a070f84d4f13735", "Assets/Settings/VolumeProfiles/MarketProfile.asset"}, - {"7ede9c9f109e5c442b7d29e54b4996fc", "Assets/Settings/VolumeProfiles/MediaOverrides.asset"}, - {"3532e98caae428047bcefe69a344f72c", "Assets/Settings/VolumeProfiles/OutlineEnabled.asset"}, - {"bfc08ba7e35de1a44bb84a32f1a693e1", "Assets/Settings/VolumeProfiles/ZenGardenProfile.asset"}, - {"59a34a3881431c246b3564a0f0ca5bb0", "Assets/Settings/Volumes/CinematicPhysicalCamera.asset"}, - {"03bc34b71695890468eb021c73b228db", "Assets/Settings/Volumes/ScreenshotsTimelineProfile.asset"}, - {"7f342610b85f4164f808a1f380dcc668", "Assets/Settings/Volumes/VolumeGlobal.asset"}, - {"bd6d234073408c44ca3828113aac655e", "Assets/Settings/Volumes/VolumeRoom1.asset"}, - {"d78a1b031ab26034eb6ec3cbc9fbcec3", "Assets/Settings/Volumes/VolumeRoom2.asset"}, - {"5727d3e07f75c3744b6cc8a1e55850a9", "Assets/Settings/Volumes/VolumeRoom2Skylight.asset"}, - {"06114ad16a0bc0a41957375ac3bf472e", "Assets/Settings/Volumes/VolumeRoom3.asset"}, - {"1584bf21cf81d5147aa00e8a2deaf2fb", "Assets/Settings/Volumes/VolumeRoom3Corridor.asset"}, - {"7bca3a07cdd522c4c8020832c20b3eae", "Assets/Settings/Volumes/VolumeRoom3Sitting.asset"}, - {"2872d90954412244a8b4a477b939c3ca", "Assets/Settings/XR/Loaders/Mock_HMD_Loader.asset"}, - {"f25758a0f79593d4a9b3ee30a17b4c2e", "Assets/Settings/XR/Loaders/Oculus_Loader.asset"}, - {"9e9f2958d1b4b4642ace1d0c7770650b", "Assets/Settings/XR/Settings/Mock_HMD_Build_Settings.asset"}, - {"290a6e6411d135049940bec2237b8938", "Assets/Settings/XR/Settings/Oculus_Settings.asset"}, - {"4c1640683c539c14080cfd43fbeffbda", "Assets/Settings/XR/XRGeneralSettings.asset"}, - {"93b439a37f63240aca3dd4e01d978a9f", "Assets/UniversalRenderPipelineGlobalSettings.asset"}, - {"38b35347542e5af4c9b140950c5b18db", "Assets/UniversalRenderPipelineGlobalSettings.asset"} - }; - } -} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckProjectTemplateAssets.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckProjectTemplateAssets.cs.meta deleted file mode 100644 index 804f84b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Test Methods/UnityPackage/CheckProjectTemplateAssets.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: f02d52a702c712e4e8089f7c2e65bae7 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI.meta deleted file mode 100644 index f401e9e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 0eed33a351c3c544ba6bf3cd29d24c26 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data.meta deleted file mode 100644 index c3a170c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 461bfd99d0923cd4a8dae2f440af1064 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions.meta deleted file mode 100644 index 93d4155..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: d7d9c6cc805e072429392e7a378d2c9c -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorResults.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorResults.cs deleted file mode 100644 index 676b70c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorResults.cs +++ /dev/null @@ -1,15 +0,0 @@ -using AssetStoreTools.Validator.Data; -using System; -using System.Collections.Generic; - -namespace AssetStoreTools.Validator.UI.Data -{ - internal interface IValidatorResults - { - event Action OnResultsChanged; - event Action OnRequireSerialize; - - void LoadResult(ValidationResult result); - IEnumerable GetSortedTestGroups(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorResults.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorResults.cs.meta deleted file mode 100644 index c914281..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorResults.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 91c62333b36d5ef47989289e8f90c056 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorSettings.cs deleted file mode 100644 index d439b0d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorSettings.cs +++ /dev/null @@ -1,31 +0,0 @@ -using AssetStoreTools.Validator.Data; -using System; -using System.Collections.Generic; - -namespace AssetStoreTools.Validator.UI.Data -{ - internal interface IValidatorSettings - { - event Action OnCategoryChanged; - event Action OnValidationTypeChanged; - event Action OnValidationPathsChanged; - event Action OnRequireSerialize; - - void LoadSettings(ValidationSettings settings); - - string GetActiveCategory(); - void SetActiveCategory(string category); - List GetAvailableCategories(); - - ValidationType GetValidationType(); - void SetValidationType(ValidationType validationType); - - List GetValidationPaths(); - void AddValidationPath(string path); - void RemoveValidationPath(string path); - void ClearValidationPaths(); - bool IsValidationPathValid(string path, out string error); - - IValidator CreateValidator(); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorSettings.cs.meta deleted file mode 100644 index d907440..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: cc6516196465ac6469258ef8950da607 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTest.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTest.cs deleted file mode 100644 index 1dcafce..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTest.cs +++ /dev/null @@ -1,15 +0,0 @@ -using AssetStoreTools.Validator.Data; - -namespace AssetStoreTools.Validator.UI.Data -{ - internal interface IValidatorTest - { - int Id { get; } - string Name { get; } - string Description { get; } - ValidationType ValidationType { get; } - TestResult Result { get; } - - void SetResult(TestResult result); - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTest.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTest.cs.meta deleted file mode 100644 index f1cbf25..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTest.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: d1e4d9ba8de8cfc4aa42786fbbc5037a -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTestGroup.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTestGroup.cs deleted file mode 100644 index 81b8d8f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTestGroup.cs +++ /dev/null @@ -1,12 +0,0 @@ -using AssetStoreTools.Validator.Data; -using System.Collections.Generic; - -namespace AssetStoreTools.Validator.UI.Data -{ - internal interface IValidatorTestGroup - { - string Name { get; } - TestResultStatus Status { get; } - IEnumerable Tests { get; } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTestGroup.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTestGroup.cs.meta deleted file mode 100644 index 86c6b56..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Abstractions/IValidatorTestGroup.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: fa8735b7eb65d3147ab8bdbf922f36cf -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization.meta deleted file mode 100644 index 4122afe..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: ec536685238584f41bd268edaaf0ad7d -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateData.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateData.cs deleted file mode 100644 index 4e75ed6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateData.cs +++ /dev/null @@ -1,28 +0,0 @@ -using Newtonsoft.Json; - -namespace AssetStoreTools.Validator.UI.Data.Serialization -{ - internal class ValidatorStateData - { - [JsonProperty("validation_settings")] - private ValidatorStateSettings _settings; - [JsonProperty("validation_results")] - private ValidatorStateResults _results; - - public ValidatorStateData() - { - _settings = new ValidatorStateSettings(); - _results = new ValidatorStateResults(); - } - - public ValidatorStateSettings GetSettings() - { - return _settings; - } - - public ValidatorStateResults GetResults() - { - return _results; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateData.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateData.cs.meta deleted file mode 100644 index eea46eb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateData.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: da7a885e302cb6b43855b68f44f2c0fc -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateDataContractResolver.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateDataContractResolver.cs deleted file mode 100644 index a72360a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateDataContractResolver.cs +++ /dev/null @@ -1,26 +0,0 @@ -using Newtonsoft.Json.Serialization; - -namespace AssetStoreTools.Validator.UI.Data.Serialization -{ - internal class ValidatorStateDataContractResolver : DefaultContractResolver - { - private static ValidatorStateDataContractResolver _instance; - public static ValidatorStateDataContractResolver Instance => _instance ?? (_instance = new ValidatorStateDataContractResolver()); - - private NamingStrategy _namingStrategy; - - private ValidatorStateDataContractResolver() - { - _namingStrategy = new SnakeCaseNamingStrategy(); - } - - protected override string ResolvePropertyName(string propertyName) - { - var resolvedName = _namingStrategy.GetPropertyName(propertyName, false); - if (resolvedName.StartsWith("_")) - return resolvedName.Substring(1); - - return resolvedName; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateDataContractResolver.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateDataContractResolver.cs.meta deleted file mode 100644 index 4187dca..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateDataContractResolver.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 60f0e8d9b2ab86547a288c337fb2be0a -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateResults.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateResults.cs deleted file mode 100644 index 3558822..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateResults.cs +++ /dev/null @@ -1,83 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.TestDefinitions; -using Newtonsoft.Json; -using System.Collections.Generic; - -namespace AssetStoreTools.Validator.UI.Data.Serialization -{ - internal class ValidatorStateResults - { - // Primary data - [JsonProperty("validation_status")] - private ValidationStatus _status; - [JsonProperty("test_results")] - private SortedDictionary _results; - - // Secondary data - [JsonProperty("project_path")] - private string _projectPath; - [JsonProperty("had_compilation_errors")] - private bool _hadCompilationErrors; - - public ValidatorStateResults() - { - _projectPath = string.Empty; - _status = ValidationStatus.NotRun; - _hadCompilationErrors = false; - _results = new SortedDictionary(); - } - - public ValidationStatus GetStatus() - { - return _status; - } - - public void SetStatus(ValidationStatus status) - { - if (_status == status) - return; - - _status = status; - } - - public SortedDictionary GetResults() - { - return _results; - } - - public void SetResults(IEnumerable tests) - { - _results.Clear(); - foreach (var test in tests) - { - _results.Add(test.Id, test.Result); - } - } - - public string GetProjectPath() - { - return _projectPath; - } - - public void SetProjectPath(string projectPath) - { - if (_projectPath == projectPath) - return; - - _projectPath = projectPath; - } - - public bool GetHadCompilationErrors() - { - return _hadCompilationErrors; - } - - public void SetHadCompilationErrors(bool hadCompilationErrors) - { - if (_hadCompilationErrors == hadCompilationErrors) - return; - - _hadCompilationErrors = hadCompilationErrors; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateResults.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateResults.cs.meta deleted file mode 100644 index 876eadb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateResults.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a90c3acfa50e8da4aa3da2b9c669502d -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateSettings.cs deleted file mode 100644 index 27cee0e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateSettings.cs +++ /dev/null @@ -1,63 +0,0 @@ -using AssetStoreTools.Validator.Data; -using Newtonsoft.Json; -using System.Collections.Generic; -using System.Linq; - -namespace AssetStoreTools.Validator.UI.Data.Serialization -{ - internal class ValidatorStateSettings - { - [JsonProperty("category")] - private string _category; - [JsonProperty("validation_type")] - private ValidationType _validationType; - [JsonProperty("validation_paths")] - private List _validationPaths; - - public ValidatorStateSettings() - { - _category = string.Empty; - _validationType = ValidationType.UnityPackage; - _validationPaths = new List(); - } - - public string GetCategory() - { - return _category; - } - - public void SetCategory(string category) - { - if (_category == category) - return; - - _category = category; - } - - public ValidationType GetValidationType() - { - return _validationType; - } - - public void SetValidationType(ValidationType validationType) - { - if (validationType == _validationType) - return; - - _validationType = validationType; - } - - public List GetValidationPaths() - { - return _validationPaths; - } - - public void SetValidationPaths(List validationPaths) - { - if (_validationPaths.SequenceEqual(validationPaths)) - return; - - _validationPaths = validationPaths; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateSettings.cs.meta deleted file mode 100644 index 0780a53..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/Serialization/ValidatorStateSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: d39d56313ade8a8409aafe95dc84f79a -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorResults.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorResults.cs deleted file mode 100644 index 38244c8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorResults.cs +++ /dev/null @@ -1,137 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.TestDefinitions; -using AssetStoreTools.Validator.UI.Data.Serialization; -using AssetStoreTools.Validator.Utility; -using System; -using System.Collections.Generic; -using System.Linq; - -namespace AssetStoreTools.Validator.UI.Data -{ - internal class ValidatorResults : IValidatorResults - { - private ValidatorStateResults _stateData; - - private IValidatorSettings _settings; - private IEnumerable _tests; - - private readonly TestResultStatus[] _priorityGroups = new TestResultStatus[] - { - TestResultStatus.Undefined, - TestResultStatus.Fail, - TestResultStatus.Warning - }; - - public event Action OnResultsChanged; - public event Action OnRequireSerialize; - - public ValidatorResults(IValidatorSettings settings, ValidatorStateResults stateData) - { - _settings = settings; - _stateData = stateData; - - _tests = GetAllTests(); - - Deserialize(); - } - - private IEnumerable GetAllTests() - { - var tests = new List(); - var testObjects = ValidatorUtility.GetAutomatedTestCases(ValidatorUtility.SortType.Alphabetical); - - foreach (var testObject in testObjects) - { - var testSource = new AutomatedTest(testObject); - var test = new ValidatorTest(testSource); - tests.Add(test); - } - - return tests; - } - - public void LoadResult(ValidationResult result) - { - if (result == null) - return; - - foreach (var test in _tests) - { - if (!result.Tests.Any(x => x.Id == test.Id)) - continue; - - var matchingResult = result.Tests.First(x => x.Id == test.Id); - test.SetResult(matchingResult.Result); - } - - OnResultsChanged?.Invoke(); - - Serialize(result); - } - - public IEnumerable GetSortedTestGroups() - { - var groups = new List(); - var testsByStatus = _tests - .Where(x => x.ValidationType == ValidationType.Generic || x.ValidationType == _settings.GetValidationType()) - .GroupBy(x => x.Result.Status).ToDictionary(x => x.Key, x => x.ToList()); - - foreach (var kvp in testsByStatus) - { - var group = new ValidatorTestGroup(kvp.Key, kvp.Value); - groups.Add(group); - } - - return SortGroups(groups); - } - - private IEnumerable SortGroups(IEnumerable unsortedGroups) - { - var sortedGroups = new List(); - var groups = unsortedGroups.OrderBy(x => x.Status).ToList(); - - // Select priority groups first - foreach (var priority in _priorityGroups) - { - var priorityGroup = groups.FirstOrDefault(x => x.Status == priority); - if (priorityGroup == null) - continue; - - sortedGroups.Add(priorityGroup); - groups.Remove(priorityGroup); - } - - // Add the rest - sortedGroups.AddRange(groups); - - return sortedGroups; - } - - private void Serialize(ValidationResult result) - { - _stateData.SetStatus(result.Status); - _stateData.SetResults(result.Tests); - _stateData.SetProjectPath(result.ProjectPath); - _stateData.SetHadCompilationErrors(result.HadCompilationErrors); - OnRequireSerialize?.Invoke(); - } - - private void Deserialize() - { - if (_stateData == null) - return; - - var serializedResults = _stateData.GetResults(); - foreach (var test in _tests) - { - if (!serializedResults.Any(x => x.Key == test.Id)) - continue; - - var matchingResult = serializedResults.First(x => x.Key == test.Id); - test.SetResult(matchingResult.Value); - } - - OnResultsChanged?.Invoke(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorResults.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorResults.cs.meta deleted file mode 100644 index 069816b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorResults.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: bf2839f8b2340294aae39c2965039d2a -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorSettings.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorSettings.cs deleted file mode 100644 index d65ab0c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorSettings.cs +++ /dev/null @@ -1,236 +0,0 @@ -using AssetStoreTools.Utility; -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.UI.Data.Serialization; -using AssetStoreTools.Validator.Utility; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using UnityEngine; - -namespace AssetStoreTools.Validator.UI.Data -{ - internal class ValidatorSettings : IValidatorSettings - { - private ValidatorStateSettings _stateData; - - private string _category; - private ValidationType _validationType; - private List _validationPaths; - - public event Action OnCategoryChanged; - public event Action OnValidationTypeChanged; - public event Action OnValidationPathsChanged; - public event Action OnRequireSerialize; - - public ValidatorSettings(ValidatorStateSettings stateData) - { - _stateData = stateData; - - _category = string.Empty; - _validationType = ValidationType.UnityPackage; - _validationPaths = new List(); - - Deserialize(); - } - - public void LoadSettings(ValidationSettings settings) - { - if (settings == null) - return; - - var currentProjectValidationSettings = settings as CurrentProjectValidationSettings; - if (currentProjectValidationSettings == null) - throw new ArgumentException($"Only {nameof(CurrentProjectValidationSettings)} can be loaded"); - - _category = currentProjectValidationSettings.Category; - OnCategoryChanged?.Invoke(); - - _validationType = currentProjectValidationSettings.ValidationType; - OnValidationTypeChanged?.Invoke(); - - _validationPaths = currentProjectValidationSettings.ValidationPaths.ToList(); - OnValidationPathsChanged?.Invoke(); - - Serialize(); - } - - public string GetActiveCategory() - { - return _category; - } - - public void SetActiveCategory(string category) - { - if (category == _category) - return; - - _category = category; - Serialize(); - OnCategoryChanged?.Invoke(); - } - - public List GetAvailableCategories() - { - var categories = new HashSet(); - - var testData = ValidatorUtility.GetAutomatedTestCases(); - foreach (var test in testData) - { - if (test.CategoryInfo == null) - continue; - - foreach (var filter in test.CategoryInfo.Filter) - categories.Add(ConvertSlashToUnicodeSlash(filter)); - } - - return categories.OrderBy(x => x).ToList(); - } - - private string ConvertSlashToUnicodeSlash(string text) - { - return text.Replace('/', '\u2215'); - } - - public ValidationType GetValidationType() - { - return _validationType; - } - - public void SetValidationType(ValidationType validationType) - { - if (validationType == _validationType) - return; - - _validationType = validationType; - - Serialize(); - OnValidationTypeChanged?.Invoke(); - } - - public List GetValidationPaths() - { - return _validationPaths; - } - - public void AddValidationPath(string path) - { - if (string.IsNullOrEmpty(path)) - return; - - if (_validationPaths.Contains(path)) - return; - - // Prevent redundancy for new paths - var existingPath = _validationPaths.FirstOrDefault(x => path.StartsWith(x + "/")); - if (existingPath != null) - { - Debug.LogWarning($"Path '{path}' is already included with existing path: '{existingPath}'"); - return; - } - - // Prevent redundancy for already added paths - var redundantPaths = _validationPaths.Where(x => x.StartsWith(path + "/")).ToArray(); - foreach (var redundantPath in redundantPaths) - { - Debug.LogWarning($"Existing validation path '{redundantPath}' has been made redundant by the inclusion of new validation path: '{path}'"); - _validationPaths.Remove(redundantPath); - } - - _validationPaths.Add(path); - - Serialize(); - OnValidationPathsChanged?.Invoke(); - } - - public void RemoveValidationPath(string path) - { - if (!_validationPaths.Contains(path)) - return; - - _validationPaths.Remove(path); - - Serialize(); - OnValidationPathsChanged?.Invoke(); - } - - public void ClearValidationPaths() - { - if (_validationPaths.Count == 0) - return; - - _validationPaths.Clear(); - - Serialize(); - OnValidationPathsChanged?.Invoke(); - } - - public bool IsValidationPathValid(string path, out string error) - { - error = string.Empty; - - if (string.IsNullOrEmpty(path)) - { - error = "Path cannot be empty"; - return false; - } - - var isAssetsPath = path.StartsWith("Assets/") - || path.Equals("Assets"); - var isPackagePath = PackageUtility.GetPackageByManifestPath($"{path}/package.json", out _); - - if (!isAssetsPath && !isPackagePath) - { - error = "Selected path must be within the Assets folder or point to a root path of a package"; - return false; - } - - if (!Directory.Exists(path)) - { - error = "Path does not exist"; - return false; - } - - if (path.Split('/').Any(x => x.StartsWith(".") || x.EndsWith("~"))) - { - error = $"Path '{path}' cannot be validated as it is a hidden folder and not part of the Asset Database"; - return false; - } - - return true; - } - - public IValidator CreateValidator() - { - var settings = new CurrentProjectValidationSettings() - { - Category = _category, - ValidationType = _validationType, - ValidationPaths = _validationPaths - }; - - var validator = new CurrentProjectValidator(settings); - return validator; - } - - private void Serialize() - { - _stateData.SetCategory(_category); - _stateData.SetValidationType(_validationType); - _stateData.SetValidationPaths(_validationPaths); - - OnRequireSerialize?.Invoke(); - } - - private void Deserialize() - { - if (_stateData == null) - return; - - _category = _stateData.GetCategory(); - _validationType = _stateData.GetValidationType(); - foreach (var path in _stateData.GetValidationPaths()) - _validationPaths.Add(path); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorSettings.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorSettings.cs.meta deleted file mode 100644 index 4905909..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorSettings.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 89504c2259614a743a164c5c162a197a -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTest.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTest.cs deleted file mode 100644 index 126cb4f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTest.cs +++ /dev/null @@ -1,28 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.TestDefinitions; - -namespace AssetStoreTools.Validator.UI.Data -{ - internal class ValidatorTest : IValidatorTest - { - public int Id { get; private set; } - public string Name { get; private set; } - public string Description { get; private set; } - public ValidationType ValidationType { get; private set; } - public TestResult Result { get; private set; } - - public ValidatorTest(AutomatedTest source) - { - Id = source.Id; - Name = source.Title; - Description = source.Description; - ValidationType = source.ValidationType; - Result = source.Result; - } - - public void SetResult(TestResult result) - { - Result = result; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTest.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTest.cs.meta deleted file mode 100644 index eb0b837..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTest.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 838e8d45ce997d8489185bc194dfcf25 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTestGroup.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTestGroup.cs deleted file mode 100644 index b3620d8..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTestGroup.cs +++ /dev/null @@ -1,18 +0,0 @@ -using AssetStoreTools.Validator.Data; -using System.Collections.Generic; - -namespace AssetStoreTools.Validator.UI.Data -{ - internal class ValidatorTestGroup : IValidatorTestGroup - { - public string Name => Status.ToString(); - public TestResultStatus Status { get; private set; } - public IEnumerable Tests { get; private set; } - - public ValidatorTestGroup(TestResultStatus status, IEnumerable tests) - { - Status = status; - Tests = tests; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTestGroup.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTestGroup.cs.meta deleted file mode 100644 index 46de398..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Data/ValidatorTestGroup.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 8f5d1fc9ff785904fb2e663e9232a7a5 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements.meta deleted file mode 100644 index 9a9f507..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 7ee7e5be29b8b184ba2abcd3ed38454e -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorButtonElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorButtonElement.cs deleted file mode 100644 index 93f8f89..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorButtonElement.cs +++ /dev/null @@ -1,50 +0,0 @@ -using AssetStoreTools.Validator.UI.Data; -using System; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Validator.UI.Elements -{ - internal class ValidatorButtonElement : VisualElement - { - // Data - private IValidatorSettings _settings; - - // UI - private Button _validateButton; - - public event Action OnValidate; - - public ValidatorButtonElement(IValidatorSettings settings) - { - _settings = settings; - _settings.OnValidationPathsChanged += ValidationPathsChanged; - - Create(); - Deserialize(); - } - - private void Create() - { - _validateButton = new Button(Validate) { text = "Validate" }; - _validateButton.AddToClassList("validator-validate-button"); - - Add(_validateButton); - } - - private void Validate() - { - OnValidate?.Invoke(); - } - - private void ValidationPathsChanged() - { - var validationPathsPresent = _settings.GetValidationPaths().Count > 0; - _validateButton.SetEnabled(validationPathsPresent); - } - - private void Deserialize() - { - ValidationPathsChanged(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorButtonElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorButtonElement.cs.meta deleted file mode 100644 index f136053..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorButtonElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 44fac105314df6341bf6a70fb3200baf -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorDescriptionElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorDescriptionElement.cs deleted file mode 100644 index 73d6e70..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorDescriptionElement.cs +++ /dev/null @@ -1,114 +0,0 @@ -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Validator.UI.Elements -{ - internal class ValidatorDescriptionElement : VisualElement - { - private const string DescriptionFoldoutText = "Validate your package to ensure your content follows the chosen submission guidelines."; - private const string DescriptionFoldoutContentText = "The validations below do not cover all of the content standards, and passing all validations does not " + - "guarantee that your package will be accepted to the Asset Store.\n\n" + - "The tests are not obligatory for submitting your assets, but they can help avoid instant rejection by the " + - "automated vetting system, or clarify reasons of rejection communicated by the vetting team.\n\n" + - "For more information about the validations, view the message by expanding the tests or contact our support team."; - - private VisualElement _descriptionSimpleContainer; - private Label _descriptionSimpleLabel; - private Button _showMoreButton; - - private VisualElement _descriptionFullContainer; - private Button _showLessButton; - - public ValidatorDescriptionElement() - { - AddToClassList("validator-description"); - Create(); - } - - private void Create() - { - CreateSimpleDescription(); - CreateFullDescription(); - } - - private void CreateSimpleDescription() - { - _descriptionSimpleContainer = new VisualElement(); - _descriptionSimpleContainer.AddToClassList("validator-description-simple-container"); - - _descriptionSimpleLabel = new Label(DescriptionFoldoutText); - _descriptionSimpleLabel.AddToClassList("validator-description-simple-label"); - - _showMoreButton = new Button(ToggleFullDescription) { text = "Show more..." }; - _showMoreButton.AddToClassList("validator-description-show-button"); - _showMoreButton.AddToClassList("validator-description-hyperlink-button"); - - _descriptionSimpleContainer.Add(_descriptionSimpleLabel); - _descriptionSimpleContainer.Add(_showMoreButton); - - Add(_descriptionSimpleContainer); - } - - private void CreateFullDescription() - { - _descriptionFullContainer = new VisualElement(); - _descriptionFullContainer.AddToClassList("validator-description-full-container"); - - var validatorDescription = new Label() - { - text = DescriptionFoldoutContentText - }; - validatorDescription.AddToClassList("validator-description-full-label"); - - var submissionGuidelinesButton = new Button(OpenSubmissionGuidelinesUrl) - { - text = "Submission Guidelines" - }; - submissionGuidelinesButton.AddToClassList("validator-description-hyperlink-button"); - - var supportTicketButton = new Button(OpenSupportTicketUrl) - { - text = "Contact our Support Team" - }; - supportTicketButton.AddToClassList("validator-description-hyperlink-button"); - - _showLessButton = new Button(ToggleFullDescription) { text = "Show less..." }; - _showLessButton.AddToClassList("validator-description-hide-button"); - _showLessButton.AddToClassList("validator-description-hyperlink-button"); - - _descriptionFullContainer.Add(validatorDescription); - _descriptionFullContainer.Add(submissionGuidelinesButton); - _descriptionFullContainer.Add(supportTicketButton); - _descriptionFullContainer.Add(_showLessButton); - - _descriptionFullContainer.style.display = DisplayStyle.None; - Add(_descriptionFullContainer); - } - - private void ToggleFullDescription() - { - var displayFullDescription = _descriptionFullContainer.style.display == DisplayStyle.None; - - if (displayFullDescription) - { - _showMoreButton.style.display = DisplayStyle.None; - _descriptionFullContainer.style.display = DisplayStyle.Flex; - } - else - { - _showMoreButton.style.display = DisplayStyle.Flex; - _descriptionFullContainer.style.display = DisplayStyle.None; - } - } - - private void OpenSubmissionGuidelinesUrl() - { - Application.OpenURL(Constants.Validator.SubmissionGuidelinesUrl); - } - - private void OpenSupportTicketUrl() - { - Application.OpenURL(Constants.Validator.SupportTicketUrl); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorDescriptionElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorDescriptionElement.cs.meta deleted file mode 100644 index 898b2ce..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorDescriptionElement.cs.meta +++ /dev/null @@ -1,3 +0,0 @@ -fileFormatVersion: 2 -guid: 9866d77420d947ba852055eed2bac895 -timeCreated: 1653383883 \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorPathsElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorPathsElement.cs deleted file mode 100644 index 6e4fe6d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorPathsElement.cs +++ /dev/null @@ -1,128 +0,0 @@ -using AssetStoreTools.Utility; -using AssetStoreTools.Validator.UI.Data; -using UnityEditor; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Validator.UI.Elements -{ - internal class ValidatorPathsElement : VisualElement - { - // Data - private IValidatorSettings _settings; - - // UI - private ScrollView _pathBoxScrollView; - - public ValidatorPathsElement(IValidatorSettings settings) - { - AddToClassList("validator-paths"); - - _settings = settings; - _settings.OnValidationPathsChanged += ValidationPathsChanged; - - Create(); - Deserialize(); - } - - private void Create() - { - var pathSelectionRow = new VisualElement(); - pathSelectionRow.AddToClassList("validator-settings-selection-row"); - - VisualElement labelHelpRow = new VisualElement(); - labelHelpRow.AddToClassList("validator-settings-selection-label-help-row"); - labelHelpRow.style.alignSelf = Align.FlexStart; - - Label pathLabel = new Label { text = "Validation paths" }; - Image pathLabelTooltip = new Image - { - tooltip = "Select the folder (or multiple folders) that your package consists of." + - "\n\nAll files and folders of your package should be contained within " + - "a single root folder that is named after your package " + - "(e.g. 'Assets/[MyPackageName]' or 'Packages/[MyPackageName]')" + - "\n\nIf your package includes special folders that cannot be nested within " + - "the root package folder (e.g. 'WebGLTemplates'), they should be added to this list " + - "together with the root package folder" - }; - - labelHelpRow.Add(pathLabel); - labelHelpRow.Add(pathLabelTooltip); - - var fullPathBox = new VisualElement() { name = "ValidationPaths" }; - fullPathBox.AddToClassList("validator-paths-box"); - - _pathBoxScrollView = new ScrollView { name = "ValidationPathsScrollView" }; - _pathBoxScrollView.AddToClassList("validator-paths-scroll-view"); - - VisualElement scrollViewBottomRow = new VisualElement(); - scrollViewBottomRow.AddToClassList("validator-paths-scroll-view-bottom-row"); - - var addExtraPathsButton = new Button(BrowsePath) { text = "Add a path" }; - addExtraPathsButton.AddToClassList("validator-paths-add-button"); - scrollViewBottomRow.Add(addExtraPathsButton); - - fullPathBox.Add(_pathBoxScrollView); - fullPathBox.Add(scrollViewBottomRow); - - pathSelectionRow.Add(labelHelpRow); - pathSelectionRow.Add(fullPathBox); - - Add(pathSelectionRow); - } - - private VisualElement CreateSinglePathElement(string path) - { - var validationPath = new VisualElement(); - validationPath.AddToClassList("validator-paths-path-row"); - - var folderPathLabel = new Label(path); - folderPathLabel.AddToClassList("validator-paths-path-row-input-field"); - - var removeButton = new Button(() => - { - _settings.RemoveValidationPath(path); - }); - removeButton.text = "X"; - removeButton.AddToClassList("validator-paths-path-row-remove-button"); - - validationPath.Add(folderPathLabel); - validationPath.Add(removeButton); - - return validationPath; - } - - private void BrowsePath() - { - string absolutePath = EditorUtility.OpenFolderPanel("Select a directory", "Assets", ""); - - if (string.IsNullOrEmpty(absolutePath)) - return; - - var relativePath = FileUtility.AbsolutePathToRelativePath(absolutePath, ASToolsPreferences.Instance.EnableSymlinkSupport); - - if (!_settings.IsValidationPathValid(relativePath, out var error)) - { - EditorUtility.DisplayDialog("Invalid path", error, "OK"); - return; - } - - _settings.AddValidationPath(relativePath); - } - - private void ValidationPathsChanged() - { - var validationPaths = _settings.GetValidationPaths(); - - _pathBoxScrollView.Clear(); - foreach (var path in validationPaths) - { - _pathBoxScrollView.Add(CreateSinglePathElement(path)); - } - } - - private void Deserialize() - { - ValidationPathsChanged(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorPathsElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorPathsElement.cs.meta deleted file mode 100644 index 93c9b6b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorPathsElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 370dcd3bc87ace647940b4b07147bf93 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorResultsElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorResultsElement.cs deleted file mode 100644 index f8e5113..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorResultsElement.cs +++ /dev/null @@ -1,47 +0,0 @@ -using AssetStoreTools.Validator.UI.Data; -using System.Linq; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Validator.UI.Elements -{ - internal class ValidatorResultsElement : ScrollView - { - private IValidatorResults _results; - - public ValidatorResultsElement(IValidatorResults results) - { - AddToClassList("validator-test-list"); - - _results = results; - _results.OnResultsChanged += ResultsChanged; - - Create(); - } - - private void Create() - { - var groups = _results.GetSortedTestGroups().ToList(); - for (int i = 0; i < groups.Count; i++) - { - var groupElement = new ValidatorTestGroupElement(groups[i]); - Add(groupElement); - if (i != groups.Count - 1) - Add(CreateSeparator()); - } - } - - private void ResultsChanged() - { - Clear(); - Create(); - } - - private VisualElement CreateSeparator() - { - var groupSeparator = new VisualElement { name = "GroupSeparator" }; - groupSeparator.AddToClassList("validator-test-list-group-separator"); - - return groupSeparator; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorResultsElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorResultsElement.cs.meta deleted file mode 100644 index d84970a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorResultsElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 12f80f9088944a149a34b3f078ca859a -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorSettingsElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorSettingsElement.cs deleted file mode 100644 index b3f69d7..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorSettingsElement.cs +++ /dev/null @@ -1,96 +0,0 @@ -using AssetStoreTools.Validator.UI.Data; -using UnityEditor.UIElements; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Validator.UI.Elements -{ - internal class ValidatorSettingsElement : VisualElement - { - // Data - private IValidatorSettings _settings; - - // UI - private ToolbarMenu _categoryMenu; - private ValidatorPathsElement _validationPathsElement; - - public ValidatorSettingsElement(IValidatorSettings settings) - { - AddToClassList("validator-settings"); - - _settings = settings; - _settings.OnCategoryChanged += CategoryChanged; - - Create(); - Deserialize(); - } - - public void Create() - { - CreateCategorySelection(); - CreateValidationPathSelection(); - } - - private void CreateCategorySelection() - { - var categorySelectionBox = new VisualElement(); - categorySelectionBox.AddToClassList("validator-settings-selection-row"); - - VisualElement labelHelpRow = new VisualElement(); - labelHelpRow.AddToClassList("validator-settings-selection-label-help-row"); - - Label categoryLabel = new Label { text = "Category" }; - Image categoryLabelTooltip = new Image - { - tooltip = "Choose a base category of your package" + - "\n\nThis can be found in the Publishing Portal when creating the package listing or just " + - "selecting a planned one." + - "\n\nNote: Different categories could have different severities of several test cases." - }; - - labelHelpRow.Add(categoryLabel); - labelHelpRow.Add(categoryLabelTooltip); - - _categoryMenu = new ToolbarMenu { name = "CategoryMenu" }; - _categoryMenu.AddToClassList("validator-settings-selection-dropdown"); - - categorySelectionBox.Add(labelHelpRow); - categorySelectionBox.Add(_categoryMenu); - - // Append available categories - var categories = _settings.GetAvailableCategories(); - foreach (var category in categories) - { - _categoryMenu.menu.AppendAction(category, _ => _settings.SetActiveCategory(category)); - } - - // Append misc category - _categoryMenu.menu.AppendAction("Other", _ => _settings.SetActiveCategory(string.Empty)); - - Add(categorySelectionBox); - } - - private void CreateValidationPathSelection() - { - _validationPathsElement = new ValidatorPathsElement(_settings); - Add(_validationPathsElement); - } - - private void CategoryChanged() - { - var category = _settings.GetActiveCategory(); - if (!string.IsNullOrEmpty(category)) - _categoryMenu.text = category; - else - _categoryMenu.text = "Other"; - } - - private void Deserialize() - { - if (_settings == null) - return; - - // Set initial category - CategoryChanged(); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorSettingsElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorSettingsElement.cs.meta deleted file mode 100644 index 0522b1b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorSettingsElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 760d25556d755d544bece3a605adea09 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestElement.cs deleted file mode 100644 index c477c72..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestElement.cs +++ /dev/null @@ -1,239 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.UI.Data; -using AssetStoreTools.Validator.Utility; -using System.Linq; -using UnityEditor.SceneManagement; -using UnityEditor.UIElements; -using UnityEngine; -using UnityEngine.Events; -using UnityEngine.SceneManagement; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Validator.UI.Elements -{ - internal class ValidatorTestElement : VisualElement - { - // Data - private IValidatorTest _test; - private bool _isExpanded; - - // UI - private Button _testFoldoutButton; - private Label _testFoldoutExpandStateLabel; - private Label _testFoldoutLabel; - private Image _testStatusImage; - - private VisualElement _testContent; - private VisualElement _resultMessagesBox; - - public ValidatorTestElement(IValidatorTest test) - { - AddToClassList("validator-test"); - - _test = test; - - Create(); - Unexpand(); - - SubscribeToSceneChanges(); - } - - private void Create() - { - CreateFoldoutButton(); - CreateTestContent(); - CreateTestDescription(); - CreateTestMessages(); - } - - private void CreateFoldoutButton() - { - _testFoldoutButton = new Button(ToggleExpand) { name = _test.Name }; - _testFoldoutButton.AddToClassList("validator-test-foldout"); - - // Expander and Asset Label - VisualElement labelExpanderRow = new VisualElement { name = "labelExpanderRow" }; - labelExpanderRow.AddToClassList("validator-test-expander"); - - _testFoldoutExpandStateLabel = new Label { name = "ExpanderLabel", text = "►" }; - _testFoldoutExpandStateLabel.AddToClassList("validator-test-expander-arrow"); - - _testFoldoutLabel = new Label { name = "TestLabel", text = _test.Name }; - _testFoldoutLabel.AddToClassList("validator-text-expander-label"); - - labelExpanderRow.Add(_testFoldoutExpandStateLabel); - labelExpanderRow.Add(_testFoldoutLabel); - - _testStatusImage = new Image - { - name = "TestImage", - image = ValidatorUtility.GetStatusTexture(_test.Result.Status) - }; - - _testStatusImage.AddToClassList("validator-test-expander-image"); - - _testFoldoutButton.Add(labelExpanderRow); - _testFoldoutButton.Add(_testStatusImage); - - Add(_testFoldoutButton); - } - - private void CreateTestContent() - { - _testContent = new VisualElement(); - _testContent.AddToClassList("validator-test-content"); - Add(_testContent); - } - - private void CreateTestDescription() - { - var testCaseDescription = new TextField - { - name = "Description", - value = _test.Description, - isReadOnly = true, - multiline = true, - focusable = false, - doubleClickSelectsWord = false, - tripleClickSelectsLine = false - }; - testCaseDescription.AddToClassList("validator-test-content-textfield"); - -#if UNITY_2022_1_OR_NEWER - testCaseDescription.focusable = true; - testCaseDescription.selectAllOnFocus = false; - testCaseDescription.selectAllOnMouseUp = false; -#endif - - _testContent.Add(testCaseDescription); - } - - private void CreateTestMessages() - { - if (_test.Result.MessageCount == 0) - return; - - _resultMessagesBox = new VisualElement(); - _resultMessagesBox.AddToClassList("validator-test-content-result-messages"); - - switch (_test.Result.Status) - { - case TestResultStatus.Pass: - _resultMessagesBox.AddToClassList("validator-test-content-result-messages-pass"); - break; - case TestResultStatus.Warning: - _resultMessagesBox.AddToClassList("validator-test-content-result-messages-warning"); - break; - case TestResultStatus.Fail: - _resultMessagesBox.AddToClassList("validator-test-content-result-messages-fail"); - break; - } - - for (int i = 0; i < _test.Result.MessageCount; i++) - { - _resultMessagesBox.Add(CreateMessage(_test.Result.GetMessage(i))); - - if (i == _test.Result.MessageCount - 1) - continue; - - var separator = new VisualElement() { name = "Separator" }; - separator.AddToClassList("message-separator"); - _resultMessagesBox.Add(separator); - } - - _testContent.Add(_resultMessagesBox); - } - - private VisualElement CreateMessage(TestResultMessage message) - { - var resultText = message.GetText(); - var clickAction = message.GetClickAction(); - - var resultMessage = new VisualElement { name = "ResultMessageElement" }; - resultMessage.AddToClassList("validator-test-content-result-messages-content"); - - var informationButton = new Button(); - informationButton.AddToClassList("validator-test-content-result-messages-content-button"); - - if (clickAction != null) - { - informationButton.tooltip = clickAction.Tooltip; - informationButton.clicked += clickAction.Execute; - informationButton.SetEnabled(true); - } - - var informationDescription = new Label { name = "InfoDesc", text = resultText }; - informationDescription.AddToClassList("validator-test-content-result-messages-content-label"); - - informationButton.Add(informationDescription); - resultMessage.Add(informationButton); - - for (int i = 0; i < message.MessageObjectCount; i++) - { - var obj = message.GetMessageObject(i); - if (obj == null) - continue; - - if (obj.GetObject() == null) - continue; - - var objectField = new ObjectField() { objectType = obj.GetType(), value = obj.GetObject() }; - objectField.RegisterCallback>((evt) => - objectField.SetValueWithoutNotify(evt.previousValue)); - resultMessage.Add(objectField); - } - - return resultMessage; - } - - private void ToggleExpand() - { - if (!_isExpanded) - Expand(); - else - Unexpand(); - } - - private void Expand() - { - _testFoldoutExpandStateLabel.text = "▼"; - _testFoldoutButton.AddToClassList("validator-test-foldout-expanded"); - _testContent.style.display = DisplayStyle.Flex; - _isExpanded = true; - } - - private void Unexpand() - { - _testFoldoutExpandStateLabel.text = "►"; - _testFoldoutButton.RemoveFromClassList("validator-test-foldout-expanded"); - _testContent.style.display = DisplayStyle.None; - _isExpanded = false; - } - - private void SubscribeToSceneChanges() - { - // Some result message objects only exist in specific scenes, - // therefore the UI must be refreshed on scene change - var windowToSubscribeTo = Resources.FindObjectsOfTypeAll().FirstOrDefault(); - UnityAction sceneChanged = null; - sceneChanged = new UnityAction((_, __) => RefreshObjects(windowToSubscribeTo)); - EditorSceneManager.activeSceneChangedInEditMode += sceneChanged; - - void RefreshObjects(ValidatorWindow subscribedWindow) - { - // Remove callback if validator window instance changed - var activeWindow = Resources.FindObjectsOfTypeAll().FirstOrDefault(); - if (subscribedWindow == null || subscribedWindow != activeWindow) - { - EditorSceneManager.activeSceneChangedInEditMode -= sceneChanged; - return; - } - - if (_resultMessagesBox != null) - _testContent.Remove(_resultMessagesBox); - - CreateTestMessages(); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestElement.cs.meta deleted file mode 100644 index 17794ff..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 56c93e6f23ba5724da8cc38f832be4e0 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestGroupElement.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestGroupElement.cs deleted file mode 100644 index 7906a0d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestGroupElement.cs +++ /dev/null @@ -1,102 +0,0 @@ -using AssetStoreTools.Validator.UI.Data; -using AssetStoreTools.Validator.Utility; -using System.Collections.Generic; -using System.Linq; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Validator.UI.Elements -{ - internal class ValidatorTestGroupElement : VisualElement - { - // Data - private IValidatorTestGroup _group; - private bool _isExpanded; - - // UI - private Button _groupFoldoutButton; - private Label _groupExpandStateLabel; - private Label _groupFoldoutLabel; - private Image _groupStatusImage; - - private VisualElement _groupContent; - private List _testElements; - - public ValidatorTestGroupElement(IValidatorTestGroup group) - { - AddToClassList("validator-test-list-group"); - - _group = group; - - Create(); - } - - private void Create() - { - CreateGroupFoldout(); - CreateGroupContent(); - } - - private void CreateGroupFoldout() - { - _groupFoldoutButton = new Button(ToggleExpand); - _groupFoldoutButton.AddToClassList("validator-test-list-group-expander"); - - _groupExpandStateLabel = new Label { name = "ExpanderLabel", text = "►" }; - _groupExpandStateLabel.AddToClassList("validator-test-list-group-expander-arrow"); - - _groupStatusImage = new Image - { - name = "TestImage", - image = ValidatorUtility.GetStatusTexture(_group.Status) - }; - _groupStatusImage.AddToClassList("validator-test-list-group-expander-image"); - - _groupFoldoutLabel = new Label() { text = $"{_group.Name} ({_group.Tests.Count()})" }; - _groupFoldoutLabel.AddToClassList("validator-test-list-group-expander-label"); - - _groupFoldoutButton.Add(_groupExpandStateLabel); - _groupFoldoutButton.Add(_groupStatusImage); - _groupFoldoutButton.Add(_groupFoldoutLabel); - - Add(_groupFoldoutButton); - } - - private void CreateGroupContent() - { - _groupContent = new VisualElement(); - _groupContent.AddToClassList("validator-test-list-group-content"); - - Add(_groupContent); - - _testElements = new List(); - foreach (var test in _group.Tests) - { - var testElement = new ValidatorTestElement(test); - _testElements.Add(testElement); - _groupContent.Add(testElement); - } - } - - private void ToggleExpand() - { - if (!_isExpanded) - Expand(); - else - Unexpand(); - } - - private void Expand() - { - _groupExpandStateLabel.text = "▼"; - _groupContent.style.display = DisplayStyle.Flex; - _isExpanded = true; - } - - private void Unexpand() - { - _groupExpandStateLabel.text = "►"; - _groupContent.style.display = DisplayStyle.None; - _isExpanded = false; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestGroupElement.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestGroupElement.cs.meta deleted file mode 100644 index eea4279..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Elements/ValidatorTestGroupElement.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: d7c7a8788d0ea324e843a475244d8e18 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/ValidatorWindow.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/ValidatorWindow.cs deleted file mode 100644 index cea8163..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/ValidatorWindow.cs +++ /dev/null @@ -1,56 +0,0 @@ -using AssetStoreTools.Utility; -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services; -using AssetStoreTools.Validator.UI.Views; -using UnityEditor.UIElements; -using UnityEngine; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Validator.UI -{ - - internal class ValidatorWindow : AssetStoreToolsWindow - { - protected override string WindowTitle => "Asset Store Validator"; - - private ICachingService _cachingService; - - private ValidatorTestsView _validationTestsView; - - protected override void Init() - { - minSize = new Vector2(350, 350); - - this.SetAntiAliasing(4); - - VisualElement root = rootVisualElement; - - // Clean it out, in case the window gets initialized again - root.Clear(); - - // Getting a reference to the USS Document and adding stylesheet to the root - root.styleSheets.Add(StyleSelector.ValidatorWindow.ValidatorWindowStyle); - root.styleSheets.Add(StyleSelector.ValidatorWindow.ValidatorWindowTheme); - - GetServices(); - ConstructWindow(); - } - - private void GetServices() - { - _cachingService = ValidatorServiceProvider.Instance.GetService(); - } - - private void ConstructWindow() - { - _validationTestsView = new ValidatorTestsView(_cachingService); - rootVisualElement.Add(_validationTestsView); - } - - public void Load(ValidationSettings settings, ValidationResult result) - { - _validationTestsView.LoadSettings(settings); - _validationTestsView.LoadResult(result); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/ValidatorWindow.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/ValidatorWindow.cs.meta deleted file mode 100644 index 378aa82..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/ValidatorWindow.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: a0dc99b826513dd4f868f1cf405c3923 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Views.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Views.meta deleted file mode 100644 index e90db60..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Views.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 8a973656ad14b8941b790ed83c874e97 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Views/ValidatorTestsView.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Views/ValidatorTestsView.cs deleted file mode 100644 index b25a8b4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Views/ValidatorTestsView.cs +++ /dev/null @@ -1,103 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services; -using AssetStoreTools.Validator.UI.Data; -using AssetStoreTools.Validator.UI.Data.Serialization; -using AssetStoreTools.Validator.UI.Elements; -using UnityEditor; -using UnityEngine.UIElements; - -namespace AssetStoreTools.Validator.UI.Views -{ - internal class ValidatorTestsView : VisualElement - { - // Data - private ValidatorStateData _stateData; - private IValidatorSettings _settings; - private IValidatorResults _results; - - private ICachingService _cachingService; - - // UI - private ValidatorSettingsElement _validatorSettingsElement; - private ValidatorButtonElement _validatorButtonElement; - private ValidatorResultsElement _validationTestListElement; - - public ValidatorTestsView(ICachingService cachingService) - { - _cachingService = cachingService; - - if (!_cachingService.GetCachedValidatorStateData(out _stateData)) - _stateData = new ValidatorStateData(); - - _settings = new ValidatorSettings(_stateData.GetSettings()); - _settings.OnRequireSerialize += Serialize; - - _results = new ValidatorResults(_settings, _stateData.GetResults()); - _results.OnRequireSerialize += Serialize; - - Create(); - } - - private void Create() - { - CreateValidatorDescription(); - CreateValidationSettings(); - CreateValidationButton(); - CreateValidatorResults(); - } - - private void CreateValidatorDescription() - { - var validationInfoElement = new ValidatorDescriptionElement(); - Add(validationInfoElement); - } - - private void CreateValidationSettings() - { - _validatorSettingsElement = new ValidatorSettingsElement(_settings); - Add(_validatorSettingsElement); - } - - private void CreateValidationButton() - { - _validatorButtonElement = new ValidatorButtonElement(_settings); - _validatorButtonElement.OnValidate += Validate; - Add(_validatorButtonElement); - } - - private void CreateValidatorResults() - { - _validationTestListElement = new ValidatorResultsElement(_results); - Add(_validationTestListElement); - } - - private void Validate() - { - var validator = _settings.CreateValidator(); - var result = validator.Validate(); - - if (result.Status == ValidationStatus.Failed) - { - EditorUtility.DisplayDialog("Validation failed", result.Exception.Message, "OK"); - return; - } - - LoadResult(result); - } - - public void LoadSettings(ValidationSettings settings) - { - _settings.LoadSettings(settings); - } - - public void LoadResult(ValidationResult result) - { - _results.LoadResult(result); - } - - private void Serialize() - { - _cachingService.CacheValidatorStateData(_stateData); - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Views/ValidatorTestsView.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Views/ValidatorTestsView.cs.meta deleted file mode 100644 index 90c2cdd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/UI/Views/ValidatorTestsView.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: c5e0da39c6638684c9d3faf8e62c60d3 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Utility.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Utility.meta deleted file mode 100644 index 148dca9..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Utility.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 3bc3a78a4b494e44b75268ad1444ab81 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Utility/ValidatorUtility.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Utility/ValidatorUtility.cs deleted file mode 100644 index 0d58db5..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Utility/ValidatorUtility.cs +++ /dev/null @@ -1,142 +0,0 @@ -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services; -using AssetStoreTools.Validator.TestDefinitions; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using UnityEditor; -using UnityEngine; -using static AssetStoreTools.Constants; -using ValidatorConstants = AssetStoreTools.Constants.Validator; - -namespace AssetStoreTools.Validator.Utility -{ - internal static class ValidatorUtility - { - public enum SortType - { - Id, - Alphabetical - } - - public static ValidationTestScriptableObject[] GetAutomatedTestCases() => GetAutomatedTestCases(SortType.Id); - - public static ValidationTestScriptableObject[] GetAutomatedTestCases(SortType sortType) - { - string[] guids = AssetDatabase.FindAssets("t:AutomatedTestScriptableObject", new[] { ValidatorConstants.Tests.TestDefinitionsPath }); - ValidationTestScriptableObject[] tests = new ValidationTestScriptableObject[guids.Length]; - for (int i = 0; i < tests.Length; i++) - { - string testPath = AssetDatabase.GUIDToAssetPath(guids[i]); - AutomatedTestScriptableObject test = AssetDatabase.LoadAssetAtPath(testPath); - - tests[i] = test; - } - - switch (sortType) - { - default: - case SortType.Id: - tests = tests.Where(x => x != null).OrderBy(x => x.Id).ToArray(); - break; - case SortType.Alphabetical: - tests = tests.Where(x => x != null).OrderBy(x => x.Title).ToArray(); - break; - } - - return tests; - } - - public static MonoScript GenerateTestScript(string testName, ValidationType validationType) - { - var derivedType = nameof(ITestScript); - var configType = string.Empty; - var scriptPath = string.Empty; - switch (validationType) - { - case ValidationType.Generic: - configType = nameof(GenericTestConfig); - scriptPath = ValidatorConstants.Tests.GenericTestMethodsPath; - break; - case ValidationType.UnityPackage: - configType = nameof(GenericTestConfig); - scriptPath = ValidatorConstants.Tests.UnityPackageTestMethodsPath; - break; - default: - throw new System.Exception("Undefined validation type"); - } - - var newScriptPath = $"{scriptPath}/{testName}"; - if (!newScriptPath.EndsWith(".cs")) - newScriptPath += ".cs"; - - var existingScript = AssetDatabase.LoadAssetAtPath(newScriptPath); - if (existingScript != null) - return existingScript; - - var scriptContent = - $"using AssetStoreTools.Validator.Data;\n" + - $"using AssetStoreTools.Validator.TestDefinitions;\n\n" + - $"namespace AssetStoreTools.Validator.TestMethods\n" + - $"{{\n" + - $" internal class {testName} : {derivedType}\n" + - $" {{\n" + - $" private {configType} _config;\n\n" + - $" // Constructor also accepts dependency injection of registered {nameof(IValidatorService)} types\n" + - $" public {testName}({configType} config)\n" + - $" {{\n" + - $" _config = config;\n" + - $" }}\n\n" + - $" public {nameof(TestResult)} {nameof(ITestScript.Run)}()\n" + - $" {{\n" + - $" var result = new {nameof(TestResult)}() {{ {nameof(TestResult.Status)} = {nameof(TestResultStatus)}.{nameof(TestResultStatus.Undefined)} }};\n" + - $" return result;\n" + - $" }}\n" + - $" }}\n" + - $"}}\n"; - - File.WriteAllText(newScriptPath, scriptContent); - AssetDatabase.Refresh(); - return AssetDatabase.LoadAssetAtPath(newScriptPath); - } - - public static string GetLongestProjectPath() - { - var longPaths = GetProjectPaths(new string[] { "Assets", "Packages" }); - return longPaths.Aggregate("", (max, cur) => max.Length > cur.Length ? max : cur); - } - - public static IEnumerable GetProjectPaths(string[] rootPaths) - { - var longPaths = new List(); - var guids = AssetDatabase.FindAssets("*", rootPaths); - - foreach (var guid in guids) - { - var path = AssetDatabase.GUIDToAssetPath(guid); - longPaths.Add(path); - } - - return longPaths; - } - - public static Texture GetStatusTexture(TestResultStatus status) - { - var iconTheme = ""; - if (!EditorGUIUtility.isProSkin) - iconTheme = "_d"; - - switch (status) - { - case TestResultStatus.Pass: - return (Texture)EditorGUIUtility.Load($"{WindowStyles.ValidatorIconsPath}/success{iconTheme}.png"); - case TestResultStatus.Warning: - return (Texture)EditorGUIUtility.Load($"{WindowStyles.ValidatorIconsPath}/warning{iconTheme}.png"); - case TestResultStatus.Fail: - return (Texture)EditorGUIUtility.Load($"{WindowStyles.ValidatorIconsPath}/error{iconTheme}.png"); - default: - return (Texture)EditorGUIUtility.Load($"{WindowStyles.ValidatorIconsPath}/undefined{iconTheme}.png"); - } - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Utility/ValidatorUtility.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Utility/ValidatorUtility.cs.meta deleted file mode 100644 index b89dc0e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/Utility/ValidatorUtility.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 24792af98b4d87746a4b945e2a45dc2d -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ValidatorBase.cs b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ValidatorBase.cs deleted file mode 100644 index e65f137..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ValidatorBase.cs +++ /dev/null @@ -1,108 +0,0 @@ -using AssetStoreTools.Validator.Categories; -using AssetStoreTools.Validator.Data; -using AssetStoreTools.Validator.Services; -using AssetStoreTools.Validator.TestDefinitions; -using AssetStoreTools.Validator.Utility; -using System; -using System.Collections.Generic; -using System.Linq; -using UnityEditor; -using UnityEngine; - -namespace AssetStoreTools.Validator -{ - internal abstract class ValidatorBase : IValidator - { - public ValidationSettings Settings { get; private set; } - - private CategoryEvaluator _categoryEvaluator; - private List _automatedTests; - - protected ICachingService CachingService; - - public ValidatorBase(ValidationSettings settings) - { - Settings = settings; - _categoryEvaluator = new CategoryEvaluator(settings?.Category); - - CachingService = ValidatorServiceProvider.Instance.GetService(); - - CreateAutomatedTestCases(); - } - - private void CreateAutomatedTestCases() - { - var testData = ValidatorUtility.GetAutomatedTestCases(ValidatorUtility.SortType.Alphabetical); - _automatedTests = new List(); - - foreach (var t in testData) - { - var test = new AutomatedTest(t); - _automatedTests.Add(test); - } - } - - protected abstract void ValidateSettings(); - protected abstract ValidationResult GenerateValidationResult(); - - public ValidationResult Validate() - { - try - { - ValidateSettings(); - } - catch (Exception e) - { - return new ValidationResult() { Status = ValidationStatus.Failed, Exception = e }; - } - - var result = GenerateValidationResult(); - return result; - } - - protected List GetApplicableTests(params ValidationType[] validationTypes) - { - return _automatedTests.Where(x => validationTypes.Any(y => y == x.ValidationType)).ToList(); - } - - protected ValidationResult RunTests(List tests, ITestConfig config) - { - var completedTests = new List(); - - for (int i = 0; i < tests.Count; i++) - { - var test = tests[i]; - - EditorUtility.DisplayProgressBar("Validating", $"Running validation: {i + 1} - {test.Title}", (float)i / _automatedTests.Count); - - test.Run(config); - - // Adjust result based on categories - var updatedStatus = _categoryEvaluator.Evaluate(test); - test.Result.Status = updatedStatus; - - // Add the result - completedTests.Add(test); - -#if AB_BUILDER - EditorUtility.UnloadUnusedAssetsImmediate(); -#endif - } - - EditorUtility.UnloadUnusedAssetsImmediate(); - EditorUtility.ClearProgressBar(); - - var projectPath = Application.dataPath.Substring(0, Application.dataPath.Length - "/Assets".Length); - var hasCompilationErrors = EditorUtility.scriptCompilationFailed; - var result = new ValidationResult() - { - Status = ValidationStatus.RanToCompletion, - Tests = completedTests, - ProjectPath = projectPath, - HadCompilationErrors = hasCompilationErrors - }; - - return result; - } - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ValidatorBase.cs.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ValidatorBase.cs.meta deleted file mode 100644 index c7fbc8e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ValidatorBase.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 2360246050affaa458413c6569c1f925 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles.meta deleted file mode 100644 index a5cbef6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 21f473cb130d5f0458b2823b3a67f789 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/Style.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/Style.uss deleted file mode 100644 index 4a79ecd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/Style.uss +++ /dev/null @@ -1,337 +0,0 @@ -/* Validator Description */ - -.validator-description { - flex-direction: column; - flex-shrink: 0; - - margin: 10px 5px 2px 5px; - padding: 2px 4px; -} - -.validator-description-simple-container { - flex-direction: column; - flex-wrap: wrap; -} - -.validator-description-simple-label { - white-space: normal; -} - -.validator-description-full-container { - margin-top: 12px; -} - -.validator-description-full-label { - white-space: normal; - margin-bottom: 10px; -} - -.validator-description-hyperlink-button { - margin: 0; - padding: 0; - - align-self: flex-start; - cursor: link; -} - -.validator-description-show-button { - margin-top: 12px; -} - -.validator-description-hide-button { - margin-top: 12px; -} - -/* Validator Settings */ - -.validator-settings { - flex-direction: column; - flex-shrink: 0; - - margin: 0px 5px 2px 5px; - padding: 2px 4px; -} - -.validator-settings-selection-row { - flex-direction: row; - flex-grow: 1; - - margin-top: 10px; - padding: 0 3px 0 2px; -} - -.validator-settings-selection-label-help-row { - flex-direction: row; - flex-shrink: 1; - flex-grow: 0; - - align-self: center; - align-items: center; - justify-content: flex-start; - - width: 120px; -} - -.validator-settings-selection-label-help-row > Label { - -unity-font-style: bold; -} - -.validator-settings-selection-label-help-row > Image { - height: 16px; - width: 16px; -} - -.validator-settings-selection-dropdown { - flex-grow: 1; - flex-shrink: 1; - - align-self: stretch; - - margin-right: 0; - margin-left: 3px; - padding: 1px 4px; -} - -/* Validate Button */ - -.validator-validate-button { - align-self: stretch; - - height: 25px; - margin-left: 2px; -} - -/* Validation Paths */ - -.validator-paths { - flex-direction: column; - flex-grow: 1; - flex-shrink: 0; - - margin-bottom: 10px; - padding: 0; -} - -.validator-paths-box { - flex-grow: 1; - flex-direction: column; -} - -.validator-paths-scroll-view { - flex-grow: 1; - height: 100px; - margin-left: 3px; -} - -.validator-paths-scroll-view > .unity-scroll-view__content-viewport -{ - margin-left: 1px; -} - -.validator-paths-scroll-view > * > .unity-scroll-view__content-container -{ - padding: 0 0 0 0; -} - -.validator-paths-scroll-view > * > .unity-scroll-view__vertical-scroller -{ - margin: -1px 0; -} - -.validator-paths-scroll-view-bottom-row { - flex-direction: row-reverse; - margin: -1px 0 0 3px; -} - -.validator-paths-add-button { - margin: 3px 0 0 0; - align-self: center; -} - -.validator-paths-path-row { - flex-direction: row; - flex-grow: 1; - - margin-top: 2px; - padding: 0 5px 0 2px; -} - -.validator-paths-path-row-input-field { - flex-grow: 1; - flex-shrink: 1; - - padding-left: 5px; - - white-space: normal; - -unity-text-align: middle-left; -} - -.validator-paths-path-row-remove-button { - width: 20px; - height: 20px; - margin-left: 2px; - margin-right: 1px; - padding: 1px 0 0 0; -} - -/* Tests List & Groups */ - -.validator-test-list { - flex-grow: 1; - flex-shrink: 1; -} - -.validator-test-list-group-separator { - height: 2px; - margin: 5px 15px; -} - -.validator-test-list-group { - overflow: hidden; -} - -.validator-test-list-group-expander { - flex-direction: row; - flex-grow: 0; - flex-shrink: 0; - - align-items: center; - - min-width: 200px; - min-height: 30px; - - margin: 10px -1px 2px -1px; -} - -.validator-test-list-group-expander-arrow { - align-self: center; - - width: 30px; - height: 30px; - - margin: 0; - padding: 0; -} - -.validator-test-list-group-expander-image { - flex-shrink: 0; - flex-grow: 0; - - width: 17px; - height: 17px; - - margin: 0 7px 0 2px; -} - -.validator-test-list-group-expander-label { - font-size: 14px; -} - -.validator-test-list-group-content { - margin: -2px -2px -2px -2px; -} - -/* Validation Test */ - -.validator-test { - flex-direction: column; - flex-shrink: 0; - flex-grow: 0; - - padding: 2px 0; -} - -.validator-test-foldout { - flex-direction: row; - flex-grow: 1; - flex-shrink: 1; - - align-items: center; - justify-content: space-between; - - min-width: 200px; - min-height: 35px; - - margin: 0; - padding: 5px 10px; -} - -.validator-test-expander { - flex-direction: row; - flex-grow: 1; -} - -.validator-test-expander-arrow { - font-size: 11px; - align-self: center; - - width: 30px; - height: 30px; - - margin: 0; - padding: 0; -} - -.validator-text-expander-label { - flex-grow: 1; - flex-shrink: 1; - - -unity-text-align: middle-left; - -unity-font-style: bold; - white-space: normal; -} - -.validator-test-expander-image { - flex-shrink: 0; - - width: 14px; - height: 14px; - - margin: 0 10px; -} - -.validator-test-content { - flex-grow: 1; - flex-shrink: 0; - - margin: 0; - padding: 5px 30px; -} - -.validator-test-content-textfield { - white-space: normal; -} - -.validator-test-content-result-messages { - flex-direction: column; - flex-shrink: 0; - flex-grow: 0; - - margin: 10px 0 5px 0; - padding: 0 3px 3px 3px; -} - -.validator-test-content-result-messages-content { - flex-basis: auto; - flex-direction: column; - - margin-top: 3px; -} - -.validator-test-content-result-messages-content-button { - align-self: stretch; - - -unity-font-style: normal; - -unity-text-align: middle-left; - - margin: 0; -} - -.validator-test-content-result-messages-content-label { - white-space: normal; -} - -.validator-test-content-result-messages-separator { - height: 3px; - margin: 5px -3px 0 -3px; -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/Style.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/Style.uss.meta deleted file mode 100644 index f933a2f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/Style.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 2c67a10c292c653428af654599fc15aa -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeDark.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeDark.uss deleted file mode 100644 index 47c13ea..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeDark.uss +++ /dev/null @@ -1,166 +0,0 @@ -.primary-colors -{ - /* Light - lighter */ - background-color: rgb(220, 220, 220); - /* Light - middle */ - background-color: rgb(200, 200, 200); - /* Light - darker */ - background-color: rgb(180, 180, 180); - - /* Dark - lighter */ - background-color: rgb(78, 78, 78); - /* Dark - middle */ - background-color: rgb(68, 68, 68); - /* Dark - darker */ - background-color: rgb(58, 58, 58); - - /* Border color - light */ - border-color: rgb(200, 200, 200); - /* Border color - dark */ - border-color: rgb(33, 33, 33); -} - -/* Validator Description */ - -.validator-description-hyperlink-button { - color: rgb(68, 113, 229); - border-width: 0; - background-color: rgba(0, 0, 0, 0); -} - -.validator-description-hyperlink-button:hover { - color: rgb(68, 133, 229); -} - -.validator-description-hyperlink-button:active { - color: rgb(68, 93, 229); -} - -/* Validator Settings */ - -.validator-settings-selection-label-help-row > Image { - --unity-image: resource("d__Help@2x"); -} - -.validator-settings-selection-dropdown { - color: rgb(238, 238, 238); - background-color: rgb(88, 88, 88); - - border-width: 1px; - border-radius: 3px; - border-color: rgb(36, 36, 36); -} - -/* Validation Paths */ - -.validator-paths-scroll-view { - border-width: 1px; - border-color: rgb(33, 33, 33); - background-color: rgb(58, 58, 58); -} - -.validator-paths-scroll-view > * > .unity-scroll-view__vertical-scroller { - border-right-width: 0; -} - -.validator-paths-path-row-input-field:hover { - background-color: rgb(78, 78, 78); -} - -/* Tests List & Groups */ - -.validator-test-list { - flex-grow: 1; - flex-shrink: 1; -} - -.validator-test-list-group-separator { - background-color: rgb(104, 104, 104); -} - -.validator-test-list-group-expander { - border-width: 0; - border-color: rgba(0, 0, 0, 0); - - background-color: rgba(0, 0, 0, 0); -} - -.validator-test-list-group-expander-arrow { - color: rgb(104, 104, 104); -} - -.validator-test-list-group-expander-label { - color: rgb(255, 255, 255); - -unity-font-style: bold; -} - -/* Validation Test */ - -.validator-test-foldout { - border-width: 0; - border-radius: 0; - background-color: rgb(56, 56, 56); -} - -.validator-test-foldout:hover { - background-color: rgb(68, 68, 68); -} - -.validator-test-foldout:active { - background-color: rgb(48, 48, 48); -} - -.validator-test-foldout-expanded { - background-color: rgb(68, 68, 68); -} - -.validator-test-expander-arrow { - color: rgb(104, 104, 104); -} - -.validator-test-content { - background-color: rgb(68, 68, 68); -} - -.validator-test-content-textfield > .unity-base-field__input { - border-width: 0; - border-color: rgba(0, 0, 0, 0); - background-color: rgba(0, 0, 0, 0); -} - -.validator-test-content-result-messages { - border-left-width: 2px; - border-color: rgb(33, 33, 33); - background-color: rgb(58, 58, 58); -} - -.validator-test-content-result-messages-pass { - border-color: rgb(40, 200, 40); -} - -.validator-test-content-result-messages-warning { - border-color: rgb(200, 140, 40); -} - -.validator-test-content-result-messages-fail { - border-color: rgb(200, 40, 40); -} - -.validator-test-content-result-messages-content-button { - border-width: 0; - border-radius: 0; - - background-color: rgba(0, 0, 0, 0); -} - -.validator-test-content-result-messages-content-button:hover { - background-color: rgb(78, 78, 78); -} - -.validator-test-content-result-messages-content-button:active { - background-color: rgba(0, 0, 0, 0); -} - -.validator-test-content-result-messages-separator { - background-color: rgb(68, 68, 68); -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeDark.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeDark.uss.meta deleted file mode 100644 index fc5c649..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeDark.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: d09164f0be2befd40aac764571737ff7 -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeLight.uss b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeLight.uss deleted file mode 100644 index 2c29c72..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeLight.uss +++ /dev/null @@ -1,166 +0,0 @@ -.primary-colors -{ - /* Light - lighter */ - background-color: rgb(220, 220, 220); - /* Light - middle */ - background-color: rgb(200, 200, 200); - /* Light - darker */ - background-color: rgb(180, 180, 180); - - /* Dark - lighter */ - background-color: rgb(50, 50, 50); - /* Dark - middle */ - background-color: rgb(28, 28, 28); - /* Dark - darker */ - background-color: rgb(0, 0, 0); - - /* Border color - light */ - border-color: rgb(200, 200, 200); - /* Border color - dark */ - border-color: rgb(33, 33, 33); -} - -/* Validator Description */ - -.validator-description-hyperlink-button { - color: rgb(68, 113, 229); - border-width: 0; - background-color: rgba(0, 0, 0, 0); -} - -.validator-description-hyperlink-button:hover { - color: rgb(68, 133, 229); -} - -.validator-description-hyperlink-button:active { - color: rgb(68, 93, 229); -} - -/* Validator Settings */ - -.validator-settings-selection-label-help-row > Image { - --unity-image: resource("_Help@2x"); -} - -.validator-settings-selection-dropdown { - color: rgb(9, 9, 9); - background-color: rgb(228, 228, 228); - - border-width: 1px; - border-radius: 3px; - border-color: rgb(178, 178, 178); -} - -/* Validation Paths */ - -.validator-paths-scroll-view { - border-width: 1px; - border-color: rgb(33, 33, 33); - background-color: rgb(180, 180, 180); -} - -.validator-paths-scroll-view > * > .unity-scroll-view__vertical-scroller { - border-right-width: 0; -} - -.validator-paths-path-row-input-field:hover { - background-color: rgb(200, 200, 200); -} - -/* Tests List & Groups */ - -.validator-test-list { - flex-grow: 1; - flex-shrink: 1; -} - -.validator-test-list-group-separator { - background-color: rgb(77, 77, 77); -} - -.validator-test-list-group-expander { - border-width: 0; - border-color: rgba(0, 0, 0, 0); - - background-color: rgba(0, 0, 0, 0); -} - -.validator-test-list-group-expander-arrow { - color: rgb(77, 77, 77); -} - -.validator-test-list-group-expander-label { - color: rgb(48, 48, 48); - -unity-font-style: bold; -} - -/* Validation Test */ - -.validator-test-foldout { - border-width: 0; - border-radius: 0; - background-color: rgb(198, 198, 198); -} - -.validator-test-foldout:hover { - background-color: rgb(212, 212, 212); -} - -.validator-test-foldout:active { - background-color: rgb(180, 180, 180); -} - -.validator-test-foldout-expanded { - background-color: rgb(212, 212, 212); -} - -.validator-test-expander-arrow { - color: rgb(77, 77, 77); -} - -.validator-test-content { - background-color: rgb(212, 212, 212); -} - -.validator-test-content-textfield > .unity-base-field__input { - border-width: 0; - border-color: rgba(0, 0, 0, 0); - background-color: rgba(0, 0, 0, 0); -} - -.validator-test-content-result-messages { - border-left-width: 2px; - border-color: rgb(33, 33, 33); - background-color: rgb(198, 198, 198); -} - -.validator-test-content-result-messages-pass { - border-color: rgb(40, 200, 40); -} - -.validator-test-content-result-messages-warning { - border-color: rgb(200, 140, 40); -} - -.validator-test-content-result-messages-fail { - border-color: rgb(200, 40, 40); -} - -.validator-test-content-result-messages-content-button { - border-width: 0; - border-radius: 0; - - background-color: rgba(0, 0, 0, 0); -} - -.validator-test-content-result-messages-content-button:hover { - background-color: rgb(212, 212, 212); -} - -.validator-test-content-result-messages-content-button:active { - background-color: rgba(0, 0, 0, 0); -} - -.validator-test-content-result-messages-separator { - background-color: rgb(212, 212, 212); -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeLight.uss.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeLight.uss.meta deleted file mode 100644 index c3b2570..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Styles/ThemeLight.uss.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 7404a65e6f9592846a20fd5190b12b1a -ScriptedImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 2 - userData: - assetBundleName: - assetBundleVariant: - script: {fileID: 12385, guid: 0000000000000000e000000000000000, type: 0} - disableValidation: 0 diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests.meta deleted file mode 100644 index 4515443..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 82d68ee644bbbb44183019f731e9f205 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic.meta deleted file mode 100644 index e10e15e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 38036e7f211469848b7cf706e3a1febf -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Animation Clips.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Animation Clips.asset deleted file mode 100644 index c9b418f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Animation Clips.asset +++ /dev/null @@ -1,27 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Animation Clips - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 31 - Title: Check Animation Clips - Description: Animation Clips should not have the default name 'Take 001'. This - could lead to confusion when filtering assets by animation clips. - CategoryInfo: - IsFailFilter: 0 - IsInclusiveFilter: 0 - AppliesToSubCategories: 1 - Filter: - - Animation - ValidationType: 0 - TestScript: {fileID: 11500000, guid: 7a28985886f182c4bacc89a44777c742, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Animation Clips.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Animation Clips.asset.meta deleted file mode 100644 index e647903..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Animation Clips.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: e0426dd01b5136a4ca1d42d312e12fad -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Audio Clipping.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Audio Clipping.asset deleted file mode 100644 index 356c3ae..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Audio Clipping.asset +++ /dev/null @@ -1,32 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Audio Clipping - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 27 - Title: Check Audio Clipping - Description: 'Audio files should not peak above the defined dB threshold of -0.3db - - - Please - note that lossless audio files that are imported into Unity with their Compression - Format set to anything other than PCM can still fail the Validator. If such cases - arise, please export your audio files with extra headroom, or set the Compression - Format to PCM if applicable.' - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: - - Audio - TestScript: {fileID: 11500000, guid: f604db0353da0cb46bb048f5cd37186f, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Audio Clipping.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Audio Clipping.asset.meta deleted file mode 100644 index f7b5dcf..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Audio Clipping.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 03c6cd398931b3e41b0784e8589e153f -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 0 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Colliders.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Colliders.asset deleted file mode 100644 index 079d75b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Colliders.asset +++ /dev/null @@ -1,26 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Colliders - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 4 - Title: Check Colliders - Description: Prefabs with meshes inside them have to have colliders applied to - them, if the Prefabs are marked as Static. Please make sure you have appropriately - sized colliders applied to your prefabs. - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: 308b3d7b7a883b949a14f47cfd5c7ebe, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Colliders.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Colliders.asset.meta deleted file mode 100644 index 9b1b8d4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Colliders.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 28ab5af444cf3c849800ed0d8f4a3102 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Compressed Files.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Compressed Files.asset deleted file mode 100644 index f8aa71f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Compressed Files.asset +++ /dev/null @@ -1,31 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Compressed Files - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 22 - Title: Check Compressed Files - Description: "Package should not contain nested .unitypackage or archive files - that obscure most of, or the entirety of the content.\n\n.unitypackage files - are acceptable for including setup preferences, settings, supplemental files - for other Asset Store products, or alternative render pipeline content\n\n.zip - files are acceptable if they are compressing files that do not natively function - in the Unity Editor. (For example, Blender, HTML Documentation, or Visual Studio - Projects). Such files should include 'source' in the file name (e.g. \"Blender_source.zip\" - or \"PSDSource.zip\")." - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: 84b23febe0d923842aef73b95da5f25b, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Compressed Files.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Compressed Files.asset.meta deleted file mode 100644 index dbf1164..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Compressed Files.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 53189e6e51235b14192c4d5b3145dd27 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Empty Prefabs.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Empty Prefabs.asset deleted file mode 100644 index 6154efa..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Empty Prefabs.asset +++ /dev/null @@ -1,31 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Empty Prefabs - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 5 - Title: Check Empty Prefabs - Description: Prefabs cannot be empty, please make sure that you set up your prefabs. - correctly. - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: - - 2D - - 3D - - Animation - - Essentials - - Templates - - VFX - TestScript: {fileID: 11500000, guid: 8055bed9373283e4793463b90b42f08f, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Empty Prefabs.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Empty Prefabs.asset.meta deleted file mode 100644 index d2f3da2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Empty Prefabs.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 08790ea0ed0fd274fb1df75ccc32d415 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check File Menu Names.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check File Menu Names.asset deleted file mode 100644 index ff0f7a4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check File Menu Names.asset +++ /dev/null @@ -1,26 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check File Menu Names - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 21 - Title: Check File Menu Names - Description: File menus should be placed under an existing menu, such as "Window/". - If no existing menus are a good fit, they should be placed under a custom menu - called "Tools". - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: d8e3b12ecc1fcd74d9a9f8d2b549fc63, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check File Menu Names.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check File Menu Names.asset.meta deleted file mode 100644 index a5a922a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check File Menu Names.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: eaf232919893db04b8e05e91f6815424 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check LODs.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check LODs.asset deleted file mode 100644 index 2b332d7..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check LODs.asset +++ /dev/null @@ -1,33 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check LODs - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 17 - Title: Check LODs - Description: 'Prefabs containing meshes with ''LOD'' in their name must meet the - following requirements: - - - LOD Mesh must be referenced by an LOD Group Component - - - - LOD Mesh GameObject must be a child of an LOD Group Component.' - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: - - 3D - - Essentials - - Templates - TestScript: {fileID: 11500000, guid: 43b2158602f87704fa7b91561cfc8678, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check LODs.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check LODs.asset.meta deleted file mode 100644 index deb5c41..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check LODs.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: ad52ffa05767e9d4bb4d92093ad68b03 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Line Endings.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Line Endings.asset deleted file mode 100644 index 08e9426..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Line Endings.asset +++ /dev/null @@ -1,26 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Line Endings - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 20 - Title: Check Line Endings - Description: Inconsistent line endings in scripts might lead to incorrect line - numbers in stacktraces and compiler errors. Many text editors can fix this using - Convert Line Endings menu commands. - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: 85885005d1c594f42826de3555e98365, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Line Endings.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Line Endings.asset.meta deleted file mode 100644 index 699185f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Line Endings.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 1e7b5480c1d8bda43ab4fa945939e243 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Mesh Prefabs.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Mesh Prefabs.asset deleted file mode 100644 index 3d8a99a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Mesh Prefabs.asset +++ /dev/null @@ -1,26 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Mesh Prefabs - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 2 - Title: Check Mesh Prefabs - Description: Each mesh should have a corresponding prefab set up with all variations - of the texture/mesh/material that you are providing. Please create prefabs for - all of your imported objects. - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: 3c3d0d642ac6a6a48aa124a93dae3734, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Mesh Prefabs.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Mesh Prefabs.asset.meta deleted file mode 100644 index cff122c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Mesh Prefabs.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 03b362b67028eb443b7ba8b84aedd5f2 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Assets.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Assets.asset deleted file mode 100644 index 0a69e35..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Assets.asset +++ /dev/null @@ -1,25 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Missing Components in Assets - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 9 - Title: Check Missing Components in Assets - Description: We do not allow missing or broken material/texture/prefab/script connections - in your package. Please make sure none of your assets have missing components. - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: 22d8f814e2363e34ea220736a4042728, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Assets.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Assets.asset.meta deleted file mode 100644 index 6ba4103..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Assets.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 1a3d0b3827fc16347867bee335e8f4ea -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Scenes.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Scenes.asset deleted file mode 100644 index f5ecb1a..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Scenes.asset +++ /dev/null @@ -1,25 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Missing Components in Scenes - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 10 - Title: Check Missing Components in Scenes - Description: We do not allow missing or broken material/texture/prefab/script connections - in your package. Please make sure none of your scene objects have missing components. - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: 511e76d0ebcb23d40a7b49dda0e2980f, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Scenes.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Scenes.asset.meta deleted file mode 100644 index 42d6127..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Missing Components in Scenes.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: bc2cb4e6635aa334ea4a52e2e3ce57c8 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Import Logs.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Import Logs.asset deleted file mode 100644 index f5d9b0f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Import Logs.asset +++ /dev/null @@ -1,26 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Model Import Logs - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 32 - Title: Check Model Import Logs - Description: Model assets should work without issues. Please make sure that there - are no errors or warnings when these models are imported. - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - ValidationType: 0 - TestScript: {fileID: 11500000, guid: 98f3ec209166855408eaf4abe5bff591, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Import Logs.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Import Logs.asset.meta deleted file mode 100644 index ba55c59..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Import Logs.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: c889cdd91c2f41941a14363dad7a1a38 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Orientation.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Orientation.asset deleted file mode 100644 index dfd8345..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Orientation.asset +++ /dev/null @@ -1,25 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Model Orientation - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 7 - Title: Check Model Orientation - Description: 'Meshes should be facing the correct way. The proper facing is: Z - vector is forward, Y vector is up, X vector is right.' - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: 56cdcdc41a80fbc46b5b2b83ec8d66d7, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Orientation.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Orientation.asset.meta deleted file mode 100644 index 4f49313..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Orientation.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 45b2b11da67e8864aacc62d928524b4c -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Types.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Types.asset deleted file mode 100644 index e9c9aac..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Types.asset +++ /dev/null @@ -1,24 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Model Types - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 23 - Title: Check Model Types - Description: Mesh assets must be either .fbx, .dae, .abc, or .obj file types. - CategoryInfo: - IsFailFilter: 0 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: 428b1fb838e6f5a469bbfd26ca3fbfd2, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Types.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Types.asset.meta deleted file mode 100644 index c4aef07..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Model Types.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: ffef800a102b0e04cae1a3b98549ef1b -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Normal Map Textures.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Normal Map Textures.asset deleted file mode 100644 index 2f65269..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Normal Map Textures.asset +++ /dev/null @@ -1,25 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Normal Map Textures - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 26 - Title: Check Normal Map Textures - Description: Textures that are assigned to Materials as Normal Maps should have - their import Texture Type set to 'Normal Map' - CategoryInfo: - IsFailFilter: 0 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: d55cea510248f814eb2194c2b53f88d2, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Normal Map Textures.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Normal Map Textures.asset.meta deleted file mode 100644 index 66ff0da..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Normal Map Textures.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 241ad0174fcadb64da867011d196acbb -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Package Naming.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Package Naming.asset deleted file mode 100644 index 5c34623..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Package Naming.asset +++ /dev/null @@ -1,30 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Package Naming - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 33 - Title: Check Package Naming - Description: Your package and its contents should be named appropriately and not - artificially force themselves up the hierarchy within commonly used project folders. - This can happen when a file or a folder name starts with a special character - (such as an underscore). - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 0 - AppliesToSubCategories: 1 - Filter: - - Essentials - - Templates - ValidationType: 0 - TestScript: {fileID: 11500000, guid: afe9e04825c7d904981a54404b222290, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Package Naming.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Package Naming.asset.meta deleted file mode 100644 index f5e0fea..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Package Naming.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 04098aa074d151b4a908dfa79dfddec3 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Particle Systems.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Particle Systems.asset deleted file mode 100644 index 62d55cd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Particle Systems.asset +++ /dev/null @@ -1,25 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Particle Systems - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 25 - Title: Check Particle Systems - Description: All Particle Systems should be saved as Prefabs - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: - - VFX - TestScript: {fileID: 11500000, guid: 6a623f7988c75884bb17b169ccd3e993, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Particle Systems.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Particle Systems.asset.meta deleted file mode 100644 index 5404fd4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Particle Systems.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 87da7eaed3cee0d4b8ada0b500e3a958 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Path Lengths.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Path Lengths.asset deleted file mode 100644 index 676ae48..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Path Lengths.asset +++ /dev/null @@ -1,25 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Path Lengths - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 28 - Title: Check Path Lengths - Description: Package content file paths should not be excessively lengthened. File - paths for assets must be under 140 characters - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: ae379305e9165e84584373a8272c09e7, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Path Lengths.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Path Lengths.asset.meta deleted file mode 100644 index 4ebd5ac..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Path Lengths.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 21f8ec0602ffac045b1f4a93f8a9b555 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Prefab Transforms.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Prefab Transforms.asset deleted file mode 100644 index 2cf336b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Prefab Transforms.asset +++ /dev/null @@ -1,28 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Prefab Transforms - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 3 - Title: Check Prefab Transforms - Description: Prefabs must have their position/rotation set to 0, and their scale - set to 1. - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: - - 3D - - Essentials - - Templates - TestScript: {fileID: 11500000, guid: f712c17a60bf2d049a4e61c8f79e56c2, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Prefab Transforms.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Prefab Transforms.asset.meta deleted file mode 100644 index 713d908..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Prefab Transforms.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 700026f446833f649a3c63b33a90a295 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Script Compilation.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Script Compilation.asset deleted file mode 100644 index fae309f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Script Compilation.asset +++ /dev/null @@ -1,25 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Script Compilation - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 29 - Title: Check Script Compilation - Description: Scripts in the package must compile successfully and not result in - compilation errors - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: 59db88f43969db8499299bce7f4fb967, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Script Compilation.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Script Compilation.asset.meta deleted file mode 100644 index 3a026fb..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Script Compilation.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 339e21c955642a04289482aa923e10b6 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Shader Compilation.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Shader Compilation.asset deleted file mode 100644 index dcbd609..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Shader Compilation.asset +++ /dev/null @@ -1,25 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Shader Compilation - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 18 - Title: Check Shader Compilation - Description: Please make sure the shaders inside your package do not have errors - and compile successfully. - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: 7abb278a6082bde4391e0779394cb85b, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Shader Compilation.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Shader Compilation.asset.meta deleted file mode 100644 index c9ebccf..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Shader Compilation.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 1450037453608204a989ff95dca62fae -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Texture Dimensions.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Texture Dimensions.asset deleted file mode 100644 index d676f14..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Texture Dimensions.asset +++ /dev/null @@ -1,25 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Texture Dimensions - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 24 - Title: Check Texture Dimensions - Description: Dimensions of textures, where appropriate, should have pixel counts - that are a power of 2 - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: 073f1dacf3da34d4783140ae9d485d5f, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Texture Dimensions.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Texture Dimensions.asset.meta deleted file mode 100644 index d0318d4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Texture Dimensions.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: c23253393b8e28846b8e02aeaee7e152 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Type Namespaces.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Type Namespaces.asset deleted file mode 100644 index 8331d60..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Type Namespaces.asset +++ /dev/null @@ -1,31 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Type Namespaces - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 19 - Title: Check Type Namespaces - Description: 'Types in your scripts (classes, interfaces, structs, enums) should - be nested under a namespace block to prevent them from being mistaken for other - potential types and for better organization as a whole. - - - It is not allowed - to nest your code under a Unity namespace.' - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - ValidationType: 0 - TestScript: {fileID: 11500000, guid: 279249fa7ef8c2446b3a9f013eeedbf0, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Type Namespaces.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Type Namespaces.asset.meta deleted file mode 100644 index 2aa250d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Check Type Namespaces.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: dd110ee16e8de4d48a602349ed7a0b25 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Executable Files.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Executable Files.asset deleted file mode 100644 index 1a00c2f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Executable Files.asset +++ /dev/null @@ -1,27 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Remove Executable Files - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 14 - Title: Remove Executable Files - Description: Your package must not contain an .exe, installer programs or applications. - If your plugin requires an external program to run, please remove the installer - program from your package and write the instructions on how to download and install - the installer program in your documentation. - CategoryInfo: - IsFailFilter: 0 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: 8e4450592cc60e54286ad089b66db94d, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Executable Files.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Executable Files.asset.meta deleted file mode 100644 index b27033d..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Executable Files.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: e996c53186de96e49a742d414648a809 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JPG Files.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JPG Files.asset deleted file mode 100644 index cd2900f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JPG Files.asset +++ /dev/null @@ -1,30 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Remove JPG Files - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 8 - Title: Remove JPG Files - Description: We do not allow texture images that are saved in lossy formats. Please - save all of your images as lossless format file types, such as PNG, TGA, or PSD. - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: - - 2D - - 3D - - Animation - - Essentials - - VFX/Shaders - TestScript: {fileID: 11500000, guid: 5634a12b3a8544c4585bbc280ae59ce2, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JPG Files.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JPG Files.asset.meta deleted file mode 100644 index 45000c9..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JPG Files.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 781021ae3aa6570468e08d78e3195127 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JavaScript Files.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JavaScript Files.asset deleted file mode 100644 index bc5102e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JavaScript Files.asset +++ /dev/null @@ -1,25 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Remove JavaScript Files - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 11 - Title: Remove JavaScript Files - Description: JavaScript / UnityScript files are not allowed, as they are no longer - supported. - CategoryInfo: - IsFailFilter: 0 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: ab1676bde9afba442b35fd3319c18063, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JavaScript Files.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JavaScript Files.asset.meta deleted file mode 100644 index d41b9e6..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove JavaScript Files.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: bf01c18b66907f54c99517f6a877e3e0 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Lossy Audio Files.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Lossy Audio Files.asset deleted file mode 100644 index 954f6fd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Lossy Audio Files.asset +++ /dev/null @@ -1,32 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Remove Lossy Audio Files - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 12 - Title: Remove Lossy Audio Files - Description: 'We do not recommend audio files that are saved as .mp3 or .ogg. Please - save all of your audio as lossless format file types, such as .wav. If you have - non-lossy alternative files to your lossy audio files, please make sure to name - them identically to avoid rejection. For example: ''shout.mp3'', ''shout.wav''. - Listing of the format in the file name is also allowed and accounted for by the - validator. For example: ''taunt MP3.mp3'', ''taunt WAV.wav''.' - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: - - Audio - - Essentials - - Templates - TestScript: {fileID: 11500000, guid: b7205a85061273a4eb50586f13f35d35, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Lossy Audio Files.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Lossy Audio Files.asset.meta deleted file mode 100644 index 2026425..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Lossy Audio Files.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: a48657926de5cfb47ac559a7108d03ee -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Mixamo Files.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Mixamo Files.asset deleted file mode 100644 index 8d3cc14..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Mixamo Files.asset +++ /dev/null @@ -1,26 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Remove Mixamo Files - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 15 - Title: Remove Mixamo Files - Description: We do not allow or accept packages files that were made with third-party - software, such as Mixamo, Fuse, etc. because these files are under licensing - that does not agree with the Asset Store End User License Agreement (EULA). - CategoryInfo: - IsFailFilter: 0 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: 9df432e52aa958b44bb5e20c13d16552, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Mixamo Files.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Mixamo Files.asset.meta deleted file mode 100644 index 84abdb1..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Mixamo Files.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: a0a44055f786ec64f86a07a214d5f831 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove SpeedTree Files.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove SpeedTree Files.asset deleted file mode 100644 index 14ff13f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove SpeedTree Files.asset +++ /dev/null @@ -1,25 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Remove SpeedTree Files - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 16 - Title: Remove SpeedTree Files - Description: You cannot redistribute SpeedTree files on other marketplaces. Please - remove all SpeedTree files that are in this package. - CategoryInfo: - IsFailFilter: 0 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: e06bb7e0aa4f9944abc18281c002dff4, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove SpeedTree Files.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove SpeedTree Files.asset.meta deleted file mode 100644 index ffc10af..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove SpeedTree Files.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 305bbe67f7c644d18bc8a5b2273aa6a4 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Video Files.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Video Files.asset deleted file mode 100644 index 1df19b9..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Video Files.asset +++ /dev/null @@ -1,26 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Remove Video Files - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 13 - Title: Remove Video Files - Description: You cannot include a video file in your package. Please upload your - video file to an online video hosting website (Youtube, Vimeo, etc.) and include - the link to the video in your written documentation. - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - TestScript: {fileID: 11500000, guid: f99724c71b0de66419b5d6e8e9bfcc2d, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Video Files.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Video Files.asset.meta deleted file mode 100644 index e62946c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/Generic/Remove Video Files.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 893a0df188c2026438be48eed39b301f -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage.meta deleted file mode 100644 index 0a50cef..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 8e978e836f2fb224fa11de94e913da49 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Demo Scenes.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Demo Scenes.asset deleted file mode 100644 index af6ecc2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Demo Scenes.asset +++ /dev/null @@ -1,34 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Demo Scenes - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 1 - Title: Check Demo Scenes - Description: If your product has content to show off, it should be displayed in - a demo scene. Please provide a practical demo with all of your assets set up. - If your asset is based on scripting or Editor extensions, please consider adding - a demo scene showcasing the asset or showing setup steps in the scene. - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: - - 3D - - 2D - - Animation - - Essentials - - Templates - - VFX - ValidationType: 1 - TestScript: {fileID: 11500000, guid: f844c2dfa4669ff4eacf5591b544edaf, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Demo Scenes.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Demo Scenes.asset.meta deleted file mode 100644 index d58914f..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Demo Scenes.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: f108107be07f69045813d69eff580078 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Documentation.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Documentation.asset deleted file mode 100644 index 6ce011e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Documentation.asset +++ /dev/null @@ -1,32 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Documentation - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 6 - Title: Check Documentation - Description: If your asset contains any code (scripts, shaders) - we ask that you - include offline documentation in the format of pdf or rtf with your submission, - as it is mandatory for all packages that include scripts or other components - that require set up. Your documentation must be organized with a table of contents - and numbered, written in English and have no grammar mistakes. Create a setup - guide with a step-by-step tutorial (pdf or video), as well as a script reference - if users will need to do any coding. If your asset contains art (3D models, sprites) - and you used code to set up a demo scene, you may skip this step. - CategoryInfo: - IsFailFilter: 1 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: [] - ValidationType: 1 - TestScript: {fileID: 11500000, guid: 3c8425198983eda4c9b35aa0d59ea33c, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Documentation.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Documentation.asset.meta deleted file mode 100644 index 4ee6335..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Documentation.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: b03433f7977b29e4ca7e8d76393a6c26 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Package Size.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Package Size.asset deleted file mode 100644 index e80b2c4..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Package Size.asset +++ /dev/null @@ -1,25 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Package Size - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 30 - Title: Check Package Size - Description: Package submissions should not be more than 6 GB in size - CategoryInfo: - IsFailFilter: 0 - IsInclusiveFilter: 0 - AppliesToSubCategories: 1 - Filter: [] - ValidationType: 1 - TestScript: {fileID: 11500000, guid: a8601b99f4afa5049954f3a2dd5996d6, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Package Size.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Package Size.asset.meta deleted file mode 100644 index 63433dd..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Package Size.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 25721b2d7384e5b4f936cf3b33b80a02 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Project Template Assets.asset b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Project Template Assets.asset deleted file mode 100644 index 645117c..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Project Template Assets.asset +++ /dev/null @@ -1,36 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!114 &11400000 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 0} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: d813ff809ae82f643bf975031305d541, type: 3} - m_Name: Check Project Template Assets - m_EditorClassIdentifier: - HasBeenInitialized: 1 - Id: 34 - Title: Check Project Template Assets - Description: 'Assets in your package derived from project template assets should - be assigned a new GUID and be located under a different path. - - - This is to - minimize the risk of users accidentally overwriting their own assets when importing - your package. - - - Example commonly used asset: ''Assets/Scenes/SampleScene.unity''' - CategoryInfo: - IsFailFilter: 0 - IsInclusiveFilter: 1 - AppliesToSubCategories: 1 - Filter: - - Essentials - - Templates - ValidationType: 1 - TestScript: {fileID: 11500000, guid: f02d52a702c712e4e8089f7c2e65bae7, type: 3} diff --git a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Project Template Assets.asset.meta b/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Project Template Assets.asset.meta deleted file mode 100644 index a00554e..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/Editor/Validator/Tests/UnityPackage/Check Project Template Assets.asset.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 5392e9de0549574419ff76897d1e0fa1 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 11400000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/LICENSE.md b/Installer/Packages/com.unity.asset-store-tools/LICENSE.md deleted file mode 100644 index b20d72b..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/LICENSE.md +++ /dev/null @@ -1,5 +0,0 @@ -Asset Store Tools v2 copyright © 2025 Unity Technologies - -Source code of the package is licensed under the Unity Companion License (see https://unity.com/legal/licenses/unity-companion-license); otherwise licensed under the Unity Package Distribution License (see https://unity.com/legal/licenses/unity-package-distribution-license ) - -Unless expressly provided otherwise, the software under this license is made available strictly on an “AS IS” BASIS WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED. Please review the license for details on these and other terms and conditions. \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/LICENSE.md.meta b/Installer/Packages/com.unity.asset-store-tools/LICENSE.md.meta deleted file mode 100644 index b5792bf..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/LICENSE.md.meta +++ /dev/null @@ -1,7 +0,0 @@ -fileFormatVersion: 2 -guid: baeaa62ad0dc664428d6069db8fd986d -TextScriptImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/com.unity.asset-store-tools/package.json b/Installer/Packages/com.unity.asset-store-tools/package.json deleted file mode 100644 index 8a64e18..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/package.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "name": "com.unity.asset-store-tools", - "displayName": "Asset Store Tools", - "version": "12.0.1", - "unity": "2019.4", - "description": "Whether you're a programmer, game designer, texture artist or 3D modeler, you're welcome to share your creations with everybody in the Unity developer community!", - "type": "tool", - "dependencies": { - "com.unity.nuget.newtonsoft-json": "3.2.1" - } -} \ No newline at end of file diff --git a/Installer/Packages/com.unity.asset-store-tools/package.json.meta b/Installer/Packages/com.unity.asset-store-tools/package.json.meta deleted file mode 100644 index e319cf2..0000000 --- a/Installer/Packages/com.unity.asset-store-tools/package.json.meta +++ /dev/null @@ -1,7 +0,0 @@ -fileFormatVersion: 2 -guid: fca7c22c787fbfd4cb0d7f186668631a -PackageManifestImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Installer/Packages/manifest.json b/Installer/Packages/manifest.json index 94941c0..10cc9fe 100644 --- a/Installer/Packages/manifest.json +++ b/Installer/Packages/manifest.json @@ -1,5 +1,6 @@ { "dependencies": { + "com.unity.asset-store-tools": "https://github.com/Unity-Technologies/com.unity.asset-store-tools.git?path=/com.unity.asset-store-tools", "com.unity.test-framework": "1.1.33" }, "scopedRegistries": [ @@ -16,4 +17,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/Installer/Packages/packages-lock.json b/Installer/Packages/packages-lock.json index 09f78c7..c8911be 100644 --- a/Installer/Packages/packages-lock.json +++ b/Installer/Packages/packages-lock.json @@ -1,12 +1,13 @@ { "dependencies": { "com.unity.asset-store-tools": { - "version": "file:com.unity.asset-store-tools", + "version": "https://github.com/Unity-Technologies/com.unity.asset-store-tools.git?path=/com.unity.asset-store-tools", "depth": 0, - "source": "embedded", + "source": "git", "dependencies": { "com.unity.nuget.newtonsoft-json": "3.2.1" - } + }, + "hash": "944773fcec4d9e1551bc8058523e5ccb649ab87e" }, "com.unity.ext.nunit": { "version": "1.0.6", diff --git a/Installer/ProjectSettings/MemorySettings.asset b/Installer/ProjectSettings/MemorySettings.asset new file mode 100644 index 0000000..5b5face --- /dev/null +++ b/Installer/ProjectSettings/MemorySettings.asset @@ -0,0 +1,35 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!387306366 &1 +MemorySettings: + m_ObjectHideFlags: 0 + m_EditorMemorySettings: + m_MainAllocatorBlockSize: -1 + m_ThreadAllocatorBlockSize: -1 + m_MainGfxBlockSize: -1 + m_ThreadGfxBlockSize: -1 + m_CacheBlockSize: -1 + m_TypetreeBlockSize: -1 + m_ProfilerBlockSize: -1 + m_ProfilerEditorBlockSize: -1 + m_BucketAllocatorGranularity: -1 + m_BucketAllocatorBucketsCount: -1 + m_BucketAllocatorBlockSize: -1 + m_BucketAllocatorBlockCount: -1 + m_ProfilerBucketAllocatorGranularity: -1 + m_ProfilerBucketAllocatorBucketsCount: -1 + m_ProfilerBucketAllocatorBlockSize: -1 + m_ProfilerBucketAllocatorBlockCount: -1 + m_TempAllocatorSizeMain: -1 + m_JobTempAllocatorBlockSize: -1 + m_BackgroundJobTempAllocatorBlockSize: -1 + m_JobTempAllocatorReducedBlockSize: -1 + m_TempAllocatorSizeGIBakingWorker: -1 + m_TempAllocatorSizeNavMeshWorker: -1 + m_TempAllocatorSizeAudioWorker: -1 + m_TempAllocatorSizeCloudWorker: -1 + m_TempAllocatorSizeGfx: -1 + m_TempAllocatorSizeJobWorker: -1 + m_TempAllocatorSizeBackgroundWorker: -1 + m_TempAllocatorSizePreloadManager: -1 + m_PlatformMemorySettings: {} diff --git a/Installer/ProjectSettings/PackageManagerSettings.asset b/Installer/ProjectSettings/PackageManagerSettings.asset index 18dfb52..956245b 100644 --- a/Installer/ProjectSettings/PackageManagerSettings.asset +++ b/Installer/ProjectSettings/PackageManagerSettings.asset @@ -12,7 +12,11 @@ MonoBehaviour: m_Script: {fileID: 13964, guid: 0000000000000000e000000000000000, type: 0} m_Name: m_EditorClassIdentifier: + m_EnablePreReleasePackages: 0 + m_EnablePackageDependencies: 0 + m_AdvancedSettingsExpanded: 1 m_ScopedRegistriesSettingsExpanded: 1 + m_SeeAllPackageVersions: 0 oneTimeWarningShown: 0 m_Registries: - m_Id: main @@ -20,7 +24,9 @@ MonoBehaviour: m_Url: https://packages.unity.com m_Scopes: [] m_IsDefault: 1 - - m_Id: scoped:package.openupm.com + m_Capabilities: 7 + m_ConfigSource: 0 + - m_Id: scoped:project:package.openupm.com m_Name: package.openupm.com m_Url: https://package.openupm.com m_Scopes: @@ -31,30 +37,13 @@ MonoBehaviour: - org.nuget.system - org.nuget.r3 m_IsDefault: 0 - m_UserSelectedRegistryName: + m_Capabilities: 0 + m_ConfigSource: 4 + m_UserSelectedRegistryName: package.openupm.com m_UserAddingNewScopedRegistry: 0 m_RegistryInfoDraft: - m_ErrorMessage: - m_Original: - m_Id: scoped:package.openupm.com - m_Name: package.openupm.com - m_Url: https://package.openupm.com - m_Scopes: - - com.ivanmurzak - - extensions.unity - - org.nuget.com.ivanmurzak - - org.nuget.microsoft - - org.nuget.system - - org.nuget.r3 - m_IsDefault: 0 m_Modified: 0 - m_Name: package.openupm.com - m_Url: https://package.openupm.com - m_Scopes: - - com.ivanmurzak - - extensions.unity - - org.nuget.com.ivanmurzak - - org.nuget.microsoft - - org.nuget.system - - org.nuget.r3 - m_SelectedScopeIndex: 0 + m_ErrorMessage: + m_UserModificationsInstanceId: -826 + m_OriginalInstanceId: -830 + m_LoadAssets: 0 diff --git a/Installer/ProjectSettings/ProjectVersion.txt b/Installer/ProjectSettings/ProjectVersion.txt index 4c19129..8386a05 100644 --- a/Installer/ProjectSettings/ProjectVersion.txt +++ b/Installer/ProjectSettings/ProjectVersion.txt @@ -1,2 +1,2 @@ -m_EditorVersion: 2019.4.40f1 -m_EditorVersionWithRevision: 2019.4.40f1 (ffc62b691db5) +m_EditorVersion: 2021.3.45f1 +m_EditorVersionWithRevision: 2021.3.45f1 (0da89fac8e79) diff --git a/Installer/ProjectSettings/VersionControlSettings.asset b/Installer/ProjectSettings/VersionControlSettings.asset new file mode 100644 index 0000000..dca2881 --- /dev/null +++ b/Installer/ProjectSettings/VersionControlSettings.asset @@ -0,0 +1,8 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!890905787 &1 +VersionControlSettings: + m_ObjectHideFlags: 0 + m_Mode: Visible Meta Files + m_CollabEditorSettings: + inProgressEnabled: 1 diff --git a/Installer/ProjectSettings/boot.config b/Installer/ProjectSettings/boot.config new file mode 100644 index 0000000..e69de29 diff --git a/Installer/UserSettings/EditorUserSettings.asset b/Installer/UserSettings/EditorUserSettings.asset new file mode 100644 index 0000000..4681d1d --- /dev/null +++ b/Installer/UserSettings/EditorUserSettings.asset @@ -0,0 +1,19 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!162 &1 +EditorUserSettings: + m_ObjectHideFlags: 0 + serializedVersion: 4 + m_ConfigSettings: + vcSharedLogLevel: + value: 0d5e400f0650 + flags: 0 + m_VCAutomaticAdd: 1 + m_VCDebugCom: 0 + m_VCDebugCmd: 0 + m_VCDebugOut: 0 + m_SemanticMergeMode: 2 + m_VCShowFailedCheckout: 1 + m_VCOverwriteFailedCheckoutAssets: 1 + m_VCOverlayIcons: 1 + m_VCAllowAsyncUpdate: 0 diff --git a/Installer/UserSettings/Search.settings b/Installer/UserSettings/Search.settings new file mode 100644 index 0000000..9e26dfe --- /dev/null +++ b/Installer/UserSettings/Search.settings @@ -0,0 +1 @@ +{} \ No newline at end of file From 1d79a05767917a9388a3d346662cf5597e9a52d4 Mon Sep 17 00:00:00 2001 From: Ivan Murzak Date: Sat, 4 Jul 2026 14:49:18 -0700 Subject: [PATCH 4/6] Add IWebRequestProvider abstraction for dependency injection Introduces IWebRequestProvider interface to enable dependency injection of web requests, allowing for mock implementations during testing. Updates FutureSprite and FutureTexture to use the new provider pattern. Adds MockWebRequest and MockWebRequestProvider for comprehensive testing without network calls. Includes test utilities for mock response configuration and adds CLAUDE.md documentation. Also updates to Unity 2022.3 and adds MCP integration dependencies. --- Unity-Package/Assets/Resources.meta | 8 + .../Resources/Unity-MCP-ConnectionConfig.json | 7 + .../Unity-MCP-ConnectionConfig.json.meta | 7 + .../root/Runtime/Future/Types/FutureSprite.cs | 2 +- .../Runtime/Future/Types/FutureTexture.cs | 2 +- .../root/Runtime/ImageLoader.Settings.cs | 6 + .../Utils/DefaultWebRequestProvider.cs | 21 + .../Utils/DefaultWebRequestProvider.cs.meta | 11 + .../root/Runtime/Utils/IWebRequestProvider.cs | 25 + .../Runtime/Utils/IWebRequestProvider.cs.meta | 11 + .../root/Tests/Base/Utils/MockWebRequest.cs | 202 +++++ .../Tests/Base/Utils/MockWebRequest.cs.meta | 11 + .../Base/Utils/MockWebRequestProvider.cs | 101 +++ .../Base/Utils/MockWebRequestProvider.cs.meta | 11 + .../Assets/root/Tests/Base/Utils/TestUtils.cs | 51 +- Unity-Package/CLAUDE.md | 112 +++ Unity-Package/Packages/manifest.json | 70 +- Unity-Package/Packages/packages-lock.json | 731 ++++++++++++++++++ .../PackageManagerSettings.asset | 91 ++- .../ProjectSettings/ProjectVersion.txt | 4 +- .../SceneTemplateSettings.json | 121 +++ 21 files changed, 1579 insertions(+), 26 deletions(-) create mode 100644 Unity-Package/Assets/Resources.meta create mode 100644 Unity-Package/Assets/Resources/Unity-MCP-ConnectionConfig.json create mode 100644 Unity-Package/Assets/Resources/Unity-MCP-ConnectionConfig.json.meta create mode 100644 Unity-Package/Assets/root/Runtime/Utils/DefaultWebRequestProvider.cs create mode 100644 Unity-Package/Assets/root/Runtime/Utils/DefaultWebRequestProvider.cs.meta create mode 100644 Unity-Package/Assets/root/Runtime/Utils/IWebRequestProvider.cs create mode 100644 Unity-Package/Assets/root/Runtime/Utils/IWebRequestProvider.cs.meta create mode 100644 Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequest.cs create mode 100644 Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequest.cs.meta create mode 100644 Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequestProvider.cs create mode 100644 Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequestProvider.cs.meta create mode 100644 Unity-Package/CLAUDE.md create mode 100644 Unity-Package/ProjectSettings/SceneTemplateSettings.json diff --git a/Unity-Package/Assets/Resources.meta b/Unity-Package/Assets/Resources.meta new file mode 100644 index 0000000..0ce8dc4 --- /dev/null +++ b/Unity-Package/Assets/Resources.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e6f8313b06bdd5546ab4abec15935ec8 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Unity-Package/Assets/Resources/Unity-MCP-ConnectionConfig.json b/Unity-Package/Assets/Resources/Unity-MCP-ConnectionConfig.json new file mode 100644 index 0000000..bc008a3 --- /dev/null +++ b/Unity-Package/Assets/Resources/Unity-MCP-ConnectionConfig.json @@ -0,0 +1,7 @@ +{ + "Host": "http://localhost:8080", + "Port": 8080, + "KeepConnected": false, + "LogLevel": 3, + "TimeoutMs": 10000 +} \ No newline at end of file diff --git a/Unity-Package/Assets/Resources/Unity-MCP-ConnectionConfig.json.meta b/Unity-Package/Assets/Resources/Unity-MCP-ConnectionConfig.json.meta new file mode 100644 index 0000000..1b2a0af --- /dev/null +++ b/Unity-Package/Assets/Resources/Unity-MCP-ConnectionConfig.json.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 90ed38b81c9eb93489944f9eab720a3a +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Unity-Package/Assets/root/Runtime/Future/Types/FutureSprite.cs b/Unity-Package/Assets/root/Runtime/Future/Types/FutureSprite.cs index b495be2..f702354 100644 --- a/Unity-Package/Assets/root/Runtime/Future/Types/FutureSprite.cs +++ b/Unity-Package/Assets/root/Runtime/Future/Types/FutureSprite.cs @@ -108,7 +108,7 @@ public static void ReleaseMemorySprite(Sprite sprite, DebugLevel logLevel = Debu // --- Web Request --- protected override UnityWebRequest CreateWebRequest(string url) - => UnityWebRequestTexture.GetTexture(url); + => ImageLoader.settings.webRequestProvider.CreateTextureRequest(url); protected override Sprite ParseWebRequest(UnityWebRequest webRequest) => ImageLoader.ToSprite(DownloadHandlerTexture.GetContent(webRequest), pivot); protected override Sprite ParseBytes(byte[] bytes) diff --git a/Unity-Package/Assets/root/Runtime/Future/Types/FutureTexture.cs b/Unity-Package/Assets/root/Runtime/Future/Types/FutureTexture.cs index 44c74be..72d843b 100644 --- a/Unity-Package/Assets/root/Runtime/Future/Types/FutureTexture.cs +++ b/Unity-Package/Assets/root/Runtime/Future/Types/FutureTexture.cs @@ -62,7 +62,7 @@ public static void ReleaseMemoryTexture(Texture2D obj, DebugLevel logLevel = Deb // --- Web Request --- protected override UnityWebRequest CreateWebRequest(string url) - => UnityWebRequestTexture.GetTexture(url); + => ImageLoader.settings.webRequestProvider.CreateTextureRequest(url); protected override Texture2D ParseWebRequest(UnityWebRequest webRequest) => DownloadHandlerTexture.GetContent(webRequest); protected override Texture2D ParseBytes(byte[] bytes) diff --git a/Unity-Package/Assets/root/Runtime/ImageLoader.Settings.cs b/Unity-Package/Assets/root/Runtime/ImageLoader.Settings.cs index 206006c..3969973 100644 --- a/Unity-Package/Assets/root/Runtime/ImageLoader.Settings.cs +++ b/Unity-Package/Assets/root/Runtime/ImageLoader.Settings.cs @@ -40,6 +40,12 @@ public partial class Settings /// Default value is 30 seconds /// public TimeSpan timeout = TimeSpan.FromSeconds(30); + + /// + /// Web request provider for dependency injection + /// Allows for mocking during tests + /// + public IWebRequestProvider webRequestProvider { get; set; } = new DefaultWebRequestProvider(); } public enum DebugLevel diff --git a/Unity-Package/Assets/root/Runtime/Utils/DefaultWebRequestProvider.cs b/Unity-Package/Assets/root/Runtime/Utils/DefaultWebRequestProvider.cs new file mode 100644 index 0000000..f9d55f5 --- /dev/null +++ b/Unity-Package/Assets/root/Runtime/Utils/DefaultWebRequestProvider.cs @@ -0,0 +1,21 @@ +using UnityEngine.Networking; + +namespace Extensions.Unity.ImageLoader +{ + /// + /// Default implementation of IWebRequestProvider using standard UnityWebRequest + /// Used in production builds + /// + public class DefaultWebRequestProvider : IWebRequestProvider + { + public UnityWebRequest CreateTextureRequest(string url) + { + return UnityWebRequestTexture.GetTexture(url); + } + + public UnityWebRequest CreateDataRequest(string url) + { + return UnityWebRequest.Get(url); + } + } +} \ No newline at end of file diff --git a/Unity-Package/Assets/root/Runtime/Utils/DefaultWebRequestProvider.cs.meta b/Unity-Package/Assets/root/Runtime/Utils/DefaultWebRequestProvider.cs.meta new file mode 100644 index 0000000..9afac5b --- /dev/null +++ b/Unity-Package/Assets/root/Runtime/Utils/DefaultWebRequestProvider.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 5710a4cae5074e34c82c050d1e7cc8b0 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Unity-Package/Assets/root/Runtime/Utils/IWebRequestProvider.cs b/Unity-Package/Assets/root/Runtime/Utils/IWebRequestProvider.cs new file mode 100644 index 0000000..c2ed478 --- /dev/null +++ b/Unity-Package/Assets/root/Runtime/Utils/IWebRequestProvider.cs @@ -0,0 +1,25 @@ +using UnityEngine.Networking; + +namespace Extensions.Unity.ImageLoader +{ + /// + /// Interface for providing UnityWebRequest instances for image loading + /// Allows for dependency injection and mocking during tests + /// + public interface IWebRequestProvider + { + /// + /// Create a UnityWebRequest for loading a texture from the given URL + /// + /// URL to load texture from + /// Configured UnityWebRequest for texture loading + UnityWebRequest CreateTextureRequest(string url); + + /// + /// Create a UnityWebRequest for loading generic data from the given URL + /// + /// URL to load data from + /// Configured UnityWebRequest for data loading + UnityWebRequest CreateDataRequest(string url); + } +} \ No newline at end of file diff --git a/Unity-Package/Assets/root/Runtime/Utils/IWebRequestProvider.cs.meta b/Unity-Package/Assets/root/Runtime/Utils/IWebRequestProvider.cs.meta new file mode 100644 index 0000000..c8cb780 --- /dev/null +++ b/Unity-Package/Assets/root/Runtime/Utils/IWebRequestProvider.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: e7684db19ca8d77448306f553a04706e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequest.cs b/Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequest.cs new file mode 100644 index 0000000..94bf7c4 --- /dev/null +++ b/Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequest.cs @@ -0,0 +1,202 @@ +using System; +using System.Reflection; +using Cysharp.Threading.Tasks; +using UnityEngine; +using UnityEngine.Networking; + +namespace Extensions.Unity.ImageLoader.Tests.Utils +{ + /// + /// Mock UnityWebRequest that simulates network behavior without actual networking + /// Uses composition pattern instead of inheritance to work around Unity's sealed classes + /// + public class MockWebRequest : UnityWebRequest + { + public enum RequestType + { + Texture, + Data + } + + private readonly MockResponse mockResponse; + private readonly RequestType requestType; + private UnityWebRequestAsyncOperation asyncOperation; + private bool isCompleted = false; + + public MockWebRequest(string url, MockResponse response, RequestType type) : base(url) + { + mockResponse = response; + requestType = type; + + // Set up appropriate download handler with reflection to avoid sealed class issues + if (type == RequestType.Texture) + { + downloadHandler = new DownloadHandlerTexture(false); + SetDownloadHandlerData(); + } + else + { + downloadHandler = new DownloadHandlerBuffer(); + SetDownloadHandlerData(); + } + } + + private void SetDownloadHandlerData() + { + try + { + // Use reflection to set the internal data + var dataField = typeof(DownloadHandler).GetField("m_Data", BindingFlags.NonPublic | BindingFlags.Instance); + if (dataField != null) + { + dataField.SetValue(downloadHandler, mockResponse?.Data ?? new byte[0]); + } + } + catch (Exception ex) + { + Debug.LogWarning($"Could not set download handler data via reflection: {ex.Message}"); + } + } + + public new UnityWebRequestAsyncOperation SendWebRequest() + { + if (asyncOperation != null) + return asyncOperation; + + // Create a dummy async operation that we can control + // Use a valid URL to avoid connection errors, but we'll override the result + var dummyRequest = new UnityWebRequest("https://httpbin.org/status/200"); + dummyRequest.downloadHandler = new DownloadHandlerBuffer(); + asyncOperation = dummyRequest.SendWebRequest(); + + // Immediately abort to prevent actual network call + dummyRequest.Abort(); + dummyRequest.Dispose(); + + // Simulate the async behavior + UniTask.Run(async () => + { + try + { + if (mockResponse.ShouldTimeout) + { + // For timeout, we just wait indefinitely + await UniTask.Delay(TimeSpan.FromHours(1)); + return; + } + + if (mockResponse.DelaySeconds > 0) + { + await UniTask.Delay(TimeSpan.FromSeconds(mockResponse.DelaySeconds)); + } + + // Complete the operation on main thread + await UniTask.SwitchToMainThread(); + CompleteOperation(); + } + catch (OperationCanceledException) + { + await UniTask.SwitchToMainThread(); + CompleteOperation(); + } + catch (Exception ex) + { + Debug.LogException(ex); + await UniTask.SwitchToMainThread(); + CompleteOperation(); + } + }).Forget(); + + return asyncOperation; + } + + private void CompleteOperation() + { + if (isCompleted) return; + isCompleted = true; + + try + { + if (!mockResponse.IsSuccess && !string.IsNullOrEmpty(mockResponse.Error)) + { + // Use reflection to set internal state + SetInternalError(mockResponse.Error); + } + else if (mockResponse.IsSuccess) + { + // Set success state + SetInternalSuccess(); + } + } + catch (Exception ex) + { + Debug.LogError($"Error setting mock response state: {ex.Message}"); + } + } + + private void SetInternalError(string errorMessage) + { + try + { + // Set result to connection error + var resultField = typeof(UnityWebRequest).GetField("m_Result", BindingFlags.NonPublic | BindingFlags.Instance); + if (resultField != null) + { +#if UNITY_2020_1_OR_NEWER + resultField.SetValue(this, UnityWebRequest.Result.ProtocolError); +#endif + } + + // Set error message + var errorField = typeof(UnityWebRequest).GetField("m_Error", BindingFlags.NonPublic | BindingFlags.Instance); + if (errorField != null) + { + errorField.SetValue(this, errorMessage); + } + } + catch (Exception ex) + { + Debug.LogError($"Failed to set internal error state via reflection: {ex.Message}"); + } + } + + private void SetInternalSuccess() + { + try + { + // Set result to success + var resultField = typeof(UnityWebRequest).GetField("m_Result", BindingFlags.NonPublic | BindingFlags.Instance); + if (resultField != null) + { +#if UNITY_2020_1_OR_NEWER + resultField.SetValue(this, UnityWebRequest.Result.Success); +#endif + } + + // Ensure data is available in download handler + SetDownloadHandlerData(); + + // For texture requests, set the texture + if (requestType == RequestType.Texture && downloadHandler is DownloadHandlerTexture textureHandler && mockResponse?.Texture != null) + { + try + { + var textureField = typeof(DownloadHandlerTexture).GetField("m_Texture", BindingFlags.NonPublic | BindingFlags.Instance); + if (textureField != null) + { + textureField.SetValue(textureHandler, mockResponse.Texture); + } + } + catch (Exception ex) + { + Debug.LogWarning($"Could not set texture via reflection: {ex.Message}"); + } + } + } + catch (Exception ex) + { + Debug.LogError($"Failed to set internal success state via reflection: {ex.Message}"); + } + } + } +} \ No newline at end of file diff --git a/Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequest.cs.meta b/Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequest.cs.meta new file mode 100644 index 0000000..3caa22c --- /dev/null +++ b/Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequest.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: ff97948234cb12a44a6b6bb44dd2fb6a +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequestProvider.cs b/Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequestProvider.cs new file mode 100644 index 0000000..3551f4f --- /dev/null +++ b/Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequestProvider.cs @@ -0,0 +1,101 @@ +using System; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.Networking; + +namespace Extensions.Unity.ImageLoader.Tests.Utils +{ + /// + /// Mock implementation of IWebRequestProvider for testing + /// Provides controllable responses without actual network requests + /// + public class MockWebRequestProvider : IWebRequestProvider + { + private static MockWebRequestProvider instance; + public static MockWebRequestProvider Instance => instance ??= new MockWebRequestProvider(); + + private readonly Dictionary responses = new Dictionary(); + private MockResponse defaultResponse = MockResponse.CreateSuccess(TestUtils.CreateTestTexture()); + + public void Reset() + { + responses.Clear(); + defaultResponse = MockResponse.CreateSuccess(TestUtils.CreateTestTexture()); + } + + public void SetDefaultResponse(MockResponse response) + { + defaultResponse = response; + } + + public void SetResponse(string url, MockResponse response) + { + responses[url] = response; + } + + public UnityWebRequest CreateTextureRequest(string url) + { + var response = responses.ContainsKey(url) ? responses[url] : defaultResponse; + return new MockWebRequest(url, response, MockWebRequest.RequestType.Texture); + } + + public UnityWebRequest CreateDataRequest(string url) + { + var response = responses.ContainsKey(url) ? responses[url] : defaultResponse; + return new MockWebRequest(url, response, MockWebRequest.RequestType.Data); + } + } + + /// + /// Represents a mock response configuration + /// + public class MockResponse + { + public bool IsSuccess { get; set; } + public string Error { get; set; } + public byte[] Data { get; set; } + public Texture2D Texture { get; set; } + public float DelaySeconds { get; set; } + public bool ShouldTimeout { get; set; } + + public static MockResponse CreateSuccess(Texture2D texture, float delaySeconds = 0f) + { + return new MockResponse + { + IsSuccess = true, + Texture = texture, + Data = texture?.EncodeToPNG() ?? new byte[0], + DelaySeconds = delaySeconds + }; + } + + public static MockResponse CreateSuccess(byte[] data, float delaySeconds = 0f) + { + return new MockResponse + { + IsSuccess = true, + Data = data, + DelaySeconds = delaySeconds + }; + } + + public static MockResponse CreateError(string error = "Mock network error", float delaySeconds = 0f) + { + return new MockResponse + { + IsSuccess = false, + Error = error, + DelaySeconds = delaySeconds + }; + } + + public static MockResponse CreateTimeout() + { + return new MockResponse + { + ShouldTimeout = true, + DelaySeconds = float.MaxValue + }; + } + } +} \ No newline at end of file diff --git a/Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequestProvider.cs.meta b/Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequestProvider.cs.meta new file mode 100644 index 0000000..8f7a37d --- /dev/null +++ b/Unity-Package/Assets/root/Tests/Base/Utils/MockWebRequestProvider.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 610fad8839602404eae6b0da851bbd0f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Unity-Package/Assets/root/Tests/Base/Utils/TestUtils.cs b/Unity-Package/Assets/root/Tests/Base/Utils/TestUtils.cs index 91c5dd2..8adb19f 100644 --- a/Unity-Package/Assets/root/Tests/Base/Utils/TestUtils.cs +++ b/Unity-Package/Assets/root/Tests/Base/Utils/TestUtils.cs @@ -12,14 +12,22 @@ public static partial class TestUtils { public static readonly string[] ImageURLs = { - "https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/docs/img/test/ImageA.jpg", - "https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/docs/img/test/ImageB.png", - "https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/docs/img/test/ImageC.png" + "https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/Test%20Images/ImageA.jpg", + "https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/Test%20Images/ImageB.png", + "https://github.com/IvanMurzak/Unity-ImageLoader/raw/main/Test%20Images/ImageC.png" }; public static string IncorrectImageURL => $"https://doesntexist.com/{Guid.NewGuid()}.png"; public static IEnumerable IncorrectImageURLs(int count = 3) => Enumerable.Range(0, count).Select(_ => IncorrectImageURL); public static readonly byte[] CorruptedTextureBytes = new byte[] { 0 }; + // Mock URLs for testing - these don't require network access + public static readonly string[] MockImageURLs = + { + "mock://test-image-a.jpg", + "mock://test-image-b.png", + "mock://test-image-c.png" + }; + public static readonly Dictionary placeholderSprites = new Dictionary { { PlaceholderTrigger.LoadingFromDiskCache, Texture2D.whiteTexture.ToSprite() }, @@ -36,6 +44,10 @@ public static IEnumerator ClearEverything(string message) LogAssert.ignoreFailingMessages = true; // compilation error in player build UniTaskScheduler.UnobservedExceptionWriteLogType = LogType.Exception; + + // Enable mock provider for tests + EnableMockProvider(); + ImageLoader.ClearSpriteRef(); ImageLoader.ClearTextureRef(); yield return ImageLoader.ClearCacheAll().TimeoutCoroutine(TimeSpan.FromSeconds(10)); @@ -65,5 +77,38 @@ public static void RunNoLogs(Action test) ImageLoader.settings.debugLevel = DebugLevel.Error; test(); } + + public static Texture2D CreateTestTexture(int width = 64, int height = 64, Color? color = null) + { + var testColor = color ?? Color.green; + var texture = new Texture2D(width, height, TextureFormat.ARGB32, false); + var pixels = new Color[width * height]; + for (int i = 0; i < pixels.Length; i++) + pixels[i] = testColor; + texture.SetPixels(pixels); + texture.Apply(); + return texture; + } + + public static void EnableMockProvider() + { + MockWebRequestProvider.Instance.Reset(); + ImageLoader.settings.webRequestProvider = MockWebRequestProvider.Instance; + } + + public static void DisableMockProvider() + { + ImageLoader.settings.webRequestProvider = new DefaultWebRequestProvider(); + } + + public static void SetupMockResponse(string url, MockResponse response) + { + MockWebRequestProvider.Instance.SetResponse(url, response); + } + + public static void SetupDefaultMockResponse(MockResponse response) + { + MockWebRequestProvider.Instance.SetDefaultResponse(response); + } } } \ No newline at end of file diff --git a/Unity-Package/CLAUDE.md b/Unity-Package/CLAUDE.md new file mode 100644 index 0000000..3282f9d --- /dev/null +++ b/Unity-Package/CLAUDE.md @@ -0,0 +1,112 @@ +# CLAUDE.md + +This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository. + +## Unity Package Structure + +This is a Unity package project for the **Image Loader** library - an asynchronous image loading system with two-layer caching (Memory and Disk). The package is located at `Assets/root/` within the Unity project. + +### Key Architecture Components + +1. **Core System (`ImageLoader.cs`)**: Static entry point providing loading methods for `Sprite` and `Texture2D` +2. **Future System**: Async operation wrapper (`IFuture`, `Future`) for handling loading lifecycle +3. **Reference System**: Memory management for `Reference` to prevent memory leaks +4. **Cache Layers**: Memory cache (fast) and Disk cache (persistent) with configurable settings +5. **Consumer System**: Extension methods to directly set loaded images into Unity components + +### Assembly Structure + +- **`Extensions.Unity.ImageLoader`**: Main runtime assembly (depends on UniTask) +- **`Extensions.Unity.ImageLoader.Tests`**: Shared test utilities +- **`Extensions.Unity.ImageLoader.Tests.Editor`**: Editor-specific tests (NUnit) +- **`Extensions.Unity.ImageLoader.Tests.Runtime`**: Runtime tests (NUnit) +- **`Extensions.Unity.ImageLoader.Samples`**: Example code and usage samples + +## Development Commands + +### Testing +- **Editor Tests**: Use Unity Test Runner window (Window → General → Test Runner) - Editor tab +- **Runtime Tests**: Use Unity Test Runner window (Window → General → Test Runner) - PlayMode tab +- **Command Line**: Unity supports running tests via batch mode with `-runTests` parameter + +### Building/Development +- Unity package development uses Unity Editor directly +- No external build system (npm/gradle/etc) - Unity handles compilation +- Package validation through Unity Package Manager + +### Dependencies +- **UniTask 2.5.10**: Async/await support for Unity (via OpenUPM) +- **Unity Test Framework 1.4.6**: Testing framework +- **Unity uGUI 1.0.0**: UI components for image consumers + +## Code Architecture Patterns + +### Loading Pattern +```csharp +// Basic loading +await ImageLoader.LoadSprite(url) + +// With consumer (auto-assignment) +await ImageLoader.LoadSprite(url).Consume(image) + +// With lifecycle events +ImageLoader.LoadSprite(url) + .LoadedFromMemoryCache(sprite => ...) + .LoadedFromDiskCache(sprite => ...) + .LoadedFromSource(sprite => ...) + .Then(sprite => ...) + .Failed(ex => ...) + .Consume(image) + .Forget(); +``` + +### Memory Management +- Use `LoadSpriteRef()` instead of `LoadSprite()` for automatic memory management +- References are disposed when target components are destroyed +- Manual disposal via `reference.Dispose()` or `reference.DisposeOnDestroy(component)` + +### Caching System +- Memory cache: Fast access, cleared on low memory +- Disk cache: Persistent across sessions (not available on WebGL) +- Both layers configurable globally via `ImageLoader.settings` or per-request + +## Testing Approach + +Tests are organized into: +- **Base utilities** (`Assets/root/Tests/Base/Utils/`): Shared test helpers and fake implementations +- **Editor tests**: Unit tests running in editor mode +- **Runtime tests**: Integration tests running in play mode + +Test structure uses: +- `FakeFuture`: Mock implementation for testing lifecycle events +- `TestUtils`: Loading utilities with test image URLs +- `FutureListener`: Event tracking for async operations + +## Key Files and Locations + +- Main API: `Assets/root/Runtime/ImageLoader.cs` +- Future system: `Assets/root/Runtime/Future/Future.cs` and related files +- Extensions: `Assets/root/Runtime/Future/Extensions/FutureEx.*.cs` +- Cache implementation: `Assets/root/Runtime/ImageLoader.Cache.*.cs` +- Sample usage: `Assets/root/Samples/Sample*.cs` +- Package definition: `Assets/root/package.json` + +## Common Development Tasks + +### Adding New Features +1. Implement core functionality in `Assets/root/Runtime/` +2. Add extension methods in `Assets/root/Runtime/Future/Extensions/` if needed +3. Create sample usage in `Assets/root/Samples/` +4. Add tests in `Assets/root/Tests/Editor/` and `Assets/root/Tests/Runtime/` + +### Testing New Code +1. Create test methods in appropriate test assembly +2. Use `TestUtils` helpers for loading operations +3. Use `FutureListener` for tracking async events +4. Test both success and failure scenarios + +### Performance Considerations +- Memory management critical due to large Texture2D objects +- Use Reference system for automatic cleanup +- Consider cache settings impact on memory usage +- Test WebGL compatibility (no disk cache) \ No newline at end of file diff --git a/Unity-Package/Packages/manifest.json b/Unity-Package/Packages/manifest.json index 9b8761e..224f03f 100644 --- a/Unity-Package/Packages/manifest.json +++ b/Unity-Package/Packages/manifest.json @@ -1,6 +1,7 @@ { "dependencies": { "com.cysharp.unitask": "2.5.10", + "com.unity.ai.navigation": "1.1.5", "com.unity.ext.nunit": "2.0.5", "com.unity.ide.visualstudio": "2.0.23", "com.unity.test-framework": "1.4.6", @@ -13,7 +14,8 @@ "com.unity.modules.unitywebrequestassetbundle": "1.0.0", "com.unity.modules.unitywebrequestaudio": "1.0.0", "com.unity.modules.unitywebrequesttexture": "1.0.0", - "com.unity.modules.unitywebrequestwww": "1.0.0" + "com.unity.modules.unitywebrequestwww": "1.0.0", + "com.ivanmurzak.unity.mcp": "0.17.2" }, "scopedRegistries": [ { @@ -21,8 +23,70 @@ "url": "https://package.openupm.com", "scopes": [ "com.cysharp.unitask", - "com.openupm" + "com.ivanmurzak.unity.mcp", + "com.openupm", + "extensions.unity.playerprefsex", + "org.nuget.microsoft.aspnetcore.connections.abstractions", + "org.nuget.microsoft.aspnetcore.http.connections.client", + "org.nuget.microsoft.aspnetcore.http.connections.common", + "org.nuget.microsoft.aspnetcore.signalr.client", + "org.nuget.microsoft.aspnetcore.signalr.client.core", + "org.nuget.microsoft.aspnetcore.signalr.common", + "org.nuget.microsoft.aspnetcore.signalr.protocols.json", + "org.nuget.microsoft.bcl.asyncinterfaces", + "org.nuget.microsoft.bcl.memory", + "org.nuget.microsoft.bcl.timeprovider", + "org.nuget.microsoft.codeanalysis.analyzers", + "org.nuget.microsoft.codeanalysis.common", + "org.nuget.microsoft.codeanalysis.csharp", + "org.nuget.microsoft.extensions.caching.abstractions", + "org.nuget.microsoft.extensions.configuration", + "org.nuget.microsoft.extensions.configuration.abstractions", + "org.nuget.microsoft.extensions.configuration.binder", + "org.nuget.microsoft.extensions.configuration.commandline", + "org.nuget.microsoft.extensions.configuration.environmentvariables", + "org.nuget.microsoft.extensions.configuration.fileextensions", + "org.nuget.microsoft.extensions.configuration.json", + "org.nuget.microsoft.extensions.configuration.usersecrets", + "org.nuget.microsoft.extensions.dependencyinjection", + "org.nuget.microsoft.extensions.dependencyinjection.abstractions", + "org.nuget.microsoft.extensions.diagnostics", + "org.nuget.microsoft.extensions.diagnostics.abstractions", + "org.nuget.microsoft.extensions.features", + "org.nuget.microsoft.extensions.fileproviders.abstractions", + "org.nuget.microsoft.extensions.fileproviders.physical", + "org.nuget.microsoft.extensions.filesystemglobbing", + "org.nuget.microsoft.extensions.hosting", + "org.nuget.microsoft.extensions.hosting.abstractions", + "org.nuget.microsoft.extensions.logging", + "org.nuget.microsoft.extensions.logging.abstractions", + "org.nuget.microsoft.extensions.logging.configuration", + "org.nuget.microsoft.extensions.logging.console", + "org.nuget.microsoft.extensions.logging.debug", + "org.nuget.microsoft.extensions.logging.eventlog", + "org.nuget.microsoft.extensions.logging.eventsource", + "org.nuget.microsoft.extensions.options", + "org.nuget.microsoft.extensions.options.configurationextensions", + "org.nuget.microsoft.extensions.primitives", + "org.nuget.r3", + "org.nuget.system.buffers", + "org.nuget.system.collections.immutable", + "org.nuget.system.componentmodel.annotations", + "org.nuget.system.diagnostics.diagnosticsource", + "org.nuget.system.diagnostics.eventlog", + "org.nuget.system.io.pipelines", + "org.nuget.system.memory", + "org.nuget.system.net.serversentevents", + "org.nuget.system.numerics.vectors", + "org.nuget.system.reflection.metadata", + "org.nuget.system.runtime.compilerservices.unsafe", + "org.nuget.system.security.principal.windows", + "org.nuget.system.text.encoding.codepages", + "org.nuget.system.text.encodings.web", + "org.nuget.system.text.json", + "org.nuget.system.threading.channels", + "org.nuget.system.threading.tasks.extensions" ] } ] -} +} \ No newline at end of file diff --git a/Unity-Package/Packages/packages-lock.json b/Unity-Package/Packages/packages-lock.json index 19056c8..ffc80cd 100644 --- a/Unity-Package/Packages/packages-lock.json +++ b/Unity-Package/Packages/packages-lock.json @@ -7,6 +7,37 @@ "dependencies": {}, "url": "https://package.openupm.com" }, + "com.ivanmurzak.unity.mcp": { + "version": "0.17.2", + "depth": 0, + "source": "registry", + "dependencies": { + "com.unity.test-framework": "1.1.33", + "com.unity.modules.uielements": "1.0.0", + "extensions.unity.playerprefsex": "2.0.2", + "org.nuget.microsoft.bcl.memory": "9.0.7", + "org.nuget.microsoft.aspnetcore.signalr.client": "9.0.7", + "org.nuget.microsoft.aspnetcore.signalr.protocols.json": "9.0.7", + "org.nuget.microsoft.codeanalysis.csharp": "4.13.0", + "org.nuget.microsoft.extensions.caching.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.hosting": "9.0.7", + "org.nuget.microsoft.extensions.hosting.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", + "org.nuget.r3": "1.3.0", + "org.nuget.system.text.json": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "com.unity.ai.navigation": { + "version": "1.1.5", + "depth": 0, + "source": "registry", + "dependencies": { + "com.unity.modules.ai": "1.0.0" + }, + "url": "https://packages.unity.com" + }, "com.unity.ext.nunit": { "version": "2.0.5", "depth": 0, @@ -43,6 +74,696 @@ "com.unity.modules.imgui": "1.0.0" } }, + "extensions.unity.playerprefsex": { + "version": "2.0.2", + "depth": 1, + "source": "registry", + "dependencies": {}, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.aspnetcore.connections.abstractions": { + "version": "9.0.7", + "depth": 3, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.features": "9.0.7", + "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", + "org.nuget.system.io.pipelines": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.aspnetcore.http.connections.client": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.aspnetcore.http.connections.common": "9.0.7", + "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.options": "9.0.7", + "org.nuget.system.net.serversentevents": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.aspnetcore.http.connections.common": { + "version": "9.0.7", + "depth": 3, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.aspnetcore.connections.abstractions": "9.0.7", + "org.nuget.system.text.json": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.aspnetcore.signalr.client": { + "version": "9.0.7", + "depth": 1, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.aspnetcore.signalr.client.core": "9.0.7", + "org.nuget.microsoft.aspnetcore.http.connections.client": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.aspnetcore.signalr.client.core": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.aspnetcore.signalr.protocols.json": "9.0.7", + "org.nuget.microsoft.aspnetcore.signalr.common": "9.0.7", + "org.nuget.microsoft.bcl.timeprovider": "9.0.7", + "org.nuget.microsoft.extensions.dependencyinjection": "9.0.7", + "org.nuget.microsoft.extensions.logging": "9.0.7", + "org.nuget.system.threading.channels": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.aspnetcore.signalr.common": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.aspnetcore.connections.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.options": "9.0.7", + "org.nuget.system.text.json": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.aspnetcore.signalr.protocols.json": { + "version": "9.0.7", + "depth": 1, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.aspnetcore.signalr.common": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.bcl.asyncinterfaces": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.system.threading.tasks.extensions": "4.5.4" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.bcl.memory": { + "version": "9.0.7", + "depth": 1, + "source": "registry", + "dependencies": { + "org.nuget.system.memory": "4.5.5", + "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.bcl.timeprovider": { + "version": "9.0.7", + "depth": 3, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.codeanalysis.analyzers": { + "version": "3.11.0", + "depth": 2, + "source": "registry", + "dependencies": {}, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.codeanalysis.common": { + "version": "4.13.0", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.codeanalysis.analyzers": "3.11.0", + "org.nuget.system.collections.immutable": "8.0.0", + "org.nuget.system.memory": "4.5.5", + "org.nuget.system.reflection.metadata": "8.0.0", + "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0", + "org.nuget.system.text.encoding.codepages": "7.0.0", + "org.nuget.system.threading.tasks.extensions": "4.5.4", + "org.nuget.system.buffers": "4.5.1", + "org.nuget.system.numerics.vectors": "4.5.0" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.codeanalysis.csharp": { + "version": "4.13.0", + "depth": 1, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.codeanalysis.common": "4.13.0", + "org.nuget.microsoft.codeanalysis.analyzers": "3.11.0", + "org.nuget.system.buffers": "4.5.1", + "org.nuget.system.collections.immutable": "8.0.0", + "org.nuget.system.memory": "4.5.5", + "org.nuget.system.numerics.vectors": "4.5.0", + "org.nuget.system.reflection.metadata": "8.0.0", + "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0", + "org.nuget.system.text.encoding.codepages": "7.0.0", + "org.nuget.system.threading.tasks.extensions": "4.5.4" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.caching.abstractions": { + "version": "9.0.7", + "depth": 1, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.primitives": "9.0.7", + "org.nuget.system.threading.tasks.extensions": "4.5.4" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.configuration": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.primitives": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.configuration.abstractions": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.primitives": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.configuration.binder": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.configuration.commandline": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.configuration": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.configuration.environmentvariables": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.configuration": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.configuration.fileextensions": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.configuration": "9.0.7", + "org.nuget.microsoft.extensions.fileproviders.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.fileproviders.physical": "9.0.7", + "org.nuget.microsoft.extensions.primitives": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.configuration.json": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.configuration.fileextensions": "9.0.7", + "org.nuget.microsoft.extensions.configuration": "9.0.7", + "org.nuget.microsoft.extensions.fileproviders.abstractions": "9.0.7", + "org.nuget.system.text.json": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.configuration.usersecrets": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.configuration.json": "9.0.7", + "org.nuget.microsoft.extensions.fileproviders.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.fileproviders.physical": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.dependencyinjection": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", + "org.nuget.system.threading.tasks.extensions": "4.5.4" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": { + "version": "9.0.7", + "depth": 1, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", + "org.nuget.system.threading.tasks.extensions": "4.5.4" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.diagnostics": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.configuration": "9.0.7", + "org.nuget.microsoft.extensions.diagnostics.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.options.configurationextensions": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.diagnostics.abstractions": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.options": "9.0.7", + "org.nuget.system.diagnostics.diagnosticsource": "9.0.7", + "org.nuget.system.buffers": "4.5.1", + "org.nuget.system.memory": "4.5.5" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.features": { + "version": "9.0.7", + "depth": 4, + "source": "registry", + "dependencies": {}, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.fileproviders.abstractions": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.primitives": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.fileproviders.physical": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.fileproviders.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.filesystemglobbing": "9.0.7", + "org.nuget.microsoft.extensions.primitives": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.filesystemglobbing": { + "version": "9.0.7", + "depth": 3, + "source": "registry", + "dependencies": {}, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.hosting": { + "version": "9.0.7", + "depth": 1, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", + "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.configuration.binder": "9.0.7", + "org.nuget.microsoft.extensions.configuration.commandline": "9.0.7", + "org.nuget.microsoft.extensions.configuration.environmentvariables": "9.0.7", + "org.nuget.microsoft.extensions.configuration.fileextensions": "9.0.7", + "org.nuget.microsoft.extensions.configuration.json": "9.0.7", + "org.nuget.microsoft.extensions.configuration.usersecrets": "9.0.7", + "org.nuget.microsoft.extensions.configuration": "9.0.7", + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.dependencyinjection": "9.0.7", + "org.nuget.microsoft.extensions.diagnostics": "9.0.7", + "org.nuget.microsoft.extensions.fileproviders.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.fileproviders.physical": "9.0.7", + "org.nuget.microsoft.extensions.hosting.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging.configuration": "9.0.7", + "org.nuget.microsoft.extensions.logging.console": "9.0.7", + "org.nuget.microsoft.extensions.logging.debug": "9.0.7", + "org.nuget.microsoft.extensions.logging.eventlog": "9.0.7", + "org.nuget.microsoft.extensions.logging.eventsource": "9.0.7", + "org.nuget.microsoft.extensions.logging": "9.0.7", + "org.nuget.microsoft.extensions.options": "9.0.7", + "org.nuget.system.threading.tasks.extensions": "4.5.4" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.hosting.abstractions": { + "version": "9.0.7", + "depth": 1, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", + "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.diagnostics.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.fileproviders.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", + "org.nuget.system.threading.tasks.extensions": "4.5.4" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.logging": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", + "org.nuget.microsoft.extensions.dependencyinjection": "9.0.7", + "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.options": "9.0.7", + "org.nuget.system.diagnostics.diagnosticsource": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.logging.abstractions": { + "version": "9.0.7", + "depth": 1, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", + "org.nuget.system.diagnostics.diagnosticsource": "9.0.7", + "org.nuget.system.buffers": "4.5.1", + "org.nuget.system.memory": "4.5.5" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.logging.configuration": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.configuration.binder": "9.0.7", + "org.nuget.microsoft.extensions.configuration": "9.0.7", + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging": "9.0.7", + "org.nuget.microsoft.extensions.options.configurationextensions": "9.0.7", + "org.nuget.microsoft.extensions.options": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.logging.console": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging.configuration": "9.0.7", + "org.nuget.microsoft.extensions.logging": "9.0.7", + "org.nuget.microsoft.extensions.options": "9.0.7", + "org.nuget.system.text.json": "9.0.7", + "org.nuget.system.buffers": "4.5.1" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.logging.debug": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.logging.eventlog": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging": "9.0.7", + "org.nuget.microsoft.extensions.options": "9.0.7", + "org.nuget.system.diagnostics.eventlog": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.logging.eventsource": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.logging": "9.0.7", + "org.nuget.microsoft.extensions.options": "9.0.7", + "org.nuget.microsoft.extensions.primitives": "9.0.7", + "org.nuget.system.text.json": "9.0.7", + "org.nuget.system.memory": "4.5.5", + "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.options": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.primitives": "9.0.7", + "org.nuget.system.componentmodel.annotations": "5.0.0" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.options.configurationextensions": { + "version": "9.0.7", + "depth": 3, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.configuration.binder": "9.0.7", + "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", + "org.nuget.microsoft.extensions.options": "9.0.7", + "org.nuget.microsoft.extensions.primitives": "9.0.7" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.microsoft.extensions.primitives": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.system.memory": "4.5.5", + "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.r3": { + "version": "1.3.0", + "depth": 1, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.bcl.timeprovider": "8.0.0", + "org.nuget.system.buffers": "4.5.1", + "org.nuget.system.componentmodel.annotations": "5.0.0", + "org.nuget.system.memory": "4.5.5", + "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0", + "org.nuget.system.threading.channels": "8.0.0" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.system.buffers": { + "version": "4.5.1", + "depth": 2, + "source": "registry", + "dependencies": {}, + "url": "https://package.openupm.com" + }, + "org.nuget.system.collections.immutable": { + "version": "8.0.0", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.system.memory": "4.5.5", + "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.system.componentmodel.annotations": { + "version": "5.0.0", + "depth": 2, + "source": "registry", + "dependencies": {}, + "url": "https://package.openupm.com" + }, + "org.nuget.system.diagnostics.diagnosticsource": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.system.memory": "4.5.5", + "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.system.diagnostics.eventlog": { + "version": "9.0.7", + "depth": 3, + "source": "registry", + "dependencies": { + "org.nuget.system.security.principal.windows": "5.0.0" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.system.io.pipelines": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.system.buffers": "4.5.1", + "org.nuget.system.memory": "4.5.5", + "org.nuget.system.threading.tasks.extensions": "4.5.4" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.system.memory": { + "version": "4.5.5", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.system.buffers": "4.5.1", + "org.nuget.system.numerics.vectors": "4.4.0", + "org.nuget.system.runtime.compilerservices.unsafe": "4.5.3" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.system.net.serversentevents": { + "version": "9.0.7", + "depth": 3, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", + "org.nuget.system.memory": "4.5.5", + "org.nuget.system.threading.tasks.extensions": "4.5.4" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.system.numerics.vectors": { + "version": "4.5.0", + "depth": 2, + "source": "registry", + "dependencies": {}, + "url": "https://package.openupm.com" + }, + "org.nuget.system.reflection.metadata": { + "version": "8.0.0", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.system.collections.immutable": "8.0.0", + "org.nuget.system.memory": "4.5.5" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.system.runtime.compilerservices.unsafe": { + "version": "6.0.0", + "depth": 2, + "source": "registry", + "dependencies": {}, + "url": "https://package.openupm.com" + }, + "org.nuget.system.security.principal.windows": { + "version": "5.0.0", + "depth": 4, + "source": "registry", + "dependencies": {}, + "url": "https://package.openupm.com" + }, + "org.nuget.system.text.encoding.codepages": { + "version": "7.0.0", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.system.memory": "4.5.5", + "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.system.text.encodings.web": { + "version": "9.0.7", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.system.buffers": "4.5.1", + "org.nuget.system.memory": "4.5.5", + "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.system.text.json": { + "version": "9.0.7", + "depth": 1, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", + "org.nuget.system.io.pipelines": "9.0.7", + "org.nuget.system.text.encodings.web": "9.0.7", + "org.nuget.system.buffers": "4.5.1", + "org.nuget.system.memory": "4.5.5", + "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0", + "org.nuget.system.threading.tasks.extensions": "4.5.4" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.system.threading.channels": { + "version": "9.0.7", + "depth": 3, + "source": "registry", + "dependencies": { + "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", + "org.nuget.system.threading.tasks.extensions": "4.5.4" + }, + "url": "https://package.openupm.com" + }, + "org.nuget.system.threading.tasks.extensions": { + "version": "4.5.4", + "depth": 2, + "source": "registry", + "dependencies": { + "org.nuget.system.runtime.compilerservices.unsafe": "4.5.3" + }, + "url": "https://package.openupm.com" + }, + "com.unity.modules.ai": { + "version": "1.0.0", + "depth": 1, + "source": "builtin", + "dependencies": {} + }, "com.unity.modules.assetbundle": { "version": "1.0.0", "depth": 1, @@ -79,6 +800,16 @@ "source": "builtin", "dependencies": {} }, + "com.unity.modules.uielements": { + "version": "1.0.0", + "depth": 1, + "source": "builtin", + "dependencies": { + "com.unity.modules.ui": "1.0.0", + "com.unity.modules.imgui": "1.0.0", + "com.unity.modules.jsonserialize": "1.0.0" + } + }, "com.unity.modules.unitywebrequest": { "version": "1.0.0", "depth": 0, diff --git a/Unity-Package/ProjectSettings/PackageManagerSettings.asset b/Unity-Package/ProjectSettings/PackageManagerSettings.asset index 06b7936..d9068da 100644 --- a/Unity-Package/ProjectSettings/PackageManagerSettings.asset +++ b/Unity-Package/ProjectSettings/PackageManagerSettings.asset @@ -12,7 +12,11 @@ MonoBehaviour: m_Script: {fileID: 13964, guid: 0000000000000000e000000000000000, type: 0} m_Name: m_EditorClassIdentifier: + m_EnablePreReleasePackages: 0 + m_AdvancedSettingsExpanded: 1 m_ScopedRegistriesSettingsExpanded: 1 + m_SeeAllPackageVersions: 0 + m_DismissPreviewPackagesInUse: 0 oneTimeWarningShown: 0 m_Registries: - m_Id: main @@ -20,29 +24,84 @@ MonoBehaviour: m_Url: https://packages.unity.com m_Scopes: [] m_IsDefault: 1 - - m_Id: scoped:package.openupm.com + m_Capabilities: 7 + m_ConfigSource: 0 + - m_Id: scoped:project:package.openupm.com m_Name: package.openupm.com m_Url: https://package.openupm.com m_Scopes: - com.cysharp.unitask + - com.ivanmurzak.unity.mcp - com.openupm + - extensions.unity.playerprefsex + - org.nuget.microsoft.aspnetcore.connections.abstractions + - org.nuget.microsoft.aspnetcore.http.connections.client + - org.nuget.microsoft.aspnetcore.http.connections.common + - org.nuget.microsoft.aspnetcore.signalr.client + - org.nuget.microsoft.aspnetcore.signalr.client.core + - org.nuget.microsoft.aspnetcore.signalr.common + - org.nuget.microsoft.aspnetcore.signalr.protocols.json + - org.nuget.microsoft.bcl.asyncinterfaces + - org.nuget.microsoft.bcl.memory + - org.nuget.microsoft.bcl.timeprovider + - org.nuget.microsoft.codeanalysis.analyzers + - org.nuget.microsoft.codeanalysis.common + - org.nuget.microsoft.codeanalysis.csharp + - org.nuget.microsoft.extensions.caching.abstractions + - org.nuget.microsoft.extensions.configuration + - org.nuget.microsoft.extensions.configuration.abstractions + - org.nuget.microsoft.extensions.configuration.binder + - org.nuget.microsoft.extensions.configuration.commandline + - org.nuget.microsoft.extensions.configuration.environmentvariables + - org.nuget.microsoft.extensions.configuration.fileextensions + - org.nuget.microsoft.extensions.configuration.json + - org.nuget.microsoft.extensions.configuration.usersecrets + - org.nuget.microsoft.extensions.dependencyinjection + - org.nuget.microsoft.extensions.dependencyinjection.abstractions + - org.nuget.microsoft.extensions.diagnostics + - org.nuget.microsoft.extensions.diagnostics.abstractions + - org.nuget.microsoft.extensions.features + - org.nuget.microsoft.extensions.fileproviders.abstractions + - org.nuget.microsoft.extensions.fileproviders.physical + - org.nuget.microsoft.extensions.filesystemglobbing + - org.nuget.microsoft.extensions.hosting + - org.nuget.microsoft.extensions.hosting.abstractions + - org.nuget.microsoft.extensions.logging + - org.nuget.microsoft.extensions.logging.abstractions + - org.nuget.microsoft.extensions.logging.configuration + - org.nuget.microsoft.extensions.logging.console + - org.nuget.microsoft.extensions.logging.debug + - org.nuget.microsoft.extensions.logging.eventlog + - org.nuget.microsoft.extensions.logging.eventsource + - org.nuget.microsoft.extensions.options + - org.nuget.microsoft.extensions.options.configurationextensions + - org.nuget.microsoft.extensions.primitives + - org.nuget.r3 + - org.nuget.system.buffers + - org.nuget.system.collections.immutable + - org.nuget.system.componentmodel.annotations + - org.nuget.system.diagnostics.diagnosticsource + - org.nuget.system.diagnostics.eventlog + - org.nuget.system.io.pipelines + - org.nuget.system.memory + - org.nuget.system.net.serversentevents + - org.nuget.system.numerics.vectors + - org.nuget.system.reflection.metadata + - org.nuget.system.runtime.compilerservices.unsafe + - org.nuget.system.security.principal.windows + - org.nuget.system.text.encoding.codepages + - org.nuget.system.text.encodings.web + - org.nuget.system.text.json + - org.nuget.system.threading.channels + - org.nuget.system.threading.tasks.extensions m_IsDefault: 0 + m_Capabilities: 0 + m_ConfigSource: 4 m_UserSelectedRegistryName: package.openupm.com m_UserAddingNewScopedRegistry: 0 m_RegistryInfoDraft: - m_ErrorMessage: - m_Original: - m_Id: scoped:package.openupm.com - m_Name: package.openupm.com - m_Url: https://package.openupm.com - m_Scopes: - - com.cysharp.unitask - - com.openupm - m_IsDefault: 0 m_Modified: 0 - m_Name: package.openupm.com - m_Url: https://package.openupm.com - m_Scopes: - - com.cysharp.unitask - - com.openupm - m_SelectedScopeIndex: 0 + m_ErrorMessage: + m_UserModificationsInstanceId: -834 + m_OriginalInstanceId: -838 + m_LoadAssets: 0 diff --git a/Unity-Package/ProjectSettings/ProjectVersion.txt b/Unity-Package/ProjectSettings/ProjectVersion.txt index 4c19129..52515b4 100644 --- a/Unity-Package/ProjectSettings/ProjectVersion.txt +++ b/Unity-Package/ProjectSettings/ProjectVersion.txt @@ -1,2 +1,2 @@ -m_EditorVersion: 2019.4.40f1 -m_EditorVersionWithRevision: 2019.4.40f1 (ffc62b691db5) +m_EditorVersion: 2022.3.44f1 +m_EditorVersionWithRevision: 2022.3.44f1 (c3ae09b9f03c) diff --git a/Unity-Package/ProjectSettings/SceneTemplateSettings.json b/Unity-Package/ProjectSettings/SceneTemplateSettings.json new file mode 100644 index 0000000..5e97f83 --- /dev/null +++ b/Unity-Package/ProjectSettings/SceneTemplateSettings.json @@ -0,0 +1,121 @@ +{ + "templatePinStates": [], + "dependencyTypeInfos": [ + { + "userAdded": false, + "type": "UnityEngine.AnimationClip", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEditor.Animations.AnimatorController", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEngine.AnimatorOverrideController", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEditor.Audio.AudioMixerController", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEngine.ComputeShader", + "defaultInstantiationMode": 1 + }, + { + "userAdded": false, + "type": "UnityEngine.Cubemap", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEngine.GameObject", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEditor.LightingDataAsset", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEngine.LightingSettings", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEngine.Material", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEditor.MonoScript", + "defaultInstantiationMode": 1 + }, + { + "userAdded": false, + "type": "UnityEngine.PhysicMaterial", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEngine.PhysicsMaterial2D", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEngine.Rendering.PostProcessing.PostProcessProfile", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEngine.Rendering.PostProcessing.PostProcessResources", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEngine.Rendering.VolumeProfile", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEditor.SceneAsset", + "defaultInstantiationMode": 1 + }, + { + "userAdded": false, + "type": "UnityEngine.Shader", + "defaultInstantiationMode": 1 + }, + { + "userAdded": false, + "type": "UnityEngine.ShaderVariantCollection", + "defaultInstantiationMode": 1 + }, + { + "userAdded": false, + "type": "UnityEngine.Texture", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEngine.Texture2D", + "defaultInstantiationMode": 0 + }, + { + "userAdded": false, + "type": "UnityEngine.Timeline.TimelineAsset", + "defaultInstantiationMode": 0 + } + ], + "defaultDependencyTypeInfo": { + "userAdded": false, + "type": "", + "defaultInstantiationMode": 1 + }, + "newSceneOverride": 0 +} \ No newline at end of file From 61f4d310b4fe029596b9a576e05bf81696c874d7 Mon Sep 17 00:00:00 2001 From: Ivan Murzak Date: Sun, 5 Jul 2026 14:07:45 -0700 Subject: [PATCH 5/6] Create CLAUDE.md --- CLAUDE.md | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 CLAUDE.md diff --git a/CLAUDE.md b/CLAUDE.md new file mode 100644 index 0000000..bd9c329 --- /dev/null +++ b/CLAUDE.md @@ -0,0 +1,57 @@ +# CLAUDE.md + +This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository. + +## Repository shape: two Unity projects + one shippable package + +This repo is not a single Unity project. It contains **two independent Unity projects** plus the library source that one of them ships: + +- **`Unity-Package/`** — the Unity project used to develop and test the actual **Image Loader** library. The distributable package is the subfolder `Unity-Package/Assets/root/` (its own `package.json`, published to OpenUPM as `extensions.unity.imageloader`). Everything else under `Unity-Package/` (ProjectSettings, Library, .sln/.csproj) is Unity scaffolding, not shipped. **All library tests run against this project** (`projectPath: ./Unity-Package`). See `Unity-Package/CLAUDE.md` for the library's internal architecture. +- **`Installer/`** — a *separate* Unity project whose only job is to export a `.unitypackage` ("ImageLoader-Installer") that adds the OpenUPM scoped registry to a consumer's `manifest.json`. Entry point `Installer/Assets/com.IvanMurzak/Image Loader Installer/Installer.cs` runs at editor load (`[InitializeOnLoad]`) and injects the registry; `PackageExporter.ExportPackage` builds the `.unitypackage`. It carries its own `Version` constant that must match the package version. +- **`docs/`**, **`README.md`**, **`bump-version.ps1`**, **`.github/`** — repo-level assets shared by both projects. + +When editing library code you almost always work in `Unity-Package/Assets/root/`; the `Installer/` project is only touched for install/registry logic. + +## Versioning (must stay in sync across two files) + +The package version lives in **two** places that are kept identical: + +- `Unity-Package/Assets/root/package.json` → `"version"` +- `Installer/Assets/com.IvanMurzak/Image Loader Installer/Installer.cs` → `public const string Version` + +Never edit these by hand independently. Use the script, which updates both atomically: + +```powershell +./bump-version.ps1 -NewVersion "7.1.0" # apply +./bump-version.ps1 -NewVersion "7.1.0" -WhatIf # preview without writing +``` + +## Testing + +Tests are Unity Test Framework (NUnit) tests inside `Unity-Package/`, split across three assemblies: + +- `Tests/Base/` (`Extensions.Unity.ImageLoader.Tests`) — shared utilities, no tests +- `Tests/Editor/` (`…Tests.Editor`) — EditMode +- `Tests/Runtime/` (`…Tests.Runtime`) — PlayMode + +**Run locally:** open the `Unity-Package` project → Window → General → Test Runner → *EditMode* / *PlayMode* tab. Run a single test by selecting it in that tree (there is no CLI-single-test shortcut short of Unity batch mode `-runTests -testFilter`). + +### Test network is faked, not real +The library issues web requests through the injectable `IWebRequestProvider` (`ImageLoader.settings.webRequestProvider`, default `DefaultWebRequestProvider`). Tests swap in `MockWebRequestProvider`, which routes every URL to an **in-process localhost HTTP server** (`TestHttpServer`) instead of the public internet — this is what makes image-loading tests deterministic. Wiring lives in `Tests/Base/Utils/TestUtils.cs`: + +- `TestUtils.BeginHold(url)` / `ReleaseHeld(url)` — park a request in-flight on the server so "cancel-while-loading" states are reproducible. Always pair them. +- Registered URLs resolve to a fast local image; unregistered URLs hit the server's slow route so client-side timeouts fire predictably. + +If you add a test that loads an image, register/route it through `TestUtils` — do not point it at a real remote URL. + +### Headless-CI caveat +Finalizer/GC-driven reference-cleanup tests are non-deterministic under Unity's conservative collector in `-batchmode`. `TestUtils` skips them when `Application.isBatchMode` is true (they still run in the interactive Editor Test Runner). Don't "fix" such a test by forcing it to run headless — verify it in the Editor. + +## CI + +Reusable workflow `.github/workflows/test_unity_plugin.yml` runs the Unity Test Runner for one `(unityVersion, testMode)` across a platform matrix (`base`, `windows-mono`) on ubuntu Docker images. + +- **`test_pull_request.yml`** fans that out over Unity 2019.4 → 6000.0 in both `editmode` and `playmode`. +- **`release.yml`** (on tag) runs the full matrix, then signs & packs the UPM tarball (`upm pack` from `Unity-Package/Assets/root`) and exports the Installer `.unitypackage` (Installer project pinned to Unity 2021.3.45f1). + +PRs from forks run with `pull_request_target` and require the **`ci-ok`** label; the workflow aborts if a PR also edits files under `.github/workflows/` (secrets safety). From e76a0a535313ec812c7170d0333fef3a40d473f2 Mon Sep 17 00:00:00 2001 From: Ivan Murzak Date: Sun, 5 Jul 2026 14:40:32 -0700 Subject: [PATCH 6/6] fix(ci): remove stray Unity MCP + AI Navigation packages from test project The Unity-Package project manifest had accidentally picked up com.ivanmurzak.unity.mcp (0.17.2) and com.unity.ai.navigation (1.1.5) plus the whole MCP NuGet/SignalR scoped-registry chain. Neither is a dependency of the Image Loader library, and both fail to compile on the older editors in the test matrix: - com.unity.ai.navigation@1.1.5: CS1061 NavMeshSurface.IsPartOfPrefab - com.ivanmurzak.unity.mcp@0.17.2: CS0246 EnumField / IntegerField "Scripts have compiler errors" made Unity exit before running any test, so every 2019/2020/2021/2022 job failed at compilation (2023.1+ passed because the newer API exists there). Restore Packages/manifest.json, packages-lock.json and PackageManagerSettings.asset to main's known-good clean state. Co-Authored-By: Claude Opus 4.8 (1M context) --- Unity-Package/Packages/manifest.json | 70 +- Unity-Package/Packages/packages-lock.json | 731 ------------------ .../PackageManagerSettings.asset | 91 +-- 3 files changed, 19 insertions(+), 873 deletions(-) diff --git a/Unity-Package/Packages/manifest.json b/Unity-Package/Packages/manifest.json index 224f03f..9b8761e 100644 --- a/Unity-Package/Packages/manifest.json +++ b/Unity-Package/Packages/manifest.json @@ -1,7 +1,6 @@ { "dependencies": { "com.cysharp.unitask": "2.5.10", - "com.unity.ai.navigation": "1.1.5", "com.unity.ext.nunit": "2.0.5", "com.unity.ide.visualstudio": "2.0.23", "com.unity.test-framework": "1.4.6", @@ -14,8 +13,7 @@ "com.unity.modules.unitywebrequestassetbundle": "1.0.0", "com.unity.modules.unitywebrequestaudio": "1.0.0", "com.unity.modules.unitywebrequesttexture": "1.0.0", - "com.unity.modules.unitywebrequestwww": "1.0.0", - "com.ivanmurzak.unity.mcp": "0.17.2" + "com.unity.modules.unitywebrequestwww": "1.0.0" }, "scopedRegistries": [ { @@ -23,70 +21,8 @@ "url": "https://package.openupm.com", "scopes": [ "com.cysharp.unitask", - "com.ivanmurzak.unity.mcp", - "com.openupm", - "extensions.unity.playerprefsex", - "org.nuget.microsoft.aspnetcore.connections.abstractions", - "org.nuget.microsoft.aspnetcore.http.connections.client", - "org.nuget.microsoft.aspnetcore.http.connections.common", - "org.nuget.microsoft.aspnetcore.signalr.client", - "org.nuget.microsoft.aspnetcore.signalr.client.core", - "org.nuget.microsoft.aspnetcore.signalr.common", - "org.nuget.microsoft.aspnetcore.signalr.protocols.json", - "org.nuget.microsoft.bcl.asyncinterfaces", - "org.nuget.microsoft.bcl.memory", - "org.nuget.microsoft.bcl.timeprovider", - "org.nuget.microsoft.codeanalysis.analyzers", - "org.nuget.microsoft.codeanalysis.common", - "org.nuget.microsoft.codeanalysis.csharp", - "org.nuget.microsoft.extensions.caching.abstractions", - "org.nuget.microsoft.extensions.configuration", - "org.nuget.microsoft.extensions.configuration.abstractions", - "org.nuget.microsoft.extensions.configuration.binder", - "org.nuget.microsoft.extensions.configuration.commandline", - "org.nuget.microsoft.extensions.configuration.environmentvariables", - "org.nuget.microsoft.extensions.configuration.fileextensions", - "org.nuget.microsoft.extensions.configuration.json", - "org.nuget.microsoft.extensions.configuration.usersecrets", - "org.nuget.microsoft.extensions.dependencyinjection", - "org.nuget.microsoft.extensions.dependencyinjection.abstractions", - "org.nuget.microsoft.extensions.diagnostics", - "org.nuget.microsoft.extensions.diagnostics.abstractions", - "org.nuget.microsoft.extensions.features", - "org.nuget.microsoft.extensions.fileproviders.abstractions", - "org.nuget.microsoft.extensions.fileproviders.physical", - "org.nuget.microsoft.extensions.filesystemglobbing", - "org.nuget.microsoft.extensions.hosting", - "org.nuget.microsoft.extensions.hosting.abstractions", - "org.nuget.microsoft.extensions.logging", - "org.nuget.microsoft.extensions.logging.abstractions", - "org.nuget.microsoft.extensions.logging.configuration", - "org.nuget.microsoft.extensions.logging.console", - "org.nuget.microsoft.extensions.logging.debug", - "org.nuget.microsoft.extensions.logging.eventlog", - "org.nuget.microsoft.extensions.logging.eventsource", - "org.nuget.microsoft.extensions.options", - "org.nuget.microsoft.extensions.options.configurationextensions", - "org.nuget.microsoft.extensions.primitives", - "org.nuget.r3", - "org.nuget.system.buffers", - "org.nuget.system.collections.immutable", - "org.nuget.system.componentmodel.annotations", - "org.nuget.system.diagnostics.diagnosticsource", - "org.nuget.system.diagnostics.eventlog", - "org.nuget.system.io.pipelines", - "org.nuget.system.memory", - "org.nuget.system.net.serversentevents", - "org.nuget.system.numerics.vectors", - "org.nuget.system.reflection.metadata", - "org.nuget.system.runtime.compilerservices.unsafe", - "org.nuget.system.security.principal.windows", - "org.nuget.system.text.encoding.codepages", - "org.nuget.system.text.encodings.web", - "org.nuget.system.text.json", - "org.nuget.system.threading.channels", - "org.nuget.system.threading.tasks.extensions" + "com.openupm" ] } ] -} \ No newline at end of file +} diff --git a/Unity-Package/Packages/packages-lock.json b/Unity-Package/Packages/packages-lock.json index ffc80cd..19056c8 100644 --- a/Unity-Package/Packages/packages-lock.json +++ b/Unity-Package/Packages/packages-lock.json @@ -7,37 +7,6 @@ "dependencies": {}, "url": "https://package.openupm.com" }, - "com.ivanmurzak.unity.mcp": { - "version": "0.17.2", - "depth": 0, - "source": "registry", - "dependencies": { - "com.unity.test-framework": "1.1.33", - "com.unity.modules.uielements": "1.0.0", - "extensions.unity.playerprefsex": "2.0.2", - "org.nuget.microsoft.bcl.memory": "9.0.7", - "org.nuget.microsoft.aspnetcore.signalr.client": "9.0.7", - "org.nuget.microsoft.aspnetcore.signalr.protocols.json": "9.0.7", - "org.nuget.microsoft.codeanalysis.csharp": "4.13.0", - "org.nuget.microsoft.extensions.caching.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.hosting": "9.0.7", - "org.nuget.microsoft.extensions.hosting.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", - "org.nuget.r3": "1.3.0", - "org.nuget.system.text.json": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "com.unity.ai.navigation": { - "version": "1.1.5", - "depth": 0, - "source": "registry", - "dependencies": { - "com.unity.modules.ai": "1.0.0" - }, - "url": "https://packages.unity.com" - }, "com.unity.ext.nunit": { "version": "2.0.5", "depth": 0, @@ -74,696 +43,6 @@ "com.unity.modules.imgui": "1.0.0" } }, - "extensions.unity.playerprefsex": { - "version": "2.0.2", - "depth": 1, - "source": "registry", - "dependencies": {}, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.aspnetcore.connections.abstractions": { - "version": "9.0.7", - "depth": 3, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.features": "9.0.7", - "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", - "org.nuget.system.io.pipelines": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.aspnetcore.http.connections.client": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.aspnetcore.http.connections.common": "9.0.7", - "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.options": "9.0.7", - "org.nuget.system.net.serversentevents": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.aspnetcore.http.connections.common": { - "version": "9.0.7", - "depth": 3, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.aspnetcore.connections.abstractions": "9.0.7", - "org.nuget.system.text.json": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.aspnetcore.signalr.client": { - "version": "9.0.7", - "depth": 1, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.aspnetcore.signalr.client.core": "9.0.7", - "org.nuget.microsoft.aspnetcore.http.connections.client": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.aspnetcore.signalr.client.core": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.aspnetcore.signalr.protocols.json": "9.0.7", - "org.nuget.microsoft.aspnetcore.signalr.common": "9.0.7", - "org.nuget.microsoft.bcl.timeprovider": "9.0.7", - "org.nuget.microsoft.extensions.dependencyinjection": "9.0.7", - "org.nuget.microsoft.extensions.logging": "9.0.7", - "org.nuget.system.threading.channels": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.aspnetcore.signalr.common": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.aspnetcore.connections.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.options": "9.0.7", - "org.nuget.system.text.json": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.aspnetcore.signalr.protocols.json": { - "version": "9.0.7", - "depth": 1, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.aspnetcore.signalr.common": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.bcl.asyncinterfaces": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.system.threading.tasks.extensions": "4.5.4" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.bcl.memory": { - "version": "9.0.7", - "depth": 1, - "source": "registry", - "dependencies": { - "org.nuget.system.memory": "4.5.5", - "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.bcl.timeprovider": { - "version": "9.0.7", - "depth": 3, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.codeanalysis.analyzers": { - "version": "3.11.0", - "depth": 2, - "source": "registry", - "dependencies": {}, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.codeanalysis.common": { - "version": "4.13.0", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.codeanalysis.analyzers": "3.11.0", - "org.nuget.system.collections.immutable": "8.0.0", - "org.nuget.system.memory": "4.5.5", - "org.nuget.system.reflection.metadata": "8.0.0", - "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0", - "org.nuget.system.text.encoding.codepages": "7.0.0", - "org.nuget.system.threading.tasks.extensions": "4.5.4", - "org.nuget.system.buffers": "4.5.1", - "org.nuget.system.numerics.vectors": "4.5.0" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.codeanalysis.csharp": { - "version": "4.13.0", - "depth": 1, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.codeanalysis.common": "4.13.0", - "org.nuget.microsoft.codeanalysis.analyzers": "3.11.0", - "org.nuget.system.buffers": "4.5.1", - "org.nuget.system.collections.immutable": "8.0.0", - "org.nuget.system.memory": "4.5.5", - "org.nuget.system.numerics.vectors": "4.5.0", - "org.nuget.system.reflection.metadata": "8.0.0", - "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0", - "org.nuget.system.text.encoding.codepages": "7.0.0", - "org.nuget.system.threading.tasks.extensions": "4.5.4" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.caching.abstractions": { - "version": "9.0.7", - "depth": 1, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.primitives": "9.0.7", - "org.nuget.system.threading.tasks.extensions": "4.5.4" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.configuration": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.primitives": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.configuration.abstractions": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.primitives": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.configuration.binder": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.configuration.commandline": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.configuration": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.configuration.environmentvariables": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.configuration": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.configuration.fileextensions": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.configuration": "9.0.7", - "org.nuget.microsoft.extensions.fileproviders.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.fileproviders.physical": "9.0.7", - "org.nuget.microsoft.extensions.primitives": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.configuration.json": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.configuration.fileextensions": "9.0.7", - "org.nuget.microsoft.extensions.configuration": "9.0.7", - "org.nuget.microsoft.extensions.fileproviders.abstractions": "9.0.7", - "org.nuget.system.text.json": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.configuration.usersecrets": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.configuration.json": "9.0.7", - "org.nuget.microsoft.extensions.fileproviders.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.fileproviders.physical": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.dependencyinjection": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", - "org.nuget.system.threading.tasks.extensions": "4.5.4" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": { - "version": "9.0.7", - "depth": 1, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", - "org.nuget.system.threading.tasks.extensions": "4.5.4" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.diagnostics": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.configuration": "9.0.7", - "org.nuget.microsoft.extensions.diagnostics.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.options.configurationextensions": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.diagnostics.abstractions": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.options": "9.0.7", - "org.nuget.system.diagnostics.diagnosticsource": "9.0.7", - "org.nuget.system.buffers": "4.5.1", - "org.nuget.system.memory": "4.5.5" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.features": { - "version": "9.0.7", - "depth": 4, - "source": "registry", - "dependencies": {}, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.fileproviders.abstractions": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.primitives": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.fileproviders.physical": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.fileproviders.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.filesystemglobbing": "9.0.7", - "org.nuget.microsoft.extensions.primitives": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.filesystemglobbing": { - "version": "9.0.7", - "depth": 3, - "source": "registry", - "dependencies": {}, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.hosting": { - "version": "9.0.7", - "depth": 1, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", - "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.configuration.binder": "9.0.7", - "org.nuget.microsoft.extensions.configuration.commandline": "9.0.7", - "org.nuget.microsoft.extensions.configuration.environmentvariables": "9.0.7", - "org.nuget.microsoft.extensions.configuration.fileextensions": "9.0.7", - "org.nuget.microsoft.extensions.configuration.json": "9.0.7", - "org.nuget.microsoft.extensions.configuration.usersecrets": "9.0.7", - "org.nuget.microsoft.extensions.configuration": "9.0.7", - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.dependencyinjection": "9.0.7", - "org.nuget.microsoft.extensions.diagnostics": "9.0.7", - "org.nuget.microsoft.extensions.fileproviders.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.fileproviders.physical": "9.0.7", - "org.nuget.microsoft.extensions.hosting.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging.configuration": "9.0.7", - "org.nuget.microsoft.extensions.logging.console": "9.0.7", - "org.nuget.microsoft.extensions.logging.debug": "9.0.7", - "org.nuget.microsoft.extensions.logging.eventlog": "9.0.7", - "org.nuget.microsoft.extensions.logging.eventsource": "9.0.7", - "org.nuget.microsoft.extensions.logging": "9.0.7", - "org.nuget.microsoft.extensions.options": "9.0.7", - "org.nuget.system.threading.tasks.extensions": "4.5.4" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.hosting.abstractions": { - "version": "9.0.7", - "depth": 1, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", - "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.diagnostics.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.fileproviders.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", - "org.nuget.system.threading.tasks.extensions": "4.5.4" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.logging": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", - "org.nuget.microsoft.extensions.dependencyinjection": "9.0.7", - "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.options": "9.0.7", - "org.nuget.system.diagnostics.diagnosticsource": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.logging.abstractions": { - "version": "9.0.7", - "depth": 1, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", - "org.nuget.system.diagnostics.diagnosticsource": "9.0.7", - "org.nuget.system.buffers": "4.5.1", - "org.nuget.system.memory": "4.5.5" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.logging.configuration": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.configuration.binder": "9.0.7", - "org.nuget.microsoft.extensions.configuration": "9.0.7", - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging": "9.0.7", - "org.nuget.microsoft.extensions.options.configurationextensions": "9.0.7", - "org.nuget.microsoft.extensions.options": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.logging.console": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging.configuration": "9.0.7", - "org.nuget.microsoft.extensions.logging": "9.0.7", - "org.nuget.microsoft.extensions.options": "9.0.7", - "org.nuget.system.text.json": "9.0.7", - "org.nuget.system.buffers": "4.5.1" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.logging.debug": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.logging.eventlog": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging": "9.0.7", - "org.nuget.microsoft.extensions.options": "9.0.7", - "org.nuget.system.diagnostics.eventlog": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.logging.eventsource": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.logging": "9.0.7", - "org.nuget.microsoft.extensions.options": "9.0.7", - "org.nuget.microsoft.extensions.primitives": "9.0.7", - "org.nuget.system.text.json": "9.0.7", - "org.nuget.system.memory": "4.5.5", - "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.options": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.primitives": "9.0.7", - "org.nuget.system.componentmodel.annotations": "5.0.0" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.options.configurationextensions": { - "version": "9.0.7", - "depth": 3, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.extensions.configuration.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.configuration.binder": "9.0.7", - "org.nuget.microsoft.extensions.dependencyinjection.abstractions": "9.0.7", - "org.nuget.microsoft.extensions.options": "9.0.7", - "org.nuget.microsoft.extensions.primitives": "9.0.7" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.microsoft.extensions.primitives": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.system.memory": "4.5.5", - "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.r3": { - "version": "1.3.0", - "depth": 1, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.bcl.timeprovider": "8.0.0", - "org.nuget.system.buffers": "4.5.1", - "org.nuget.system.componentmodel.annotations": "5.0.0", - "org.nuget.system.memory": "4.5.5", - "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0", - "org.nuget.system.threading.channels": "8.0.0" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.system.buffers": { - "version": "4.5.1", - "depth": 2, - "source": "registry", - "dependencies": {}, - "url": "https://package.openupm.com" - }, - "org.nuget.system.collections.immutable": { - "version": "8.0.0", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.system.memory": "4.5.5", - "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.system.componentmodel.annotations": { - "version": "5.0.0", - "depth": 2, - "source": "registry", - "dependencies": {}, - "url": "https://package.openupm.com" - }, - "org.nuget.system.diagnostics.diagnosticsource": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.system.memory": "4.5.5", - "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.system.diagnostics.eventlog": { - "version": "9.0.7", - "depth": 3, - "source": "registry", - "dependencies": { - "org.nuget.system.security.principal.windows": "5.0.0" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.system.io.pipelines": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.system.buffers": "4.5.1", - "org.nuget.system.memory": "4.5.5", - "org.nuget.system.threading.tasks.extensions": "4.5.4" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.system.memory": { - "version": "4.5.5", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.system.buffers": "4.5.1", - "org.nuget.system.numerics.vectors": "4.4.0", - "org.nuget.system.runtime.compilerservices.unsafe": "4.5.3" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.system.net.serversentevents": { - "version": "9.0.7", - "depth": 3, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", - "org.nuget.system.memory": "4.5.5", - "org.nuget.system.threading.tasks.extensions": "4.5.4" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.system.numerics.vectors": { - "version": "4.5.0", - "depth": 2, - "source": "registry", - "dependencies": {}, - "url": "https://package.openupm.com" - }, - "org.nuget.system.reflection.metadata": { - "version": "8.0.0", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.system.collections.immutable": "8.0.0", - "org.nuget.system.memory": "4.5.5" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.system.runtime.compilerservices.unsafe": { - "version": "6.0.0", - "depth": 2, - "source": "registry", - "dependencies": {}, - "url": "https://package.openupm.com" - }, - "org.nuget.system.security.principal.windows": { - "version": "5.0.0", - "depth": 4, - "source": "registry", - "dependencies": {}, - "url": "https://package.openupm.com" - }, - "org.nuget.system.text.encoding.codepages": { - "version": "7.0.0", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.system.memory": "4.5.5", - "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.system.text.encodings.web": { - "version": "9.0.7", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.system.buffers": "4.5.1", - "org.nuget.system.memory": "4.5.5", - "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.system.text.json": { - "version": "9.0.7", - "depth": 1, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", - "org.nuget.system.io.pipelines": "9.0.7", - "org.nuget.system.text.encodings.web": "9.0.7", - "org.nuget.system.buffers": "4.5.1", - "org.nuget.system.memory": "4.5.5", - "org.nuget.system.runtime.compilerservices.unsafe": "6.0.0", - "org.nuget.system.threading.tasks.extensions": "4.5.4" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.system.threading.channels": { - "version": "9.0.7", - "depth": 3, - "source": "registry", - "dependencies": { - "org.nuget.microsoft.bcl.asyncinterfaces": "9.0.7", - "org.nuget.system.threading.tasks.extensions": "4.5.4" - }, - "url": "https://package.openupm.com" - }, - "org.nuget.system.threading.tasks.extensions": { - "version": "4.5.4", - "depth": 2, - "source": "registry", - "dependencies": { - "org.nuget.system.runtime.compilerservices.unsafe": "4.5.3" - }, - "url": "https://package.openupm.com" - }, - "com.unity.modules.ai": { - "version": "1.0.0", - "depth": 1, - "source": "builtin", - "dependencies": {} - }, "com.unity.modules.assetbundle": { "version": "1.0.0", "depth": 1, @@ -800,16 +79,6 @@ "source": "builtin", "dependencies": {} }, - "com.unity.modules.uielements": { - "version": "1.0.0", - "depth": 1, - "source": "builtin", - "dependencies": { - "com.unity.modules.ui": "1.0.0", - "com.unity.modules.imgui": "1.0.0", - "com.unity.modules.jsonserialize": "1.0.0" - } - }, "com.unity.modules.unitywebrequest": { "version": "1.0.0", "depth": 0, diff --git a/Unity-Package/ProjectSettings/PackageManagerSettings.asset b/Unity-Package/ProjectSettings/PackageManagerSettings.asset index d9068da..06b7936 100644 --- a/Unity-Package/ProjectSettings/PackageManagerSettings.asset +++ b/Unity-Package/ProjectSettings/PackageManagerSettings.asset @@ -12,11 +12,7 @@ MonoBehaviour: m_Script: {fileID: 13964, guid: 0000000000000000e000000000000000, type: 0} m_Name: m_EditorClassIdentifier: - m_EnablePreReleasePackages: 0 - m_AdvancedSettingsExpanded: 1 m_ScopedRegistriesSettingsExpanded: 1 - m_SeeAllPackageVersions: 0 - m_DismissPreviewPackagesInUse: 0 oneTimeWarningShown: 0 m_Registries: - m_Id: main @@ -24,84 +20,29 @@ MonoBehaviour: m_Url: https://packages.unity.com m_Scopes: [] m_IsDefault: 1 - m_Capabilities: 7 - m_ConfigSource: 0 - - m_Id: scoped:project:package.openupm.com + - m_Id: scoped:package.openupm.com m_Name: package.openupm.com m_Url: https://package.openupm.com m_Scopes: - com.cysharp.unitask - - com.ivanmurzak.unity.mcp - com.openupm - - extensions.unity.playerprefsex - - org.nuget.microsoft.aspnetcore.connections.abstractions - - org.nuget.microsoft.aspnetcore.http.connections.client - - org.nuget.microsoft.aspnetcore.http.connections.common - - org.nuget.microsoft.aspnetcore.signalr.client - - org.nuget.microsoft.aspnetcore.signalr.client.core - - org.nuget.microsoft.aspnetcore.signalr.common - - org.nuget.microsoft.aspnetcore.signalr.protocols.json - - org.nuget.microsoft.bcl.asyncinterfaces - - org.nuget.microsoft.bcl.memory - - org.nuget.microsoft.bcl.timeprovider - - org.nuget.microsoft.codeanalysis.analyzers - - org.nuget.microsoft.codeanalysis.common - - org.nuget.microsoft.codeanalysis.csharp - - org.nuget.microsoft.extensions.caching.abstractions - - org.nuget.microsoft.extensions.configuration - - org.nuget.microsoft.extensions.configuration.abstractions - - org.nuget.microsoft.extensions.configuration.binder - - org.nuget.microsoft.extensions.configuration.commandline - - org.nuget.microsoft.extensions.configuration.environmentvariables - - org.nuget.microsoft.extensions.configuration.fileextensions - - org.nuget.microsoft.extensions.configuration.json - - org.nuget.microsoft.extensions.configuration.usersecrets - - org.nuget.microsoft.extensions.dependencyinjection - - org.nuget.microsoft.extensions.dependencyinjection.abstractions - - org.nuget.microsoft.extensions.diagnostics - - org.nuget.microsoft.extensions.diagnostics.abstractions - - org.nuget.microsoft.extensions.features - - org.nuget.microsoft.extensions.fileproviders.abstractions - - org.nuget.microsoft.extensions.fileproviders.physical - - org.nuget.microsoft.extensions.filesystemglobbing - - org.nuget.microsoft.extensions.hosting - - org.nuget.microsoft.extensions.hosting.abstractions - - org.nuget.microsoft.extensions.logging - - org.nuget.microsoft.extensions.logging.abstractions - - org.nuget.microsoft.extensions.logging.configuration - - org.nuget.microsoft.extensions.logging.console - - org.nuget.microsoft.extensions.logging.debug - - org.nuget.microsoft.extensions.logging.eventlog - - org.nuget.microsoft.extensions.logging.eventsource - - org.nuget.microsoft.extensions.options - - org.nuget.microsoft.extensions.options.configurationextensions - - org.nuget.microsoft.extensions.primitives - - org.nuget.r3 - - org.nuget.system.buffers - - org.nuget.system.collections.immutable - - org.nuget.system.componentmodel.annotations - - org.nuget.system.diagnostics.diagnosticsource - - org.nuget.system.diagnostics.eventlog - - org.nuget.system.io.pipelines - - org.nuget.system.memory - - org.nuget.system.net.serversentevents - - org.nuget.system.numerics.vectors - - org.nuget.system.reflection.metadata - - org.nuget.system.runtime.compilerservices.unsafe - - org.nuget.system.security.principal.windows - - org.nuget.system.text.encoding.codepages - - org.nuget.system.text.encodings.web - - org.nuget.system.text.json - - org.nuget.system.threading.channels - - org.nuget.system.threading.tasks.extensions m_IsDefault: 0 - m_Capabilities: 0 - m_ConfigSource: 4 m_UserSelectedRegistryName: package.openupm.com m_UserAddingNewScopedRegistry: 0 m_RegistryInfoDraft: - m_Modified: 0 m_ErrorMessage: - m_UserModificationsInstanceId: -834 - m_OriginalInstanceId: -838 - m_LoadAssets: 0 + m_Original: + m_Id: scoped:package.openupm.com + m_Name: package.openupm.com + m_Url: https://package.openupm.com + m_Scopes: + - com.cysharp.unitask + - com.openupm + m_IsDefault: 0 + m_Modified: 0 + m_Name: package.openupm.com + m_Url: https://package.openupm.com + m_Scopes: + - com.cysharp.unitask + - com.openupm + m_SelectedScopeIndex: 0