Difference between revisions of "Homebrew installation"

From wikieduonline
Jump to navigation Jump to search
 
(16 intermediate revisions by 4 users not shown)
Line 1: Line 1:
 +
https://docs.brew.sh/Installation
  
  /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
+
Adminnistrator required
 +
  /bin/[[bash -c]] "$([[curl -fsSL]] https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
 
  ==> Checking for `sudo` access (which may request your password)...
 
  ==> Checking for `sudo` access (which may request your password)...
  Sorry, user sf may not run sudo on Ms-MacBook-Pro.
+
  Sorry, user sf may not run sudo on XXXXXX.
 
  Need sudo access on macOS (e.g. the user YOUR_USERNAME needs to be an [[Administrator]])!
 
  Need sudo access on macOS (e.g. the user YOUR_USERNAME needs to be an [[Administrator]])!
  
Line 9: Line 11:
 
  ==> Checking for `sudo` access (which may request your password)...
 
  ==> Checking for `sudo` access (which may request your password)...
 
  Don't run this as root!
 
  Don't run this as root!
 +
 +
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
 +
==> Checking for `sudo` access (which may request your password)...
 +
[[Homebrew on Linux is not supported on ARM processors]].
 +
  https://docs.brew.sh/Homebrew-on-Linux#arm-unsupported
  
 
== User installation ==
 
== User installation ==
 
https://stackoverflow.com/a/55021458
 
https://stackoverflow.com/a/55021458
cd $HOME && [[git clone]] https://github.com/Homebrew/brew.git && ./brew/bin/[[brew tap homebrew/core]]
+
{{brew user installation}}
echo "[[export]] PATH=$HOME/brew/bin:$PATH" >> ~/[[.zshrc]]
 
echo "[[export]] PATH=$HOME/brew/bin:$PATH" >> ~/[[.bashrc]]
 
  
 
Verify:  
 
Verify:  
:<code>[[exec]] [[$SHELL]]</code>
+
:<code>[[exec]] [[$SHELL]] && [[which]] brew</code>
:<code>[[which]] brew</code> # see that brew is found in your path
+
 
  
  
 
  du -hs $HOME/brew
 
  du -hs $HOME/brew
 
  640M /Users/YOUR_USER/brew
 
  640M /Users/YOUR_USER/brew
 +
 +
OR
 +
 +
{{brew user installation curl}}
 +
 +
== ARM errors ==
 +
<pre>
 +
Error: No Homebrew ruby 2.6.8_1 available for aarch64 processors!
 +
Error: Failed to install Homebrew Portable Ruby and cannot find another Ruby 2.6.8!
 +
If there's no Homebrew Portable Ruby available for your processor:
 +
- install Ruby 2.6.8 with your system package manager (or rbenv/ruby-build)
 +
- make it first in your PATH
 +
- try again
 +
</pre>
 +
 +
 +
== Errors ==
 +
[[Error: Git is unavailable]]
  
 
== Related ==
 
== Related ==
 
* <code>[[brew install]]</code>
 
* <code>[[brew install]]</code>
 
* <code>[[/opt/homebrew/]]</code>
 
* <code>[[/opt/homebrew/]]</code>
* <code>[[.zprofile]]</code>
+
* <code>[[~/.zprofile]]</code>
 +
* <code>[[brew autoupdate start --upgrade]]</code>
 +
* [[macOs first setup]]
  
 
== See also ==
 
== See also ==
 +
* {{brew install}}
 
* {{brew}}
 
* {{brew}}
 
* {{homebrew}}
 
* {{homebrew}}
  
 
[[Category:macOS]]
 
[[Category:macOS]]

Latest revision as of 10:12, 27 May 2024

https://docs.brew.sh/Installation

Adminnistrator required

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
==> Checking for `sudo` access (which may request your password)...
Sorry, user sf may not run sudo on XXXXXX.
Need sudo access on macOS (e.g. the user YOUR_USERNAME needs to be an Administrator)!
sudo /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
Password:
==> Checking for `sudo` access (which may request your password)...
Don't run this as root!
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
==> Checking for `sudo` access (which may request your password)...
Homebrew on Linux is not supported on ARM processors.
  https://docs.brew.sh/Homebrew-on-Linux#arm-unsupported

User installation[edit]

https://stackoverflow.com/a/55021458

cd $HOME && git clone https://github.com/Homebrew/brew.git && ./brew/bin/brew tap homebrew/core && echo "export PATH=$HOME/brew/bin:$PATH" >> ~/.zshrc && echo "export PATH=$HOME/brew/bin:$PATH" >> ~/.bashrc

Verify:

exec $SHELL && which brew


du -hs $HOME/brew
640M	/Users/YOUR_USER/brew

OR

 mkdir homebrew && curl -L https://github.com/Homebrew/brew/tarball/master | tar xz --strip 1 -C homebrew && echo "export PATH=$PATH:$HOME/homebrew/bin" >> ~/.bash_profile && source ~/.bash_profile

ARM errors[edit]

Error: No Homebrew ruby 2.6.8_1 available for aarch64 processors!
Error: Failed to install Homebrew Portable Ruby and cannot find another Ruby 2.6.8!
If there's no Homebrew Portable Ruby available for your processor:
- install Ruby 2.6.8 with your system package manager (or rbenv/ruby-build)
- make it first in your PATH
- try again


Errors[edit]

Error: Git is unavailable

Related[edit]

See also[edit]

Advertising: