lmorg / murex

A smarter shell and scripting environment with advanced features designed for usability, safety and productivity (eg smarter DevOps tooling)
https://murex.rocks
GNU General Public License v2.0
1.5k stars 27 forks source link

Enable installation via Homebrew #355

Closed cglong closed 3 years ago

cglong commented 3 years ago

Hi, I'd like to use murex via Homebrew, but Homebrew requires a stable version number. I see murex already has version numbers (e.g. #347). Would it be possible to add Git tags corresponding to the defined release numbers so GitHub can publish the related source tarballs?

lmorg commented 3 years ago

Hi @cglong

I already have pre-compiled binaries for all supported platforms available to download here: https://murex.rocks/DOWNLOAD.html The links on there will not change in name and will always be the latest release (intentionally done this way to aid in any automation someone might want).

Historic versions are also kept around on a public S3 bucket in case anyone wants to download a specific version, but I don't as yet have an index page for that.

These are automatically updated as part of the CI/CD build so that's my preferred way of distributing the application, with the code on Github being more aimed for developers. However if Homebrew needs to work off git tags then I can look into adding that to the build pipeline too. Let me know :)

cglong commented 3 years ago

Thank you for the detailed response and for your willingness to explore this 🙂 I realized I slightly misspoke earlier; Homebrew itself doesn't have such a requirement. However, there are a few requirements for inclusion into homebrew-core:

Given your reply above, I can see a few possible approaches here:

lmorg commented 3 years ago

@cglong Thanks for the detail. By the sounds of it your original suggestion is the more painless path forward.

I want to do a little bit of reading about Homebrew first though, just to confirm some behaviours, before I create the tagging. Just to make sure I get it right and don't mess people about once the target has been created.

cglong commented 3 years ago

That makes total sense! Thank you again for investigating this 🙂 Let me know if there's anything I might be able to clear up or help out with!

lmorg commented 3 years ago

Hi @cglong

Read through the docs and one thing isn't clear to me: version upgrades. How do they work in practice?

  1. In the event of bug fix releases, would I create a v{major}.{minor}.{release} tag and each new release would have a new tag? Or would I create a v{major}.{minor} with each release owning the aforementioned tag (like with latest in Docker).
  2. How does Homebrew pick up new versions? Is that a PR on their github page? I see there is a SHA1 of the tarball in the package description so I'm guessing there's a manual process involved?

btw Thank you for helping me out with this process too. :)

cglong commented 3 years ago

For sure! Happy to help however I can 🙂

  1. Each release needs a unique tag, so in your example, you'd have both a v2.0.0 and a v2.0.1 tag.
  2. Yeah, ultimately new versions come in the form of GitHub PRs. The maintainers have a lot of automation in place though to help with this; the two I'm aware of are brew livecheck and brew bump-formula-pr.
lmorg commented 3 years ago

Awesome, thank you.

I've created a new release in Github: https://github.com/lmorg/murex/releases/tag/v2.2.1200 Looks like the tarballs are there now too.

cglong commented 3 years ago

Awesome, thank you!! I'll try to spin up a first pass at a formula in the next few days 🙂

cglong commented 3 years ago

Small update: I've written a formula that builds murex and verified that it works 🎉 Next step is to write an appropriate test block and submit the PR for review!

lmorg commented 3 years ago

Excellent work. Thanks for the update

cglong commented 3 years ago

This is done! 🚀 You should now be able to install murex with:

brew install murex

Thank you again for all your help! Feel free to tag me if you or any users have any issues with using it via Homebrew 😄

lmorg commented 3 years ago

That's fantastic. Thank you very much. I'll update the install instructions