Visual Studio Code (VS Code) is a free, open-source code editor developed by Microsoft. It offers robust features like IntelliSense, integrated Git support, debugging capabilities, and a vast extension ecosystem, making it a favourite among developers.
๐งฐ Prerequisites
- macOS Version: Ensure you’re running macOS 10.15 (Catalina) or later.
- Internet Connection: Required to download VS Code and any extensions.
- Terminal Access: Basic familiarity with the Terminal app is beneficial.
๐ฅ๏ธ Installation Steps
1. Download VS Code
- Navigate to the official Visual Studio Code download page.
- Click on the macOS download button. The site will automatically detect your operating system and provide the appropriate version (Intel or Apple Silicon).
2. Install VS Code
- Locate the downloaded
.zip
file in your Downloads folder. - Double-click the
.zip
file to extract it. This will produce theVisual Studio Code.app
file. - Drag and drop the
Visual Studio Code.app
into your Applications folder to install it.
3. Launch VS Code
- Open the Applications folder and double-click on Visual Studio Code to launch the editor.
- Optionally, right-click on the VS Code icon in the Dock and select Options > Keep in Dock for easy access.
4. Add VS Code to Your PATH (Optional)
Adding VS Code to your system’s PATH allows you to open the editor from the Terminal using the code
command.
- Open VS Code.
- Press
Cmd + Shift + P
to open the Command Palette. - Type
shell command
and select Shell Command: Install ‘code’ command in PATH. - Restart your Terminal for the changes to take effect.
Now, you can open any folder in VS Code directly from the Terminal:
bashcode .
๐ Recommended Extensions
Enhance your development experience by installing popular extensions:
- Python: Adds support for Python development.
- ESLint: Integrates ESLint into VS Code for JavaScript linting.
- Prettier: Code formatter for consistent styling.
- GitLens: Supercharges the built-in Git capabilities.
To install extensions:
- Go to the Extensions view by clicking on the square icon in the sidebar or pressing
Cmd + Shift + X
. - Search for the desired extension and click Install.
๐งช Verify Installation
To ensure everything is set up correctly:
- Open VS Code.
- Press
Cmd + Shift + P
, typeTerminal: Create New Integrated Terminal
, and press Enter. - In the terminal, type:
bashcode --version
You should see the installed version number, confirming that VS Code is correctly installed and accessible via the command line.
๐ฅ Download Visual Studio Code
For your convenience, here are direct download links: