Class: PodPrebuild::PreInstallHook
- Inherits:
-
Object
- Object
- PodPrebuild::PreInstallHook
- Includes:
- ObjectSpace
- Defined in:
- lib/cocoapods-binary-ht/hooks/pre_install.rb
Instance Attribute Summary collapse
-
#cache_validation ⇒ Object
readonly
Returns the value of attribute cache_validation.
-
#installer_context ⇒ Object
readonly
Returns the value of attribute installer_context.
-
#podfile ⇒ Object
readonly
Returns the value of attribute podfile.
-
#prebuild_sandbox ⇒ Object
readonly
Returns the value of attribute prebuild_sandbox.
-
#standard_sandbox ⇒ Object
readonly
Returns the value of attribute standard_sandbox.
Instance Method Summary collapse
-
#initialize(installer_context) ⇒ PreInstallHook
constructor
A new instance of PreInstallHook.
- #run ⇒ Object
Constructor Details
#initialize(installer_context) ⇒ PreInstallHook
Returns a new instance of PreInstallHook.
7 8 9 10 11 12 13 14 |
# File 'lib/cocoapods-binary-ht/hooks/pre_install.rb', line 7 def initialize(installer_context) @installer_context = installer_context @podfile = installer_context.podfile @pod_install_options = {} @prebuild_sandbox = nil @standard_sandbox = installer_context.sandbox @cache_validation = nil end |
Instance Attribute Details
#cache_validation ⇒ Object (readonly)
Returns the value of attribute cache_validation.
5 6 7 |
# File 'lib/cocoapods-binary-ht/hooks/pre_install.rb', line 5 def cache_validation @cache_validation end |
#installer_context ⇒ Object (readonly)
Returns the value of attribute installer_context.
5 6 7 |
# File 'lib/cocoapods-binary-ht/hooks/pre_install.rb', line 5 def installer_context @installer_context end |
#podfile ⇒ Object (readonly)
Returns the value of attribute podfile.
5 6 7 |
# File 'lib/cocoapods-binary-ht/hooks/pre_install.rb', line 5 def podfile @podfile end |
#prebuild_sandbox ⇒ Object (readonly)
Returns the value of attribute prebuild_sandbox.
5 6 7 |
# File 'lib/cocoapods-binary-ht/hooks/pre_install.rb', line 5 def prebuild_sandbox @prebuild_sandbox end |
#standard_sandbox ⇒ Object (readonly)
Returns the value of attribute standard_sandbox.
5 6 7 |
# File 'lib/cocoapods-binary-ht/hooks/pre_install.rb', line 5 def standard_sandbox @standard_sandbox end |
Instance Method Details
#run ⇒ Object
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 |
# File 'lib/cocoapods-binary-ht/hooks/pre_install.rb', line 16 def run return if @installer_context.sandbox.is_a?(Pod::PrebuildSandbox) log_section "🚀 Prebuild frameworks" ensure_valid_podfile save_installation_states create_prebuild_sandbox Pod::UI.title("Detect implicit dependencies") { detect_implicit_dependencies } Pod::UI.title("Validate prebuilt cache") { validate_cache } prebuild! if PodPrebuild.config.prebuild_job? PodPrebuild::Env.next_stage! prepare_for_integration log_section "🤖 Resume pod installation" require_relative "../pod-binary/integration" end |