Essay - Published: 2016.08.01 | 1 min read (206 words)
DISCLOSURE: If you buy through affiliate links, I may earn a small commission. (disclosures)
**Problem: **I use Visual Studio Code as my primary editor on my Mac. I’ve heard that there’s a way to open a directory in an editor through a Terminal command. How can I open a new editor window inside a directory from the command line?
**Solution: **
First, make sure that you already have the Visual Studio Code ‘code’ command installed in PATH. You can check this by:
If you did the above and saw something similar to ‘command code could not be found/resolved’, then code hasn’t been added to your path yet. To install it correctly:
Once you’ve finished the above, you’re now ready to open your first Visual Studio Code editor in a directory straight from the command line.
The best way to support my work is to like / comment / share this post on your favorite socials.