Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to Install Sublime Text 3 using Homebrew cask

How can I use Homebrew cask to install Sublime Text 3? I only see Sublime Text 2 when using Homebrew's search. I even tried tapping homebrew/versions, but no luck.

like image 672
ZakTaccardi Avatar asked Dec 09 '14 14:12

ZakTaccardi


People also ask

How do I install sublime text on my Macbook Pro?

Go to the Sublime Text download page. Download Sublime Text for Mac. In your Downloads directory, double-click on Sublime Text. dmg to open it.


8 Answers

brew install caskroom/cask/brew-cask
brew tap caskroom/versions
brew cask install sublime-text

Weird how I will struggle with this for days, post on StackOverflow, then figure out my own answer in 20 seconds.

[edited to reflect that the package name is now just sublime-text, not sublime-text3]

like image 96
ZakTaccardi Avatar answered Oct 06 '22 03:10

ZakTaccardi


An update

Turns out now brew cask install sublime-text installs the most up to date version (e.g. 3) by default and brew cask is now part of the standard brew-installation.

like image 43
madhu131313 Avatar answered Oct 06 '22 03:10

madhu131313


As of late May, 2021, Sublime Text 4 has been released. As a result, the old solution to installing Sublime Text 3 via Homebrew will now install Sublime Text 4 instead. If this is what you actually want, then the following brew installation command will install it:

brew install --cask sublime-text

Currently, there is no available cask on Homebrew which will allow the installation of Sublime Text 3 instead of Sublime Text 4.

As a side note, Sublime Text 2 is available in the sublime-text2 cask.


Historical note: This question originally was motivated by the fact that the sublime-text cask was Sublime Text 2 instead of Sublime Text 3. As of around May 2016, this is no longer the case.

like image 37
taylorthurlow Avatar answered Oct 06 '22 04:10

taylorthurlow


$ brew tap caskroom/cask
$ brew install brew-cask
$ brew tap caskroom/versions
$ brew cask install sublime-text
like image 39
Abdulla Abu Zakham Avatar answered Oct 06 '22 03:10

Abdulla Abu Zakham


To install Sublime Text 3 run:

brew install --cask sublime-text

reference: https://formulae.brew.sh/cask/sublime-text

like image 21
Boaz Avatar answered Oct 06 '22 04:10

Boaz


I did not have brew cask installed so I had to install it first,so these were the steps I followed:

brew install caskroom/cask/brew-cask
brew tap caskroom/versions
brew cask install sublime-text
like image 45
The Third Avatar answered Oct 06 '22 02:10

The Third


As per latest updates, caskroom packages have moved to homebrew. So try following commands:

brew tap homebrew/cask
brew cask install sublime-text

These 2 terminal commands will be enough for installing sublime.

like image 33
Manasvi Batra Avatar answered Oct 06 '22 03:10

Manasvi Batra


Please note that brew cask <command> was deprecated in favor of brew <command> --cask in Homebrew 2.6.0. So as of 2021, you can use:

brew install --cask sublime-text
like image 37
1218985 Avatar answered Oct 06 '22 04:10

1218985