Support pods project/target regeneration when incremental_installation is enabled: in the preinstall the plugin checks if the XCRemoteCache changes for disabled -> enabled. If so, it forces Pods project/targets regeneration by deleting the previous cache model, provided by the sandbox class (e.g. Pods/.project_cache/installation_cache.yaml). Removing this file has to happen in the preinstall, before the cache invalidation is inspected.
This PR moves also some essential xcrc cocoapods plugin steps (like downloading XCRC binaries from the Internet) from post-install to preinstall because these are needed to discriminate if the remote cache is enabled/disabled.
How to test?
Install first the project with no artifacts. Sample Podfile:
Support pods project/target regeneration when
incremental_installation
is enabled: in the preinstall the plugin checks if the XCRemoteCache changes for disabled -> enabled. If so, it forces Pods project/targets regeneration by deleting the previous cache model, provided by the sandbox class (e.g.Pods/.project_cache/installation_cache.yaml
). Removing this file has to happen in the preinstall, before the cache invalidation is inspected.This PR moves also some essential xcrc cocoapods plugin steps (like downloading XCRC binaries from the Internet) from post-install to preinstall because these are needed to discriminate if the remote cache is enabled/disabled.
How to test?
plugin 'cocoapods-xcremotecache'
xcremotecache({ 'cache_addresses' => ['http://localhost:8080/cache/pods'], 'primary_repo' => '.', 'mode' => 'consumer' })
target 'Generate' do
Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
pod 'Firebase/Analytics' pod 'ReactiveSwift' end