-
Copy the files in the
.github/workflows
folder to your repository -
Run Generate Activation License File workflow to create a license request file (.alf)
-
Use that .alf file to generate a Unity license file (.ulf) from Unity
-
Encode a download license file and save it to a repository's secrets (
UNITY_ULF
)base64 < /Users/pokeum/Downloads/Unity_v2022.x.ulf | pbcopy
-
Specify which assets should be included in a Unity Package (.unitypackage) using
.unitypackage_exports
file# Include Script Assets/MyPackage/Include # Include Scene Assets/Scenes/IncludeScene.unity
-
Customize and use the
unity-packaging.yml
file to fit your project environmentyour-repository-name --> Unity project root ├── .github | └── workflows ├── Assets | ├── Scenes | ├── Scripts | ├── ... ├── .unitypackage_exports ├── ...
If the root folder of your GitHub repository and the root folder of your Unity project are the same,
change the unity-packaging.yml file as shown below:jobs: unity-packaging: ... env: ... UNITY_PROJECT_PATH: ${{ '.' }}
-
Run Unity Packaging workflow to create unity package
You can customize your Git workflow to ensure that a merge event triggers the release stage and automatically run unity packaging workflow
→ Download artifact and unzip it
unzip /Users/pokeum/Downloads/mypackage-0.0.0.zip