您的位置:首页 > 其它

解决sublime无法安装软件的问题

2016-05-16 17:34 316 查看
  具体可参考:http://lostingz.github.io/sublime_channel/

  1.打开sublime,ctrl+shift+p打开窗口输入:Package Control: Add Channel

  输入sublime的channel为本页面下载channel json的路径即:https://raw.githubusercontent.com/lostingz/sublime_channel/gh-pages/channel_v3.json

  2.ctrl+shift+p 输入install 选择Package Control install 等待后输入或选择要安装的软件

  注:如果指定channel json 路径后提示 Schema的的版本不对(schema is not a valid number) 卸载原来的package control插件,重新安装新版本即可

  卸载指定插件方法:
选择 the Preferences > Settings – User

从 "ignored_packages"中删除"Package Control" 项(如果有删除,没有不管)

选择 Preferences > Browse Packages(浏览程序包)…

删除 Package Control文件夹

返回上一级到 Installed Packages文件夹

删除 Package Control.sublime-package 文件(如果有删除,没有不管)

重新安装 Package Control
安装方法一:

sublime text3:

import urllib2,os,hashlib; h = '2915d1851351e5ee549c20394736b442' + '8bc59f460fa1548d1514676163dafc88'; 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')


sublime text2:

import urllib2,os,hashlib; h = '2915d1851351e5ee549c20394736b442' + '8bc59f460fa1548d1514676163dafc88'; 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')


安装方法二:
Click the Preferences > Browse Packages… menu

Browse up a folder and then into the Installed Packages/ folder

Download Package Control.sublime-package and copy it into the Installed Packages/ directory

Restart Sublime Text
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: