File tree Expand file tree Collapse file tree 2 files changed +19
-1
lines changed
OneSignalExample/Assets/OneSignalPackager/Editor Expand file tree Collapse file tree 2 files changed +19
-1
lines changed Original file line number Diff line number Diff line change 5757 with :
5858 version : 2021.3.0f1
5959
60+ - uses : buildalon/activate-unity-license@v2
61+ with :
62+ license : ' Personal'
63+ username : ' ${{ secrets.UNITY_USERNAME }}'
64+ password : ' ${{ secrets.UNITY_PASSWORD }}'
65+
6066 - name : Verify Unity install
6167 run : |
6268 UNITY_PATH=$(find /home/runner -type f -name Unity | grep "Editor/Unity" | head -n 1)
Original file line number Diff line number Diff line change @@ -49,9 +49,21 @@ public static void ExportUnityPackage()
4949 var packageVersion = File . ReadAllText ( VersionFilePath ) ;
5050 var packageName = $ "OneSignal-v{ packageVersion } .unitypackage";
5151
52+ // detect CLI argument for exportPath
53+ string [ ] args = System . Environment . GetCommandLineArgs ( ) ;
54+ string exportPathArg = args . FirstOrDefault ( a => a . StartsWith ( "exportPath=" ) ) ;
55+
56+ string exportPath =
57+ exportPathArg != null
58+ ? exportPathArg . Split ( '=' ) [ 1 ]
59+ : Path . Combine ( Directory . GetCurrentDirectory ( ) , packageName ) ;
60+
61+ if ( ! exportPath . EndsWith ( ".unitypackage" ) )
62+ exportPath = Path . Combine ( exportPath , packageName ) ;
63+
5264 AssetDatabase . ExportPackage (
5365 _filePaths ( ) ,
54- packageName ,
66+ exportPath ,
5567 ExportPackageOptions . Recurse | ExportPackageOptions . IncludeDependencies
5668 ) ;
5769 }
You can’t perform that action at this time.
0 commit comments