Module: ProjectGen::ProductHelper
- Included in:
- Product
- Defined in:
- lib/cocoapods-project-gen/gen/product/product_helper.rb
Instance Method Summary collapse
- #build_as_framework? ⇒ Boolean
- #build_as_library? ⇒ Boolean
- #file_accessors ⇒ Object
- #label ⇒ Object
- #module_basename ⇒ Object
- #pod_dir ⇒ Object
- #pod_name ⇒ Object
- #product_name ⇒ Object
- #product_path ⇒ Object
- #product_type ⇒ Object
- #root_spec ⇒ Object
- #sandbox ⇒ Object
- #scope_suffix ⇒ Object
- #static_library_name ⇒ Object
- #uses_swift? ⇒ Boolean
- #version ⇒ Object
- #xcframework_name ⇒ Object
- #xcframework_product_name ⇒ Object
- #xcframework_product_path ⇒ Object
Instance Method Details
#build_as_framework? ⇒ Boolean
45 46 47 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 45 def build_as_framework? target.build_as_framework? end |
#build_as_library? ⇒ Boolean
37 38 39 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 37 def build_as_library? target.build_as_library? end |
#file_accessors ⇒ Object
65 66 67 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 65 def file_accessors target.file_accessors end |
#label ⇒ Object
20 21 22 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 20 def label target.label end |
#module_basename ⇒ Object
49 50 51 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 49 def module_basename Pod::Specification.root_name(pod_name) end |
#pod_dir ⇒ Object
32 33 34 35 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 32 def pod_dir root_name = module_basename sandbox.sources_root + root_name end |
#pod_name ⇒ Object
57 58 59 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 57 def pod_name target.pod_name end |
#product_name ⇒ Object
53 54 55 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 53 def product_name target.product_name end |
#product_path ⇒ Object
85 86 87 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 85 def product_path product_root.join("#{module_basename}-#{product_type}-#{version}") end |
#product_type ⇒ Object
61 62 63 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 61 def product_type target.product_type end |
#root_spec ⇒ Object
81 82 83 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 81 def root_spec target.root_spec end |
#sandbox ⇒ Object
69 70 71 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 69 def sandbox target.sandbox end |
#scope_suffix ⇒ Object
24 25 26 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 24 def scope_suffix target.scope_suffix end |
#static_library_name ⇒ Object
28 29 30 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 28 def static_library_name "lib#{Utils.remove_target_scope_suffix(label, scope_suffix)}.a" end |
#uses_swift? ⇒ Boolean
41 42 43 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 41 def uses_swift? target.uses_swift? end |
#version ⇒ Object
16 17 18 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 16 def version root_spec.version end |
#xcframework_name ⇒ Object
77 78 79 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 77 def xcframework_name pod_name end |
#xcframework_product_name ⇒ Object
73 74 75 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 73 def xcframework_product_name "#{xcframework_name}.xcframework" end |
#xcframework_product_path ⇒ Object
89 90 91 |
# File 'lib/cocoapods-project-gen/gen/product/product_helper.rb', line 89 def xcframework_product_path product_path.join(xcframework_product_name) end |