Class: Fastlane::Helper::Unity3dHelper
- Inherits:
-
Object
- Object
- Fastlane::Helper::Unity3dHelper
- Defined in:
- lib/fastlane/plugin/unity3d/helper/unity3d_helper.rb
Class Method Summary collapse
-
.default_exe_path ⇒ Object
class methods that you define here become available in your action as ‘Helper::Unity3dHelper.your_method`.
Class Method Details
.default_exe_path ⇒ Object
class methods that you define here become available in your action as ‘Helper::Unity3dHelper.your_method`
github.com/safu9/fastlane-plugin-unity/blob/main/lib/fastlane/plugin/unity/helper/unity_helper.rb
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
# File 'lib/fastlane/plugin/unity3d/helper/unity3d_helper.rb', line 12 def self.default_exe_path paths = [] if OS::Underlying.docker? # See: https://gitlab.com/gableroux/unity3d paths << "/opt/Unity/Editor/Unity" end if OS.windows? paths << "C:\\Program Files\\Unity\\Editor\\Unity.exe" elsif OS.mac? paths << "/Applications/Unity/Unity.app/Contents/MacOS/Unity" paths << Dir[File.join('Applications', '**', 'Unity.app', 'Contents', 'MacOS', 'Unity')] elsif OS.linux? paths << "~/Unity/Editor/Unity" end return paths.find { |path| File.exist?(path) } end |