If running Linux or WSL, there are some pre-requisite packages to install. You can set HOMEBREWBREWGITREMOTE and/or HOMEBREWCOREGITREMOTE in your shell environment to use geolocalized Git mirrors to speed up Homebrew's installation with this script and, after installation, brew update. The most significant changes since 2.2.0 are GitHub Actions CI usage, fetching resources before installation, Docker image improvements and the deprecation of brew install from URLs. Major changes and deprecations since 2.2.0: brew tap-pin and brew tap-unpin have been removed along with the deprecation of some Homebrew and Formula methods. Homebrew’s package index. Installs (30 days) git: 255,122: git -HEAD: 31: git -HEAD -with-blk-sha1 -with-curl. Homebrew is a member of the Software Freedom Conservancy. Homebrew is generously supported by Substack, GitHub, Randy Reddig, embark-studios, Realist.ai and many other users and organisations via GitHub Sponsors.
Instructions for a supported install of Homebrew are on the homepage.
This script installs Homebrew to its preferred prefix (
/usr/local
for macOS Intel, /opt/homebrew
for Apple Silicon) so thatyou don’t need sudo when youbrew install
. It is a careful script; it can be run even if you have stuffinstalled in /usr/local
already. It tells you exactly what it will do beforeit does it too. You have to confirm everything it will do before it starts.macOS Requirements
- A 64-bit Intel CPU or Apple Silicon CPU 1
- macOS Mojave (10.14) (or higher) 2
- Command Line Tools (CLT) for Xcode:
xcode-select --install
,developer.apple.com/downloads orXcode3 - A Bourne-compatible shell for installation (e.g.
bash
orzsh
) 4
Git Remote Mirroring
You can set
HOMEBREW_BREW_GIT_REMOTE
and/or HOMEBREW_CORE_GIT_REMOTE
in your shell environment to use geolocalized Git mirrors to speed up Homebrew’s installation with this script and, after installation, brew update
.The default Git remote will be used if the corresponding environment variable is unset.
Alternative Installs
Linux or Windows 10 Subsystem for Linux
Brew Github 2020
Check out the Homebrew on Linux installation documentation.
Untar anywhere
Brew Github Login
Just extract (or
git clone
) Homebrew wherever you want. Just avoid:- Directories with names that contain spaces. Homebrew itself can handle spaces, but many build scripts cannot.
/tmp
subdirectories because Homebrew gets upset./sw
and/opt/local
because build scripts get confused when Homebrew is there instead of Fink or MacPorts, respectively.
![Brew Brew](/uploads/1/1/8/1/118186076/280080000.png)
However do yourself a favour and install to
/usr/local
on macOS Intel, /opt/homebrew
on macOS ARM,and /home/linuxbrew/.linuxbrew
on Linux. Some things maynot build when installed elsewhere. One of the reasons Homebrew justworks relative to the competition is because we recommend installinghere. Pick another prefix at your peril!Multiple installations
Create a Homebrew installation wherever you extract the tarball. Whichever
brew
command is called is where the packages will be installed. You can use this as you see fit, e.g. a system set of libs in /usr/local
and tweaked formulae for development in ~/homebrew
.Uninstallation
Uninstallation is documented in the FAQ.
1 For 32-bit or PPC support seeTigerbrew.
2 10.14 or higher is recommended. 10.9–10.13 aresupported on a best-effort basis. For 10.4-10.6 seeTigerbrew.
3 Most formulae require a compiler. A handfulrequire a full Xcode installation. You can install Xcode, the CLT, or both;Homebrew supports all three configurations. Downloading Xcode may require anApple Developer account on older versions of Mac OS X. Sign up for freehere.
4 The one-liner installation method found onbrew.sh requires a Bourne-compatible shell (e.g. bash orzsh). Notably, fish, tcsh and csh will not work.
$gh issue listShowing 4 of 4 issues in cli/cli
#16Improving interactions with protected branches
#14PR commands on a detached head
#13Support for GitHub Enterprise (enhancement)
#8Add an easier upgrade command (bug)
Relevant pull requests in cli/cli
Current branch
There is no pull request associated with [fix-homepage-bug]
Created by you
You have no open pull requests
Requesting a code review from you
#100Fix footer on homepage[fix-homepage-footer]
✓ Checks passing- Review pending
remote: Enumerating objects: 66, done.
remote: Counting objects: 100% (66/66), done.
remote: Total 83 (delta 66), reused 66 (delta 66), pack-reused 17
Unpacking objects: 100% (83/83), done.
From https://github.com/owner/repo
* [new ref] refs/pull/8896/head -> patch-2
M README.md
Switched to branch 'patch-2'
gh pr createremote: Counting objects: 100% (66/66), done.
remote: Total 83 (delta 66), reused 66 (delta 66), pack-reused 17
Unpacking objects: 100% (83/83), done.
From https://github.com/owner/repo
* [new ref] refs/pull/8896/head -> patch-2
M README.md
Switched to branch 'patch-2'
Homebrew Github Actions
Creating pull request for feature-branch into main in ampinsk/test
? Title My new pull request
? Body [(e) to launch vim, enter to skip]
? What's next? Submit
http://github.com/owner/repo/pull/1
![Github Github](/uploads/1/1/8/1/118186076/318347418.jpg)
Homebrew
All checks were successful
1 failing, 3 successful, and 1 pending checks
-CodeQL3m43shttps://github.com/cli/cli/runs/123
✓build (macos-latest)4m18shttps://github.com/cli/cli/runs/123
✓build (ubuntu-latest)1m23shttps://github.com/cli/cli/runs/123
✓build (windows-latest)4m43shttps://github.com/cli/cli/runs/123
×lint47shttps://github.com/cli/cli/runs/123
gh release create 1.01 failing, 3 successful, and 1 pending checks
-CodeQL3m43shttps://github.com/cli/cli/runs/123
✓build (macos-latest)4m18shttps://github.com/cli/cli/runs/123
✓build (ubuntu-latest)1m23shttps://github.com/cli/cli/runs/123
✓build (windows-latest)4m43shttps://github.com/cli/cli/runs/123
×lint47shttps://github.com/cli/cli/runs/123
? Title GitHub CLI 1.0
? Release notes Write my own
? Is this a prerelease? No
? Submit? Publish release
https://github.com/octocat/.github/releases/tag/1.0
gh repo view? Release notes Write my own
? Is this a prerelease? No
? Submit? Publish release
https://github.com/octocat/.github/releases/tag/1.0
cli/cli
GitHub’s official command line tool
GitHub CLI
gh is GitHub on the command line. It brings pull requests, issues, and other GitHub concepts to the terminal next to where you are already working with git and your code.
Image: screenshot of gh pr status →https://user-images.githubusercontent.com/98482/84171218-327e7a80-aa40-11ea-8cd1-5177fc2d0e72.png
View this repository on GitHub: https://github.com/cli/cli
gh alias set bugs 'issue list --label='bugs'GitHub’s official command line tool
GitHub CLI
gh is GitHub on the command line. It brings pull requests, issues, and other GitHub concepts to the terminal next to where you are already working with git and your code.
Image: screenshot of gh pr status →https://user-images.githubusercontent.com/98482/84171218-327e7a80-aa40-11ea-8cd1-5177fc2d0e72.png
View this repository on GitHub: https://github.com/cli/cli
- Adding alias for bugs: issue list --label='bugs'
✓ Added alias.
$ gh bugs
Showing 2 of 7 issues in cli/cli that match your search
#19Pagination request returns empty JSON (bug)
#21Error raised when passing valid parameters (bug)
✓ Added alias.
$ gh bugs
Showing 2 of 7 issues in cli/cli that match your search
#19Pagination request returns empty JSON (bug)
#21Error raised when passing valid parameters (bug)