-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hash scope suffixes if they are over 50 characters #5608
Conversation
👍🏻 |
29502ef
to
2e4cf9b
Compare
I don't think we should hash the full label. Just hashing the scope suffix should be sufficient. I can push a PR for that later today. |
@mrackwitz I can update this PR pretty easily. TBH tho, I don't think we'd really get much of an advantage by doing that? |
2e4cf9b
to
531b61b
Compare
@mrackwitz Updated |
@@ -121,7 +123,6 @@ To install release candidates run `[sudo] gem install cocoapods --pre` | |||
[Simon Warta](https://github.com/webmaster128) | |||
[#5595](https://github.com/CocoaPods/CocoaPods/pull/5595) | |||
|
|||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this second line should be here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oops, happened during the rebase, fixing now.
3bcf153
to
011762f
Compare
Build is failing because json is refusing to build on system ruby, but tests are passing elsewhere. |
Thanks for updating the PR, @dantoml. 😀 diff --git a/lib/cocoapods/installer/analyzer/pod_variant_set.rb b/lib/cocoapods/installer/analyzer/pod_variant_set.rb
index b758c31..fd7dc3a 100644
--- a/lib/cocoapods/installer/analyzer/pod_variant_set.rb
+++ b/lib/cocoapods/installer/analyzer/pod_variant_set.rb
@@ -23,7 +23,10 @@ module Pod
#
def scope_suffixes
return { variants.first => nil } if variants.count == 1
- scope_by_specs
+ Hash[scope_by_specs.map do |variant, scope|
+ scope = Digest::MD5.hexdigest(scope)[0..7] if scope.length > 100
+ [variant, scope]
+ end]
end
# Groups the collection by result of the block. You might want to take over at least the cropping of the hash to 8 chars? |
011762f
to
d85a341
Compare
@mrackwitz Updated |
👍 |
@dantoml question about this (sorry if commenting on a closed PR isn't the place but I'm not sure where else to ask): if I want during post_install what target name from the pod's project represents which original PodTarget name, do I have any way of doing so? |
supersedes CocoaPods/Core#344
actually closes #5491