Class: Xcodeproj::Project
- Inherits:
-
Object
- Object
- Xcodeproj::Project
- Defined in:
- lib/ext/group.rb,
lib/ext/project.rb,
lib/ext/native_target.rb
Defined Under Namespace
Modules: Object
Instance Method Summary collapse
- #app_scheme ⇒ Object
- #app_scheme_name ⇒ Object
- #app_target ⇒ Object
- #debug_build_configuration ⇒ Object
- #name ⇒ Object
- #release_build_configuration ⇒ Object
- #spec_target ⇒ Object
- #wk_app_target ⇒ Object
- #wk_ext_target ⇒ Object
Instance Method Details
#app_scheme ⇒ Object
49 50 51 |
# File 'lib/ext/project.rb', line 49 def app_scheme scheme_for_scheme_name(app_scheme_name) end |
#app_scheme_name ⇒ Object
40 41 42 43 44 45 46 47 |
# File 'lib/ext/project.rb', line 40 def app_scheme_name scheme_name = RSwift::Configuration.new.app_scheme_name schemes_names = Xcodeproj::Project.schemes(path) scheme_name ||= schemes_names.find do |scheme_name| is_app_scheme(scheme_for_scheme_name(scheme_name)) end scheme_name end |
#app_target ⇒ Object
24 25 26 |
# File 'lib/ext/project.rb', line 24 def app_target targets.find { |target| target.product_type.eql? Xcodeproj::Constants::PRODUCT_TYPE_UTI[:application] } end |
#debug_build_configuration ⇒ Object
8 9 10 11 12 13 14 |
# File 'lib/ext/project.rb', line 8 def debug_build_configuration build_configuration_name = RSwift::Configuration.new.debug_build_configuration build_configuration_name ||= RSwift::Constants::CONFIGURATION_PROPERTIES[:debug][:name] build_configurations.find do |build_configuration| build_configuration.name.eql? build_configuration_name end end |
#name ⇒ Object
4 5 6 |
# File 'lib/ext/project.rb', line 4 def name path.dirname.split.last.to_s end |
#release_build_configuration ⇒ Object
16 17 18 19 20 21 22 |
# File 'lib/ext/project.rb', line 16 def release_build_configuration build_configuration_name = RSwift::Configuration.new.release_build_configuration build_configuration_name ||= RSwift::Constants::CONFIGURATION_PROPERTIES[:release][:name] build_configurations.find do |build_configuration| build_configuration.name.eql? build_configuration_name end end |
#spec_target ⇒ Object
28 29 30 |
# File 'lib/ext/project.rb', line 28 def spec_target targets.find { |target| target.product_type.eql? Xcodeproj::Constants::PRODUCT_TYPE_UTI[:unit_test_bundle] } end |
#wk_app_target ⇒ Object
32 33 34 |
# File 'lib/ext/project.rb', line 32 def wk_app_target targets.find { |target| target.product_type.eql? Xcodeproj::Constants::PRODUCT_TYPE_UTI[:watch2_app] } end |
#wk_ext_target ⇒ Object
36 37 38 |
# File 'lib/ext/project.rb', line 36 def wk_ext_target targets.find { |target| target.product_type.eql? Xcodeproj::Constants::PRODUCT_TYPE_UTI[:watch2_extension] } end |