17

I don't see a keyboard shortcut for "Open Folder..." listed on the documentation page below, and after searching elsewhere for a while I didn't see anything else.

https://code.visualstudio.com/docs/customization/keybindings

I thought I would ask here before putting an issue on GitHub about it. (Also there doesn't seem to be a open / closed issue about this anywhere on the GitHub repo.)

https://github.com/Microsoft/vscode/issues

3 Answers 3

13

There is indeed a shortcut for it, the command is workbench.action.files.openFolder, and the default keybinding is Ctrl+K,Ctrl+O.

It's easy to find in the list of shortcuts (File → Preferences → Keyboard Shortcuts) if you search for "folder" or "openFolder" in the Default Keybindings.

Sign up to request clarification or add additional context in comments.

Comments

0

Hit Cmd+O on macOS or Ctrl+O on Windows/Linux to activate the open dialog, select a folder, and click "Open."

Note: This answer was written before multiple folder workspaces were implemented in VS Code. If you open folders this way, it will replace your entire workspace with the folder you selected to open. If you want to add a folder to your existing workspace, you must use Cmd+K, Cmd+O on a macOS or Ctrl+K, Ctrl+O on Windows/Linux.

4 Comments

It's for file not for folder. @Gama11's solution works
@JanatbekSharsheyev it works for both by default. If you select a folder it will still let you click "Open" then open the folder in VS Code. However, it will replace your entire workspace with the new open folder. You will need to use Gama11's solution only if you want to add a folder to your current workspace (which wasn't even a feature when I wrote this answer).
@adamency when do you have to use a mouse click? it's just Ctrl + K, Ctrl + O
Misunderstood. However, this shortcut is not existent on a native VS Code install (with brew) on macos today.
0

You have to type Ctrl+K and then Ctrl+O to open a folder in Vs code on Windows and you have to type Cmd+K and Cmd+O to open folder in Vs code on mac...

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.