Skip to content

Commit

Permalink
adjusted Rakefile about UNITY path.
Browse files Browse the repository at this point in the history
  • Loading branch information
KojiNakamaru committed Jul 11, 2023
1 parent 8b673d2 commit eac59fc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions build/Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

require 'fileutils'

UNITY="/Applications/UnityCurrent/Unity.app/Contents"
UNITY="/Applications/Unity/Hub/Editor/2019.4.40f1/Unity.app/Contents/MacOS/Unity"

CNT = 2
SRCDIR = Array.new(CNT);
Expand Down Expand Up @@ -76,7 +76,7 @@ end

desc "pack"
task :pack do
sh "#{UNITY}/MacOS/Unity -projectPath `pwd`/Packager -batchmode -quit -executeMethod Packager.Export -logFile LOG"
sh "#{UNITY} -projectPath `pwd`/Packager -batchmode -quit -executeMethod Packager.Export -logFile LOG"
FileUtils.mv "Packager/unity-webview.unitypackage", "../dist"
sh "(cd Packager; rm -f ../../dist/unity-webview.zip; zip -qr9 ../../dist/unity-webview.zip `find Assets/Plugins -type f` `find Assets/WebGLTemplates -type f` `find Assets/WebPlayerTemplates -type f`)"
sh "(cd ../dist/package; rm -rf Assets; unzip -q ../unity-webview.zip; git checkout Assets/Plugins.meta; git checkout Assets/WebGLTemplates.meta; git checkout Assets/WebPlayerTemplates.meta)"
Expand All @@ -94,7 +94,7 @@ end

desc "packnofragment"
task :packnofragment do
sh "#{UNITY}/MacOS/Unity -projectPath `pwd`/Packager -batchmode -quit -executeMethod Packager.Export -logFile LOG"
sh "#{UNITY} -projectPath `pwd`/Packager -batchmode -quit -executeMethod Packager.Export -logFile LOG"
FileUtils.mv "Packager/unity-webview.unitypackage", "../dist/unity-webview-nofragment.unitypackage"
sh "(cd Packager; rm -f ../../dist/unity-webview-nofragment.zip; zip -qr9 ../../dist/unity-webview-nofragment.zip `find Assets/Plugins -type f` `find Assets/WebGLTemplates -type f` `find Assets/WebPlayerTemplates -type f`)"
sh "(cd ../dist/package-nofragment; rm -rf Assets; unzip -q ../unity-webview-nofragment.zip; git checkout Assets/Plugins.meta; git checkout Assets/WebGLTemplates.meta; git checkout Assets/WebPlayerTemplates.meta)"
Expand Down

0 comments on commit eac59fc

Please sign in to comment.