问题原因整理:

查阅资料,察觉问题出在IPv6传输协议。

本机的Internet服务提供商(ISP)不支持IPv6。


解决方案如下:(手动安装)

1、CTRL+` (ese按键下),打开sublime命令输入框,将下述代码粘贴到命令行中,直接Enter执行:

sublime text 3 :

import urllib.request,os,hashlib; h = '6f4c264a24d933ce70df5dedcf1dcaee' + 'ebe013ee18cced0ef93d5f746d80ef60'; pf = 'Package Control.sublime-package'; ipp = sublime.installed_packages_path(); urllib.request.install_opener( urllib.request.build_opener( urllib.request.ProxyHandler()) ); by = urllib.request.urlopen( 'http://packagecontrol.io/' + pf.replace(' ', '%20')).read(); dh = hashlib.sha256(by).hexdigest(); print('Error validating download (got %s instead of %s), please try manual install' % (dh, h)) if dh != h else open(os.path.join( ipp, pf), 'wb' ).write(by)

sublime text 2

import urllib2,os,hashlib; h = '6f4c264a24d933ce70df5dedcf1dcaee' + 'ebe013ee18cced0ef93d5f746d80ef60'; pf = 'Package Control.sublime-package'; ipp = sublime.installed_packages_path(); os.makedirs( ipp ) if not os.path.exists(ipp) else None; urllib2.install_opener( urllib2.build_opener( urllib2.ProxyHandler()) ); by = urllib2.urlopen( 'http://packagecontrol.io/' + pf.replace(' ', '%20')).read(); dh = hashlib.sha256(by).hexdigest(); open( os.path.join( ipp, pf), 'wb' ).write(by) if dh == h else None; print('Error validating download (got %s instead of %s), please try manual install' % (dh, h) if dh != h else 'Please restart Sublime Text to finish installation')

 2.Enter执行后静等安装,安装完成后重新启动sublime,‘ctrl+shift+p’ 打开package,输入 install package 执行后不会报错就是成功了,再输入想要的插件进行安装即可,安装后同样的重新启动sublime,至此,常用的安装package control插件方法就是这了。



Created with the Personal Edition of HelpNDoc: Free PDF documentation generator