标签:int request build pack list sts read cab res
安装Package Control
安装过程: 使用快捷键 control + ` 或者菜单栏选择View > Show Console
安装Package Control参考官方页面.
Sublime Text3在控制台输入
import urllib.request,os,hashlib; h = ‘7183a2d3e96f11eeadd761d777e62404‘ + ‘e330c659d4bb41d3bdf022e94cab3cd0‘; 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 Text2在控制台输入
import urllib2,os,hashlib; h = ‘7183a2d3e96f11eeadd761d777e62404‘ + ‘e330c659d4bb41d3bdf022e94cab3cd0‘; 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‘)
打开Package Control 快捷键:shift + cmd + p, 然后输入install如下图所示:
终端启动Sublime Text3
终端输入如下命令,建立软连接
ln -s "/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl" /usr/local/bin/subl
在终端中可以通过 subl 来打开对应的文件.
快捷键
Command + Shift + P打开 Package Control 命令面板。
Command + P 打开文件,例如在linux内核源码中输入list.h会列出整个文件夹下所有同名文件。
Command + / 注释/取消注释选中的代码
Command + R 查找函数、结构体定义等,例如我们要查找函数list_entry
Control +G 跳转到某一行,例如我们在list.h中要跳转到100行.
Command + L选取光标所在的行,光标指向下一行行首,继续Command+L则继续选中
---------------------
作者:52coder
来源:CSDN
原文:https://blog.csdn.net/persever/article/details/78118795
标签:int request build pack list sts read cab res
原文地址:https://www.cnblogs.com/hankleo/p/10393116.html