Cursor is an AI programming tool developed based on VS Code. The concept of workspace is similar to that of workspaces in VS Code. Here is a step-by-step guide to creating a new workspace.
1. Start Cursor AI
Launch the Cursor AI application. If you have not installed it, you can download and install a version suitable for your operating system from the official website ( cursor.com ).
2. Open the File menu
At the top of the interface, click the "File" option in the menu bar. If your interface is in Chinese, it should be "Open File" .
3. Select "Open Folder" or "Add Folder to Workspace"
If you want to create a new workspace, select Open Folder . This prompts you to select a local folder as the root directory of the workspace.
You can select an existing folder, or create a new empty folder (for example, create a new folder in File Explorer and select it).
If you already have an ongoing project and want to add another folder to the current workspace, you can choose Add Folder to Workspace .
4. Select or create a folder
In the file selection window that pops up, browse to the folder you want to set as the workspace.
If you need to create a new folder, you can click "New Folder" and confirm after naming it.
5. Save the workspace (optional)
If you want to save the current workspace for later use, you can click "File" > "Save Workspace as..." .
In the pop-up window, select the save location and name the workspace file (the workspace file is usually suffixed with .code-workspace
).
After saving, you can reopen the workspace at any time via File > Open Workspace..." .
6. Get started using the workspace
Once the folder is added to the workspace, the Explorer panel on the left will display the contents of the folder.
Now you can start creating files, writing code, and developing with Cursor's AI capabilities.
What a workspace does : In Cursor, a workspace is a collection of folders that can contain multiple project folders. It helps you manage multiple related projects at the same time and preserve specific settings (such as AI rules, extended configurations, etc.).
AI Integration : After creating a workspace, you can use shortcut keys (such as Cmd/Ctrl + L ) to open the AI chat panel to interact with the AI assistant, generate code, or get development help.
Custom rules : If you need to configure specific AI behavior for the workspace, you can create a .cursorrules
file in the workspace root directory to define code style, technology stack and other rules.
Create a folder on the desktop named MyProject .
In Cursor, click File > Open Folder and select the MyProject folder.
Click File > Save Workspace as... , save as MyProject.code-workspace .
Now you can create a code file in that workspace and start development.
Through these steps, you can quickly create and manage workspaces in Cursor AI and effectively leverage its AI capabilities to improve development efficiency.