When you install the "Cursor" AI code editor / IDE on Windows, it takes over the code
command which many developers often use in the terminal to quickly open VSCode.
For example, the issue arises if you navigate to a folder with your code repo and type code .
it will open that folder in "Cursor" instead of "VS Code".
This is fine if you wish to replace Cursor with VS Code as your default IDE. But if you wish to use both "Cursor" and "VS Code", such replacement of default behavior is annoying, when you want to launch VS Code.
I prefer to open VS Code when code .
command is used, and wish to open "Cursor" if cursor .
is typed.
So how to have ability to quickly open both VS Code and cursor on CLI?
Reference: https://namvu.net/2025/01/cursor-stole-your-code-command-heres-how-to-revert-it/
On Windows:
C:\Users\<your-user-name>\AppData\Local\Programs\
foldercursor\resources\app\bin,
You should see two identical files code.cmd and cursor.cmd.code
code .
will open VS code as usually preferred by VS code users, whereascursor .
should open the cursor AI editor.