UnityPackageManager is a Unity editor tool for inspecting .unitypackage archives before import.
It adds a window at Tools > Orbiters > UnityPackageManager where you can:
.unitypackageThis package is split into:
Runtime: public models and interfaces other tools can callEditor: archive reader/extractor implementation and the editor windowArchives are read through Orbiters Toolkit’s UnityPackageReader, the one .unitypackage reader every Orbiters tool
shares, so UnityPackageManager requires Orbiters Toolkit 0.3.19 or newer (installed with it through the Creator
Companion). Since 0.2.0 it refuses archives that are not well-formed Unity packages: a broken tar header checksum, a
record name that is not <32 hex GUID>/pathname|asset|asset.meta|preview.png, a repeated record, two GUIDs for one asset
path, an asset without a pathname, metadata naming another GUID, or a missing tar terminator. A pathname’s first line is
its path, as in Unity’s importer.
Tools > Orbiters > UnityPackageManager..unitypackage file with Browse....Import Selected to extract into the chosen destination folderDragging from the tool window into the Project window imports the selected files directly into the target folder.
Preserve Package Hierarchy is enabled for button import, the original package folder layout is preserved under the destination folder...) are never written; UnityPackageManager lists them after the import.Other editor tools can use the public API to inspect or extract package contents:
using Orbiters.UnityPackageManager;
using UnityEditor;
var archive = UnityPackageManagerApi.ReadArchive(@"C:\Downloads\Example.unitypackage");
foreach (var asset in archive.Assets)
{
Debug.Log($"{asset.AssetName} | {asset.OriginalAssetPath} | {asset.AssetSizeBytes} bytes");
}
UnityPackageManagerApi.ExtractAssets(
@"C:\Downloads\Example.unitypackage",
archive.Assets.Take(2).Select(a => a.OriginalAssetPath),
"Assets/Imported",
new UnityPackageImportOptions
{
PreservePackageHierarchy = true,
OverwriteExistingFiles = false
});
IUnityPackageReaderIUnityPackageExtractorUnityPackageManagerApiUnityPackageArchiveInfoUnityPackageAssetInfoUnityPackageImportOptionsThis folder is initialized as its own git repository so it can be versioned independently from the main Unity project.
orbiters.unitypackagemanager
Undefined
0.2.0
2022.3 or later
No dependencies
No legacy packages
Undefined