VS Code Basic command snippets

VS Code Basic command snippets

VS Code Command shortcuts

  • So many of you not using the minimum VS code shortcuts. VS code provided us awesome shortcuts it can save our time.

    Here I will show you minimum regular usage basics commands in VS code.

Open a VS terminal

  • You can open a terminal using below comand snippet.
ctrl + `

Create a new file in VS terminal

  • You can create a new file using below command snippet in your VS terminal
code filename.html or .css or .js or .py

                or
echo > "filename.html or .css or .js or .py"

                or
cat > filename.html or .css or .js or .py

                or
ctrl + N

2.png

3.png

In VS code terminal touch command is not work because it's not a command. No problem Here I will show you tricky part in VS code

  • In VS terminal right top open + menu bar in that you can see gitbash(it must install on your machine) then you can choose the gitbash.
  touch filename.html or css or js or py

1.png

gitbash.png

Create a new folder in VS terminal

  • You can create a new folder using below command snippet in your VS terminal
mkdir yourFolderName

4.png

Open New in VS Code

  • You can Open a new VS Code using below command snippet in your VS terminal
ctrl + shift + N

Multiline Cursor in VS Code

  • This cool feature is more advantages and time saving also let see how it work's.
    alt + mouse left click
    
    then you can select multiple code lines and feel free to type delete the same content only.

Select current lines in VS Code

  • In this selection part you want to copy the paragraph or same line words use below command snippet let see how it work's.
    ctrl + L or alt + arrow down
    
    then you can select multiple code lines and feel free to type delete the same content only.

Replace content in VS Code

  • You want to replace some words instead of other same words you can follow the below command.
search command
ctrl + f

replace command
ctrl + h

You can choose for replacing one word or multiple words(use replace all)

Debug in VS Code

  • You want yo open a debug menu by shorcut you can follow the below command.
Start/Continue debugging
F5 or fn(function) + F5
        and
Stop debugging
Shift + F5

5.png

You can choose for replacing one word or multiple words(use replace all)

These are the minimum basic keyword shortcuts for VS Code

For More shortcuts for windows. VS Code-shortcuts-windows

For More shortcuts for Mac os VS Code-shortcuts-Mac

Thanks for reading