-
-
Notifications
You must be signed in to change notification settings - Fork 10.1k
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
Fix :svn download errors with :latest casks #13358
Conversation
Library/Homebrew/cask/cask.rb
Outdated
@@ -129,19 +129,26 @@ def config_path | |||
metadata_main_container_path/"config.json" | |||
end | |||
|
|||
def checksumable? | |||
url.using.nil? || url.using == :post |
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.
I believe once #13232 we can change this to.
But until #13232 is merged this will result in an error.
@MikeMcQuaid Could we merge without support and include the changes in the other PR? I'm not sure on the status quo here.
url.using.nil? || url.using == :post | |
(url.using.nil? && url.only_paths.nil?) || url.using == :post |
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.
Let's just merge what will work for now assuming that #13232 isn't merged or at least gracefully handling it.
url.using.nil? || url.using == :post | |
url.using.blank? || url.using == :post |
or
url.using.nil? || url.using == :post | |
(url.using.blank? && url.only_paths.blank?) || url.using == :post |
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.
For now it'll need to be
url.using.nil? || url.using == :post | |
url.using.blank? || url.using == :post |
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.
Fine as-is if it'll work, otherwise pick one of the suggestions and then 👍🏻 to merge.
Library/Homebrew/cask/cask.rb
Outdated
@@ -129,19 +129,26 @@ def config_path | |||
metadata_main_container_path/"config.json" | |||
end | |||
|
|||
def checksumable? | |||
url.using.nil? || url.using == :post |
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.
Let's just merge what will work for now assuming that #13232 isn't merged or at least gracefully handling it.
url.using.nil? || url.using == :post | |
url.using.blank? || url.using == :post |
or
url.using.nil? || url.using == :post | |
(url.using.blank? && url.only_paths.blank?) || url.using == :post |
d2f6add
to
6f06236
Compare
Okay, I updated |
Thanks again @apainintheneck! |
brew style
with your changes locally?brew typecheck
with your changes locally?brew tests
with your changes locally?Note: This is an alternative solution to #13354.
This only computes the sha256 for
version :latest
casks that don't use the subversion download method. Currently with Casks there are three allowed download types.From what I can see both Curl download methods require single compressed files which can be hashed. From the documentation:
URL to the .dmg/.zip/.tgz/.tbz2 file that contains the application.
That requirement apparently doesn't exist for Subversion downloads so I added a
Cask#checksumable?
method that checks if the url is using either of the Curl methods. This should still work with #13232 assuming that is given a differentusing
directive.Fixes #13359.