离线安装vscode插件

1.进入插件下载官网

 

https://marketplace.visualstudio.com/vscode 

 

2.获取下载链接
下载链接的模板为:
https://${publisher}.gallery.vsassets.io/_apis/public/gallery/publisher/${publisher}/extension/${extension name}/${version}/assetbyname/Microsoft.VisualStudio.Services.VSIXPackage

3.以python插件为例
在插件官网进入python插件的页面 
网址为:https://marketplace.visualstudio.com/items?itemName=ms-python.python
从这个url中获取
${publisher}的值为ms-python
${extension name}的值为python

${version}的值在插件介绍界面右侧的More Info获取(当前版本是2018.2.1)

修改之后的下载链接为:

https://ms-python.gallery.vsassets.io/_apis/public/gallery/publisher/ms-python/extension/python/2018.2.1/assetbyname/Microsoft.VisualStudio.Services.VSIXPackage

4.下载之后的文件名是:

Microsoft.VisualStudio.Services.VSIXPackage

修改文件名为:
python.vsix(文件名随意修改,后缀必须为vsix)
 

5.开始安装

打开vscode,点击扩展右侧的三个点,选择从VSIX安装,之后选择文件安装,之后重启即可

你可能感兴趣的:(离线安装vscode插件)