DEV Community

Lumin
Lumin

Posted on • Edited on

4 1

Install vscode on OSX via brew

| updated to latest brew version (thanks: @eloisetaylor5693)

Already have brew, then go

$ brew install --cask visual-studio-code
Enter fullscreen mode Exit fullscreen mode

If doesn't have brew before, run this first

$ /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
Enter fullscreen mode Exit fullscreen mode

Success ? check version and run :D

$ code --version 
$ code {your-project-folder}
Enter fullscreen mode Exit fullscreen mode

Top comments (5)

Collapse
 
eloisetaylor5693 profile image
eloisetaylor5693

Following the brew instructions noted in your post, I ran this brew cask install visual-studio-code, but got an error: Error: Unknown command: cask

After removing cask it worked

Collapse
 
eloisetaylor5693 profile image
eloisetaylor5693

seems like newer version of homebrew uses --cask instead, so now looks like this:

brew install --cask visual-studio-code

Collapse
 
ilumin profile image
Lumin

Thanks mate, I'll update my post too!

Collapse
 
tik9 profile image
Timo Körner

Why I need --cask? I installed without the flag and it works.

Collapse
 
xtrasmal profile image
Xander

Cask offers a way to manage the installation of graphical applications.

Brew without the --cask would install headless versions of those applications(like Docker for example) or would install the commandline version of it. It could also mean it install the application, but keeps it in the homebrew installation folder.

Installing all your applications through --cask allow you to better manage your system using homebrew only.

Homebrew offers the brew bundle dump command, which dumps all the things you installed on your machine through homebrew. It would create a file in your home directory called Brewfile, which you can use to easy recover your software using brew bundle install.

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Discover a treasure trove of wisdom within this insightful piece, highly respected in the nurturing DEV Community enviroment. Developers, whether novice or expert, are encouraged to participate and add to our shared knowledge basin.

A simple "thank you" can illuminate someone's day. Express your appreciation in the comments section!

On DEV, sharing ideas smoothens our journey and strengthens our community ties. Learn something useful? Offering a quick thanks to the author is deeply appreciated.

Okay