To disabled font weight bold in the terminal of vscode/cursor
Add below settings to
settings.json
Custom class name to show the autocompletion (default to
className
)Cannot turn off format on save?
First, try the solutions suggested here.
If the official settings don't work, consider binding "Saving without formatting" to
cmd+S
as described in this solution.Run JavaScript, C#, F#, R, SQL, KQL, PowerShell in Jupyter notebook of VSCode
We will use Polyglot Notebooks. Some remarks (for macOS M1):
- Install .NET SDK (M1 use arm64)
- Install this extension
- Restart VSCode and maybe after restarting VSCode, we need to reload the window too
- We cannot choose any “Polyglot Notebook: …” from the Command Palette. Instead, create a new normal jupyter notebook, change the kernel to .NET Interactive
- Inside the cell, change the language to the language we want, for example, “javascript”.
- That’s it!
To run python and R codes, check this note.
Caution: After installing .NET, a service named
dotnet
may continuously run in the background, potentially slowing down your system by consuming excessive CPU. If you wish to remove it, consult Microsoft's official uninstallation guide. For a quick solution, I simply use this command:Enable preview (nhấn file in the left sidebar → show file as preview)
Search trong settings, “Workbench → Editor: Enable Preview”
Files to exclude list
Change style of active tab
Fixed tab size
Using VSCode in terminal
Open VSCode >
cmd + shift + p
> Type "shell command" > Select "Install code command in path" > Navigate to any project on terminal and type code .
top open it.reStructuredText
preview engine sphinx is not installed
→ in Ubuntu 20.04+Add extra path to auto complete (python)
Open
settings.json
and add,Fix Pylint unable to import
Open
settings.json
and add,Enable font ligatures
For example, you type
>
+ =
, it becomes ≥
.- Download Fira Code Font.
- Extract and then install the font after that.
- Reload VSC.
💡 If you only wanna apply this setting for some file format, you can click on the language at the bottom right of VSC, then click Configure 'Markdown' language based setting.
Exlude files/folders in search results
Go to Preferences > Settings > search
exclude
and modify inside section Search: Exclude
. More patterns can be found here.Connect
ssh
folders in VSCRead this tutorial.
- Install extension Remote - SSH
- View > Command Palette... > type "SSH" and choose "Remote-SSH: Connect to Host..." > choose "+ Add New SSH Host..."
- Type
ssh user@host
>Enter
> choose a file to be updated, e.g.~/.ssh/config
.
- Click Connect if there is any popup in VSC.
- Choose platform on the server, usually Linux.
Work with multiple workspace
💡A tip to work with different workspace in the same screen (Because it's difficult to distinguish "quickly" between opened windows) => change color scheme for each workspace!
In the current workspace > Go to "Preferences" > Settings > Click on tab "Workspace" > Workbench > Appearance > Color Theme.
Snippets
💡 Why need? Quickly add a long snippet of text (with suggestion) with several keywords. For example, I add
###Thi console.log()
when debugging codes in JS. Then, I search the whole project for the line console.log()
that I forgot to delete.How? Open Preferences > User Snippets > either you create a global file or type and find a good format (for example, type "markdown" and create snippets for this format only).
Note: In order for snippets working with markdown file, you have to add below settings (VSCode's
settings.json
)Show the verticle line for blocks (indentation guides)
"editor.guides.indentation": false,
Pylint
Disable tslint
Ignore some pylint for jupyter notebook
👉 Note: Jupyter notebook.
Just place before the line like this,
Open Terminal window in the split screen mode
If you wanna open terminal below the 2nd screen in the vertical split screen mode, you can:
Cmd
(or Ctrl
on Windows/Linux) + Shift
+ P
to open Command Palette > search for "Terminal: Move Terminal into Editor Area".Hot keys
One can change the default keyboard shortcut by going to: File > Preferences > Keyboard Shortcuts.