Skip to main content

Visual Studio Code

·862 words·5 mins· ·
Table of Contents

Visual Studio Code Shortcuts Guide
#

One of the key features that make Visual Studio Code (VS Code) a favorite among developers is its extensive set of keyboard shortcuts. These shortcuts can significantly enhance productivity by allowing you to perform actions quickly without leaving the keyboard. Below is a table listing some of the most useful shortcuts for VS Code.

ActionShortcut (Windows)
Command PaletteCtrl + Shift + P
Quick OpenCtrl + P
New FileCtrl + N
Open FileCtrl + O
SaveCtrl + S
Save AllCtrl + K, S
Close EditorCtrl + W
Close All EditorsCtrl + K, W
Split EditorCtrl + \
Toggle Terminal`Ctrl + ``
Toggle SidebarCtrl + B
Toggle Full ScreenF11
FindCtrl + F
ReplaceCtrl + H
Find in FilesCtrl + Shift + F
Replace in FilesCtrl + Shift + H
Go to DefinitionF12
Peek DefinitionAlt + F12
Rename SymbolF2
Show HoverCtrl + K, Ctrl + I
Open SettingsCtrl + ,
Open Keyboard ShortcutsCtrl + K, Ctrl + S
Open ExtensionsCtrl + Shift + X
Comment LineCtrl + /
Block CommentShift + Alt + A
Move Line Up/DownAlt + Up/Down Arrow
Copy Line Up/DownShift + Alt + Up/Down
Open/focus terminalCtrl + æ
Focus ExplorerCtrl + Shift + E

These shortcuts cover a wide range of functionalities, from navigating the code to performing complex refactoring tasks. Learning and incorporating these into your workflow can make your development process much smoother and more efficient.

Installed Extensions in Visual Studio Code
#

Visual Studio Code’s extensibility allows you to tailor your development environment to suit your specific needs. Here is a detailed list of some powerful extensions that are currently installed in your VS Code instance:

1. Continue (continue.continue)
#

  • Description: Continue is an AI-powered code assistant that helps you write and understand code faster. It leverages advanced machine learning models to suggest code completions, generate documentation, and provide intelligent insights into your codebase.
  • Usage: This extension can be particularly useful for speeding up development by providing context-aware code suggestions. I have setup a ollama installation for use with this plugin.

2. Dracula Official (dracula-theme.theme-dracula)
#

  • Description: Dracula is a popular, dark theme for various editors and platforms. It offers a visually appealing and consistent color scheme that reduces eye strain and makes the code easier to read.
  • Usage: Ideal for developers who prefer working in a dark-themed environment, enhancing focus and reducing eye fatigue.

3. Indent Rainbow (oderwat.indent-rainbow)
#

  • Description: Indent Rainbow colorizes the indentation levels in your code with different colors, making it easier to identify the structure and nested blocks of code.
  • Usage: Particularly useful for languages with significant indentation, like Python, or for large code files where visualizing nested structures quickly is essential.

4. Ansible (redhat.ansible)
#

  • Description: This extension provides rich support for Ansible, including features like syntax highlighting, IntelliSense, and linting for Ansible playbooks, roles, and variables.
  • Usage: Essential for developers working with Ansible automation, ensuring accurate and efficient Ansible script development.

5. YAML (redhat.vscode-yaml)
#

  • Description: This extension offers comprehensive support for YAML files, including features like validation, autocompletion, and error detection.
  • Usage: Crucial for developers who frequently work with YAML configuration files, ensuring the correctness and efficiency of their YAML scripts.

6. VSCode Icons (vscode-icons-team.vscode-icons)
#

  • Description: Adds a set of visually appealing icons to VS Code, making it easier to identify files and directories at a glance.
  • Usage: Enhances the visual organization of your project, making it easier to navigate and manage your files.

7. Zoom Bar (wraith13.zoombar-vscode)
#

  • Description: Adds a zoom bar to VS Code, allowing you to quickly zoom in and out of your code.
  • Usage: Useful for presentations, pair programming, or simply adjusting the code view for better readability.

8. Markdown Preview GitHub Styles (bierner.markdown-preview-github-styles)
#

  • Description: Renders Markdown previews in VS Code with GitHub-like styles, providing a more consistent look with how Markdown files are displayed on GitHub.
  • Usage: Ideal for developers writing documentation or README files that need to look the same as they would on GitHub.

9. Markdown All in One (yzhang.markdown-all-in-one)
#

  • Description: An all-in-one extension for Markdown, providing features like shortcuts, table of contents generation, and more.
  • Usage: Makes writing and managing Markdown files easier and more efficient with a comprehensive set of tools.

10. Trailing Spaces (shardulm94.trailing-spaces)
#

  • Description: Highlights trailing spaces in your code and provides commands to delete them.
  • Usage: Helps maintain clean code by ensuring no unnecessary trailing spaces are left in the code files.

11. File Tree Generator (shinotatwu-ds.file-tree-generator)
#

  • Description: Generates a file tree structure of your project directory for easy visualization and documentation.
  • Usage: Useful for creating visual representations of your project structure, which can be included in documentation or shared with team members.

One-Liner to Install All Extensions (PowerShell)
#

To install all these extensions in VS Code using PowerShell, run the following command:

code --install-extension continue.continue; code --install-extension dracula-theme.theme-dracula; code --install-extension oderwat.indent-rainbow; code --install-extension redhat.ansible; code --install-extension redhat.vscode-yaml; code --install-extension vscode-icons-team.vscode-icons; code --install-extension wraith13.zoombar-vscode; code --install-extension bierner.markdown-preview-github-styles; code --install-extension yzhang.markdown-all-in-one; code --install-extension shardulm94.trailing-spaces; code --install-extension shinotatwu-ds.file-tree-generator
Kristian
Author
Kristian