How to install Homebrew in Mac OSX (High Sierra)

Homebrew setup guide


This guide describes how to install Homebrew and few ferequently used Homebrew commands.
Using Homebrew you can install software very easily. It is like linux "yum" command.

Install Homebrew (The missing package manager for OS X):

$/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
  • $brew doctor (You should see "Your system is ready to brew." on the console output. Do not move forward unless you see this.)

Common commands:

  • Check version of brew:  $brew --version
  • Search Homebrew repo: $brew search %app name% (i.e: I want to check "wget" is available or not. $brew search wget)
  • Check app information:   $brew info %app name% (i.e: $brew info wget)
  • Install software package: $brew install %app name% (brew install tree)
  • Uninstall software package: $brew uninstall %app name% (brew uninstall tree)
  • Check installed packages in your system: $brew list

Install Cask:

brew cask is an extension (3rd party repo) to brew that allows management of graphical applications executable through the Cask project, on the otherside brew only install command line app. For example using brew cask sublime, java can be installed easily.
  • $brew tap caskroom/cask
  • $brew install cask

Note

The "$brew tap" command allows Homebrew to tap into another repository of formulae (package def. in Ruby). Once you have done this you have expanded your options of installable software (adding more repo.).

Common commands:

  • Check version of cask: $brew cask --version
  • Search cask repo: $brew cask search %app name% (i.e: I want to check "java" is available or not. $brew cask search java. You can search all packages in the search repo by: "$brew cask search" This command returns all available package names in the Cask repo.)
  • Upgrade Cask's installed app: $brew cask upgrade (Upgrade outdated package only)
  • Check app information: $brew cask info %app name% (i.e: $brew cask info dbeaver-community)
  • Install software package: $brew cask install %app name% (brew cask install sublime-text)
  • Uninstall software package: $brew cask uninstall %app name% (brew cask uninstall sublime-text)
  • Check installed cask packages in your system: $brew cask list

Update Homebrew and Cask package list

  • $brew update

Note:

Homebrew does not check online everytime about the newly available package. During installation of Homebrew it downloads the current package list. Thus, we may need to update latest package list before searching new app. Since the Homebrew-Cask repository is a Homebrew Tap, you’ll pull down the latest Casks every time you issue the regular Homebrew command "$brew update"

Comments

Popular posts from this blog

There is a process already using the admin port 4848 -- it probably is another instance of a GlassFish server; ERROR

How to Convert OutputStream to InputStream

How to compile and install GraphicsMagick (GM) in Linux