Build Sublime Text 2 into a useful IDE

Source: Internet
Author: User

Build Sublime Text 2 into a useful IDE

Speaking of the editor, most people may recommend Vim and Emacs. I have used Vim, which is really powerful, but I am not very used to it. I have always recommended SUblime Text 2 as an editor, then I tried it during this time, and I really liked this editor. For similar editors, I used notepad2, notepad ++, Editplus, UltraEdit, Vim, and TextPad, I didn't think any editor was very easy to use until I met Sublime Text 2. I had been searching for a useful IDE when I wrote a Python script, I have used WingIDE, Ulipad, Pycharm, Eclipse + Pydev, and PyScrypter. None of them really liked it until I met Sublime Text 2, today, let's talk about how to create Sublime Text 2 into a useful IDE. Although it is just an editor, it has a wide range of extensions, it is enough for us to turn it into a good IDE.

1. Download and install

Sublime Text2 is an open-source software that can be used without registration (although there is a pop-up window when it is not registered, it basically does not affect usage ).

: Http://www.sublimetext.com/. please download the package on your own. After the download, install the SDK directly.

The default sublime configuration file is in the C Directory. If a friend feels that the C disk is not suitable, do not directly run sublime after installing sublime, enter % appdata % in the address bar, delete the sublime text 2 folder under the Directory, create a folder named Data in the installation directory of sublime, and then run sublime, all the configuration files about sublime will be stored in the Data directory.

If a friend is not used to the English interface, he can use the Chinese package for localization. I have uploaded the Chinese package to the blog space and can download the package.

Http://files.cnblogs.com/dolphin0520/sublime%E6%B1%89%E5%8C%96.rar package address:

Localization Method:

1. Run sublime text 2;

2. Select preferences> Browse packages ";

3. Find the "Default" folder and copy the extracted file to the "Default" folder to overwrite it.

The following is the running interface after the Chinese version:

The following message is displayed when sublime is disabled:

By default, there will be an update prompt dialog box in sublime. You can disable the update prompt by setting the method:

Select "preferences"-> "Browse packages" to find the Preferences in the Default folder. sublime-settings, add a line at the bottom (note that you must add a comma at the end of the previous line ):

"Update_check": false

Save and exit and restart sublime.

2. Some common settings and shortcut keys

1. Font and theme style settings

When you need to change a theme, you can directly set it through "preferences"-> "color theme:

Only the font size can be changed on the main interface:

To change the font and font size, you can first "preferences"-> "Browse Packages", find the "Default" folder, and then find Preferences. sublime-settings: use Sublime Text 2 to open the file, which saves some common settings,

For example, font, theme style, whether to display the line number, smart prompt delay time, etc. You can set it as needed.

2. Open (close) the sidebar, right thumbnail, and other commonly used panels

By default, Sublime Text 2 does not open the sidebar file browser. You can use "view"-> "sidebar"-> "Hide Sidebar" to open or close the sidebar.

By default, Sublime Text 2 has a file thumbnail on the right. You can open and close the thumbnail through "view"-> "hide mini map.

3. Search for files and defined functions with the shortcut key

In Sublime Text 2, you can quickly switch to the desired file. You only need to press Ctrl + P to open the switch panel.

Enter the name of the file you want to find to quickly switch to the file. If you want to find a function, you can quickly switch to the file that defines the function by entering "@ + function name.

3. Some necessary plug-ins.

The following describes some common plug-ins necessary for Sublime Text 2.

All plug-ins installed in Sublime Text 2 and preset plug-ins are in the Packages file and can be accessed directly through "preferences"-> "Browse Pakcages.

There are two ways to install the plug-in Sublime Text 2:

1) Download the installation package offline, decompress the Packages package, and restart Sublime.

2) install package management plug-in online. Before installing Packages Control, install the package management plug-in as follows:

Select "View"-> "Display Console", and enter the following in the pop-up box:

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 ())

Then press enter to confirm. After the installation is complete, restart sublime. If you find package control in Perferences, the installation is successful.

Then you can open the command panel through "Ctrl + Shift + P" and enter the "install" command to view the installation package list.

We recommend several necessary common plug-ins below:

1. Tag plug-in

The Tag plug-in can provide html and css labels for web developers, which is convenient and convenient for web front-end designers.

2. Prefixr plug-in

Provide some prefixes for css3, such

3. Terminal plug-in

The Terminal plug-in allows you to open the cmd command window in Sublime Text2. It is a practical plug-in. After the plug-in is installed, the shortcut key for opening the cmd command window is

Ctrl + Shift + T.

4. SublimeTmpl plug-in

This plug-in allows users to define file templates. For example, when writing an html file, the introduction information of repeated file headers is cumbersome. You can define a template to directly generate required information, for specific SublimeTmpl plug-in usage, Baidu.

5. SideBarEnhancements plug-in

A plug-in that enhances the browsing function of the sidebar folder.

6. DocBlockr plug-in

The plug-in used to generate the comment block. After installation, enter "/*" and press enter to generate the code comment block.

7. SublimeCodeIntel plug-in

Smart notification plug-in. This plug-in provides a powerful smart notification function. You can customize the prompt content library and set the Python smart prompt (the configuration file path is packages \ SublimeCodeIntel-master \. codeintel \ config:

{"Python": {"python": 'D:/Program Files/Python26/python.exe ', "pythonExtraPaths": ['d:/Program Files/python26', 'd: /Program Files/Python26/DLLs ', 'd:/Program Files/Python26/Lib', 'd:/Program Files/Python26/Lib/plat-win ', 'd: /Program Files/Python26/Lib/lib-tk ', 'd:/Program Files/Python26/Lib/site-packages']}

Build Sublime Text 2 into a useful IDE

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.