vam*_*olu 8 sublimetext3 package-control sublime-text-plugin
由于某种原因,我在印度的ISP拒绝阻止Github.我一直在尝试手动安装Sublime Text 3的Package Control并使用Sublime Text 3 Console.在这两种情况下,似乎都缺少一个依赖:
Package Control: Installing 1 missing dependencies
Package Control: Attempting to use Urllib downloader due to WinINet error: Error downloading package. Host not found (errno 12007) during HTTP write phase of downloading https://codeload.github.com/codexns/sublime-bz2/zip/1.0.0.
Package Control: Error downloading package. URL error [Errno 11004] getaddrinfo failed downloading https://codeload.github.com/codexns/sublime-bz2/zip/1.0.0.
error: Package Control
Unable to download bz2. Please view the console for more details.
Package Control: Skipping automatic upgrade, last run at 2015-01-03 11:32:25, next run at 2015-01-03 12:32:25 or after
Run Code Online (Sandbox Code Playgroud)
我手动下载了Sublime bz2文件,我现在该怎么办?
浏览一些东西告诉我Package Control 3.0有依赖关系:
Once the package is extracted, a custom-generated python file is added to a special package named
0_package_control_loader. For Sublime Text 3, this is a .sublime-package file, whereas for
Sublime Text 2 it is just a folder. The reason for the name (and creating it as a .sublime-
package file in ST3) is to ensure it is the very first non-default package that Sublime Text
loads.
Run Code Online (Sandbox Code Playgroud)
是否有一个0_package_control_loader.sublime-package我可以手动添加的版本(假设我已经安装了Package Control,这个依赖项丢失了?
小智 -2
import urllib.request,os,hashlib;
h = '2deb499853c4371624f5a07e27c334aa' + 'bf8c4e67d14fb0525ba4f89698a6d7e1';
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)
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
26470 次 |
| 最近记录: |