Skip to content

Conversation

@courier-new
Copy link
Contributor

@courier-new courier-new commented Oct 14, 2022

This is the initial, simpler solution to #862 which assumes we continue to publish src-cli the way we typically have, i.e. only ever releasing a new latest version. It assumes that the newer a tag is, the later the version is. This is absolutely not a good assumption to make most of the time, however it turns out to be remarkably realistic for our repository. With the exception of the 4.0.0-rc release, we have not had a patch release on an older major version since March of 2020.

It adds a goreleaser-pre step which:

  • Fetches the current/new and previous version tags
  • Converts the current "main" formula in the Homebrew tap repository into a versioned formula

It then lets goreleaser run like normal, which will update the main Homebrew formula.

It then also adds a goreleaser-post step which:

  • Updates the symlink for the new latest version

Test plan

  • Set up fork of Homebrew tap repo as if 4.0.1 was the latest release (main formula is for 4.0.1, versioned formulas up to 4.0.0, symlink for 4.0.1)
  • Update GH action to skip goreleaser step (don't want to actually publish anything new), point pre and post steps at fork repo
  • Trigger action
  • Observed expected results (main formula is converted into versioned formula, symlink for 4.0.2, no other side effects)

@courier-new courier-new self-assigned this Oct 14, 2022
@courier-new
Copy link
Contributor Author

Closing as superseded by #864.

@keegancsmith keegancsmith deleted the kr/automate-version-publishing branch November 11, 2025 20:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants