Press Windows + S, search for "Environment Variables", and select:
👉 "Edit the system environment variables"
Click the Environment Variables button at the bottom.
Under User variables for USERNAME(OF YOUR WINDOWS):
-
Select Path
-
Click Edit
-
Click New
-
Paste the following path:
Click OK on all windows to apply.
Restart Terminal / VS Code
Close Command Prompt, PowerShell, or VS Code, and reopen them.
Now try:
If the version number appears, it means the code
command is now available in the terminal.