Skip to content

Avoid upgrade notice for recent release if gh is under Homebrew prefix#3020

Merged
mislav merged 1 commit intotrunkfrom
brew-upgrade-notice
Feb 23, 2021
Merged

Avoid upgrade notice for recent release if gh is under Homebrew prefix#3020
mislav merged 1 commit intotrunkfrom
brew-upgrade-notice

Conversation

@mislav
Copy link
Contributor

@mislav mislav commented Feb 23, 2021

Before, when gh detected there was a new release in the cli/cli repo, it would show this notice to both Homebrew and non-Homebrew users:

A new release of gh is available: {V1} → {V2}

Additionally, when the release was more than 24h old, we would show this to Homebrew users:

To upgrade, run: brew update && brew upgrade gh

This change makes it so that the original notice A new release of gh is available is not shown to Homebrew users unless the release is older than 24h. We effectively hide the fact that any release happened until we're sure that the version bump has made it to homebrew-core.

Followup to #2929

Before, when gh detected there was a new release in the `cli/cli` repo,
it would show this notice:

    A new release of gh is available: {V1} → {V2}

Additionally, when the release was more than 24h old, we would show this
to Homebrew users:

    To upgrade, run: brew update && brew upgrade gh

Ref. feb4acc

This change makes it so that the original notice "A new release of gh is
available" is NOT shown to Homebrew users unless the release is older
than 24h. We effectively hide the fact that any release happened until
we're sure that the version bump has made it to `homebrew-core`.
@mislav mislav requested a review from a team February 23, 2021 11:27
@mislav mislav merged commit 98df059 into trunk Feb 23, 2021
@mislav mislav deleted the brew-upgrade-notice branch February 23, 2021 20:05
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