-
-
Notifications
You must be signed in to change notification settings - Fork 11.2k
dnclient 0.9.0 (new cask) #239468
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
base: main
Are you sure you want to change the base?
dnclient 0.9.0 (new cask) #239468
Conversation
This PR adds DNClient Desktop.app, from https://www.defined.net/downloads
| livecheck do | ||
| url "https://api.defined.net/v1/downloads" | ||
| regex(/^v?(\d+(?:\.\d+)+)$/i) | ||
| strategy :json do |json, regex| | ||
| json.dig("data", "dnclient")&.filter_map do |version, downloads| | ||
| next if version == "latest" | ||
| next unless downloads.key?("macos-universal-desktop") | ||
| next unless version.match?(regex) | ||
|
|
||
| version[regex, 1] | ||
| end | ||
| end | ||
| end |
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.
| livecheck do | |
| url "https://api.defined.net/v1/downloads" | |
| regex(/^v?(\d+(?:\.\d+)+)$/i) | |
| strategy :json do |json, regex| | |
| json.dig("data", "dnclient")&.filter_map do |version, downloads| | |
| next if version == "latest" | |
| next unless downloads.key?("macos-universal-desktop") | |
| next unless version.match?(regex) | |
| version[regex, 1] | |
| end | |
| end | |
| end | |
| livecheck do | |
| url "https://api.defined.net/v1/downloads" | |
| strategy :json do |json| | |
| json.dig("data", "versionInfo", "latest", "dnclient") | |
| end | |
| end |
We might be able to simplify the livecheck by querying the versionInfo rather than the download URLs.
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.
The only issue is that the download url changes both due to the version change, and due to the git sha as a folder prefix
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.
Thanks, I skipped over that part. We will have to capture the Git SHA as well since it changes with each version.
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.
Ok, I think I've got it.
Co-authored-by: Klaus Hipp <[email protected]>
This PR adds DNClient Desktop.app, from https://www.defined.net/downloads
Important: Do not tick a checkbox if you haven’t performed its action. Honesty is indispensable for a smooth review process.
In the following questions
<cask>is the token of the cask you're submitting.After making any changes to a cask, existing or new, verify:
brew audit --cask --online <cask>is error-free.brew style --fix <cask>reports no offenses.Additionally, if adding a new cask:
brew audit --cask --new <cask>worked successfully.HOMEBREW_NO_INSTALL_FROM_API=1 brew install --cask <cask>worked successfully.brew uninstall --cask <cask>worked successfully.