Skip to content
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

[packager] Custom download strategy for homebrew #1555

Closed
aalmiray opened this issue Dec 15, 2023 Discussed in #1554 · 3 comments
Closed

[packager] Custom download strategy for homebrew #1555

aalmiray opened this issue Dec 15, 2023 Discussed in #1554 · 3 comments
Assignees
Labels
enhancement New feature or request released Issue has been released
Milestone

Comments

@aalmiray
Copy link
Member

Discussed in #1554

Originally posted by jonnybbb December 15, 2023
I would like to use a custom download strategy for downloading the artefacts.

require_relative "lib/private"
.....
  if OS.linux? && Hardware::CPU.intel?
    URL "<url>", using: GitHubPrivateRepositoryReleaseDownloadStrategy
    sha256 "<sha>"
  end
  if OS.mac? && Hardware::CPU.arm?
    url "<url>", using: GitHubPrivateRepositoryReleaseDownloadStrategy
    sha256 "<sha>"
  end

Is there a way to configure this in jReleaser?

goreleaser has this:

    # Allows you to set a custom download strategy. Note that you'll need
    # to implement the strategy and add it to your tap repository.
    # Example: https://docs.brew.sh/Formula-Cookbook#specifying-the-download-strategy-explicitly
    download_strategy: CurlDownloadStrategy

    # Allows you to add a custom require_relative at the top of the formula
    # template.
    custom_require: custom_download_strategy
@aalmiray aalmiray added the enhancement New feature or request label Dec 15, 2023
@aalmiray aalmiray added this to the v1.10.0 milestone Dec 15, 2023
@aalmiray aalmiray self-assigned this Dec 15, 2023
aalmiray added a commit to jreleaser/jreleaser.github.io that referenced this issue Dec 15, 2023
@jonnybbb
Copy link

Thanks @aalmiray for tackling it so quickly

@aalmiray
Copy link
Member Author

You can try this feature using the early-access builds of the CLI.

aalmiray added a commit to jreleaser/jreleaser.github.io that referenced this issue Dec 23, 2023
@aalmiray
Copy link
Member Author

🎉 This issue has been resolved in v1.10.0 (Release Notes)

@aalmiray aalmiray added the released Issue has been released label Dec 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request released Issue has been released
Projects
None yet
Development

No branches or pull requests

2 participants