Skip to content

Instantly share code, notes, and snippets.

@1901
Last active October 3, 2015 05:58
Show Gist options
  • Save 1901/2404724 to your computer and use it in GitHub Desktop.
Save 1901/2404724 to your computer and use it in GitHub Desktop.
SublimeText2安装“Package Control”
# 1、打开 Sublime Text 2,按下 Control + ` 调出 Console
# 2、将以下代码粘贴进命令行中并回车
import urllib2,os;pf='Package Control.sublime-package';ipp=sublime.installed_packages_path();os.makedirs(ipp) if not os.path.exists(ipp) else None;open(os.path.join(ipp,pf),'wb').write(urllib2.urlopen('http://sublime.wbond.net/'+pf.replace(' ','%20')).read())
# 3、重启 Sublime Text 2,如果在 Preferences -> Package Settings中见到Package Control这一项,就说明安装成功了
# Sublime Text 2 和 Sublime Text 3中Package Control安装方法及下载地址:
# https://sublime.wbond.net/installation
# Mac系统下长按重复按键
# sublimetext 3
defaults write com.sublimetext.3 ApplePressAndHoldEnabled -bool false
#sublimetext 2
defaults write com.sublimetext.2 ApplePressAndHoldEnabled -bool false
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment