Visual Studio Code
- blog tutorial vscode
Visual Studio Code - Open Source - wiki - Docs
Portable version of the Visual Studio Code editor
设置语言
ctrl + shift + p
> Configure Language / 配置语言
> 修改为 zh-CN/en-US
> 保存重启 VSCode
用户设置
File
> Preferences
> Settings
// Place your settings in this file to overwrite the default settings
{
"editor.fontFamily": "Source Code Pro",
"editor.fontSize": 16,
"editor.tabSize": 4,
"editor.insertSpaces": true,
"editor.detectIndentation": true,
"editor.roundedSelection": true,
"editor.wordWrap": "on",
"editor.renderWhitespace": "all",
"editor.formatOnType": false,
"editor.useTabStops": true,
"files.encoding": "utf8",
"files.trimTrailingWhitespace": true,
"files.autoSave": "afterDelay",
"files.autoSaveDelay": 1000,
"files.insertFinalNewline": true,
"files.eol": "\n",
"files.associations": {"*.m": "matlab"},
"files.autoGuessEncoding": true
"http.proxy": "",
"http.proxyStrictSSL": true,
"git.enabled": true,
"git.path": null,
}
安装插件1
ctrl + shift + p
> ext install python
Python
ctrl + shift + p
> >Tasks: Configure Task Runner
> Others
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"tasks": [
{
"taskName": "Python",
"type": "process",
"command": "python",
"args": [
"-u",
"${file}"
],
"group": "build",
"presentation": {
"reveal": "silent"
},
// Use the standard MS compiler pattern to detect errors, warnings and infos
"problemMatcher": "$msCompile"
}
]
}
ctrl + shift + b
即可执行 Python 代码。
-
插件目录
~/.vscode/extensions
↩︎