Repository navigation
Brew Upgrade GH doesnt initiate upgrade #299
Description
Activity
Version at https://github.com/github/homebrew-gh/blob/7f18e38ff44aabd8d2e61cdcde5c2eef43081c03/Formula/gh.rb#L4-L11 still shows
0.5.2.This commit github/homebrew-gh@f1814e9 created a new
gh.rbfile at the root of the repo with version0.5.3. Butgh.rbfile should be inFormuladirectory.oof, seems like it got broken in the recent clean-up. i'll look at it today.
- addedpriority-1Affects a large population and inhibits workAffects a large population and inhibits work
on Feb 4, 2020 Thanks for the fix
Reacted by Nate SmithHi I'm getting a similar error when I use brew on mac to upgrade gh:
brew upgrade gh
Warning: gh 2.5.1 already installedhow did you fix this?
@ptn77 gh 2.5.1 is already the latest available GitHub CLI version.
@mislav sorry. I tried to run git init -b main and it's not recognizing the switch 'b', so I thought maybe I didn't have the correct version. I'm seeing a version 2.32.0 is needed?
If you wanted to update
git, then you should have runbrew upgrade gitand notbrew upgrade gh. Note thatgitandghare different command-line tools.For
git init -b, you will need git 2.28 or higher.For what it's worth: on an Ubuntu system I had the same problem. It appeared a second instance was installed through apt which was out of date.
sudo apt remove ghand then abrew reinstall ghdid the trick.- added a commit that references this issue
on Jul 21, 2025
Describe the bug
I am trying to update the CLI on mac using the brew update && brew upgrade gh command however it is giving me a message with
Warning: github/gh/gh 0.5.2 already installed
Not sure what needs to be done to update to 0.5.3
Steps to reproduce the behavior
Expected vs actual behavior
I expected it to initiate an update using homebrew
Logs
==> Tapping github/gh
Cloning into '/usr/local/Homebrew/Library/Taps/github/homebrew-gh'...
remote: Enumerating objects: 34, done.
remote: Counting objects: 100% (34/34), done.
remote: Compressing objects: 100% (27/27), done.
remote: Total 166 (delta 8), reused 0 (delta 0), pack-reused 132
Receiving objects: 100% (166/166), 29.61 KiB | 2.47 MiB/s, done.
Resolving deltas: 100% (41/41), done.
Tapped 1 formula (28 files, 61.1KB).
==> Installing gh from github/gh
==> Downloading https://github.com/github/homebrew-gh/releases/download/v0.5.2/gh_0.5.2_macOS_amd64.tar.gz
==> Downloading from https://github-production-release-asset-2e65be.s3.amazonaws.com/212587282/a8165500-42ae-11ea-8d73-a12edaa54824?X-Amz-Algorithm=AW
######################################################################## 100.0%
A new release of gh is available: 0.5.2 → v0.5.3
https://github.com/cli/cli/releases/tag/v0.5.3
A new release of gh is available: 0.5.2 → v0.5.3
https://github.com/cli/cli/releases/tag/v0.5.3
==> Caveats
Bash completion has been installed to:
/usr/local/etc/bash_completion.d
zsh completions have been installed to:
/usr/local/share/zsh/site-functions
==> Summary
🍺 /usr/local/Cellar/gh/0.5.2: 8 files, 13.4MB, built in 11 seconds
brew update && brew upgrade gh
Already up-to-date.
Warning: github/gh/gh 0.5.2 already installed