Go 开发利器:VSCode
为什么选择 VSCode?
微软官方出品,更新迭代快
强大的插件:代码跳转,自动格式化,错误检测等
下载安装
登录 vscode 官网: https://code.visualstudio.com
根据操作系统选择对应包下载
将 code
命令添加到系统 PATH 中
code
命令添加到系统 PATH 中效果:在终端输入
code <filename/foldername>
就能用 vscode 打开文件或文件夹
以 mac 为例:在 vscode 中使用快捷键
command + shif + p
,输入 shell command,选择
Shell Command:Install 'code' command in PATH
,如下图:
安装 Go 插件
登录 vscode 官网
Extensions
模块:https://marketplace.visualstudio.com/VSCode搜索
go
插件推荐安装
lukehoban
的 go 插件: https://marketplace.visualstudio.com/items?itemName=lukehoban.Go点击
install
后就打开 vscode 界面,进行安装
Go 开发相关配置
最后更新于