Prior to doing Android development has been using eclipse as an editor, after contact with Ruby began to use sublime Text 2, gradually discovered the benefits of these editors, but also more and more rely on it.
Sublime Text 2 is a lightweight, simple, efficient, cross-platform editor, with a variety of advantages such as easy color Matching and vim shortcut keys, which has won a lot of front-end developers ' love. Not before and know that it has so many plug-in extension and support, until Vincent asked if there is no ctags plug-in, only to know that the original sublime through the plug-in can also realize some of the functions of the large IDE, so Google a bit, This blog is to introduce the next sublime under the frequently used plugins.
Install package Control
Open Sublime Text 2, click Tools, Command Palette to bring up console console;
Paste the following code into the command line and enter:
ImportUrllib2,Os;Pf=' Package Control.sublime-package ';Ipp=Sublime.Installed_packages_path();Os.Makedirs(Ipp)IfNotOs.Path.Exists(Ipp)else none; Open (os. Path. Join (ipp,pf ' WB ' ) . Write (urllib2. Urlopen ( ' http://sublime.wbond.net/' +pf replace ( ","%20 " . Read ())
Restart Sublime Text 2, if you see the package control item in Preferences---settings, the installation is successful.
Installing the Alignment plugin
For some programmers who like to be neat, it's possible to see the following situation as intolerable:
var joe = ‘joe‘;var johnny = ‘john
var joe = ‘joe‘; var johnny = ‘johnny‘; var quaid = ‘quaid‘;
ny‘;var quaid = ‘quaid‘;
Be sure to change it to be safe:
var joe = ‘joe‘;
var johnny = ‘johnny‘;
var quaid = ‘quaid‘;
Sublime Text 2, a Sublime Alignment plugin can also be easily implemented.
1. Press Ctrl + Shift + P to bring up the command panel.
2. Enter the install to bring up the package control:install package option and press ENTER.
3. Locate the Alignment in the list and press ENTER to install.
4. Restart Sublime Text 2 to make it effective. Now you can do the Zicao by selecting the text and pressing Ctrl + Shift + A.
Vim mode
Yes, Sublime Text 2 already supports Vim's editing mode, and if you prefer Vim's editing mode, you can activate Vintage mode by the following methods:
1. Press Ctrl + Shift + P to bring up the command panel.
2. Enter settings user to bring up the Preferences:settings-user and press ENTER.
3. This will open a preferences.sublime-settings file, if it is the first time, it should be an empty file, paste the following text in:
{ "ignored_packages": []}
4. Save this file, then press ESC, and then press some of your familiar Vim commands, is not very cordial?
Installing Soda Themes
The topic here is different from the Color Scheme for the code, which refers to the theme of the Sublime program itself, which can now be installed by Ian Hill's Soda.
Because the source has been added, the installation of this theme can also be done through the package Control, very convenient. Currently the Soda theme offers both light and dark styles.
To activate the method, also modify the Preferences:settings-user:
1. Press Ctrl + Shift + P to bring up the command panel.
2. Enter user settings to bring up Preferences:settings-user and press ENTER.
3. Add the following code to activate the Soda light theme:
{ "theme": "Soda Light.sublime-theme"}
Add the following code to activate the Soda Dark topic:
{ "theme": "Soda Dark.sublime-theme"}
4. The Save takes effect.
Installing the Ctags Plugin
This plug-in can jump across files, to realize the function like Eclipse can trace function, since then more like the sublime. Installation method:
1. Press Ctrl + Shift + P to bring up the command panel.
2. Enter the install to bring up the package control:install package option and press ENTER.
3. Locate the Ctags in the list and press ENTER to install.
4.ubuntu Install Run command: sudo apt-get install exuberant-ctags.
5. In the Sublime project folder right-click, the Ctag:rebuild Tags menu appears. Click on it, and the. tags file will be generated.
Then in your code, the cursor is placed on a function, click ctrl+shift+ left mouse button can jump to function declaration place.
Zen Coding
If you often want to write some front-end code, this plugin is also essential, do not know zencoding classmates recommend to see: "Zen Coding: A quick way to write html/css code"
Git
A plugin that consolidates git and sublime text executes a lot of the commands you need to use.
Sublime Text 2 Plugin