69 reported that for development_pods some absolute dependency paths sneak into meta .json file and thus degrade the hit rate.
I looked at how CocoaPods generates development_pods project and it has a unique setup:
SRCROOT is equal to ./Pods
All sources are references within a group that has ".." in it.
It is a documented requirement of XCRemoteCache to always reference files within SRCROOT. On the other hand, CocoaPods provide PODS_TARGET_SRCROOT, which points (indirectly) to the development_pod src root:
69 reported that for
development_pods
some absolute dependency paths sneak into meta .json file and thus degrade the hit rate.I looked at how CocoaPods generates development_pods project and it has a unique setup:
SRCROOT
is equal to./Pods
SRCROOT
. On the other hand, CocoaPods providePODS_TARGET_SRCROOT
, which points (indirectly) to the development_pod src root:The idea is to add
PODS_TARGET_SRCROOT
into all EVNs that could be rewritten in the dependency identification.This PR introduces that:
custom_rewrite_envs
that allows extendingDependenciesMapping.rewrittenEnvs
(requested also in #59)How to test?
Use the sample project shared in #69: https://github.com/dwirandyh/xcremotecache-modular-example Add into Podfile's xcremotecache configuration:
Verify no absolute paths in the
User
development_pod's json.