sublime text3 配置 python

Win8環境下配置python開發IDE。

準備工具:

  1.  編輯器Sublime Text3 下載地址[http://www.sublimetext.com/3](http://www.sublimetext.com/3)
    
  2.  Python-2.7.10   下載地址 [https://www.python.org/downloads/](https://www.python.org/downloads/)
    
     參考文章鏈接:[http://www.cnblogs.com/waising/articles/3466120.html](http://www.cnblogs.com/waising/articles/3466120.html)
    

配置步驟:

     安裝插件方法:

按下Ctrl+Shift+P調出命令面板

輸入install 調出 Install Package 選項并回車,然后在列表中選中要安裝的插件。如圖:

     所有安裝的插件位置:preferences>>package settings
  1.  首先安裝**PackageControl,**用來安裝插件。
    

a. 快捷鍵 ctrl+` 或者 View > Show Console 打開控制臺

b. 粘貼一下代碼到控制臺

import urllib.request,os; pf = 'Package Control.sublime-package'; ipp = sublime.installed_packages_path();urllib.request.install_opener( urllib.request.build_opener(urllib.request.ProxyHandler()) ); open(os.path.join(ipp, pf),'wb').write(urllib.request.urlopen( 'http://sublime.wbond.net/' + pf.replace(' ','%20')).read())

c. 重啟

d. 在Perferences->package settings中看到package control這一項,則安裝成功

2. 安裝插件-Pylinter:

保存自動規范:

{
// Configure pylint's behavior

"pylint_rc":"/Users/daniel/dev/pylintrc",

// Show different icons for errors,warnings, etc.

"use_icons": true,

// Automatically run Pylinter when saving aPython document

"run_on_save": true,

// Don't hide pylint messages when movingthe cursor

"message_stay": true

}

3. SublimeCodeIntel:

** 只能提示:**

{
   "python":"D:/Python27/python.exe",

    "pythonExtraPaths":

        [

            "D:/Python27",

             "D:/Python27/DLLs",

             "D:/Python27/Lib",

            "D:/Python27/Lib/lib-tk",

            "D:/Python27/Lib/site-packages"

        ]

    }

4. PEP8Autoformat :

自動格式化代碼:

 {

"auto_complete": false,

"caret_style": "solid",

"ensure_newline_at_eof_on_save":true,

"find_selected_text": true,

"font_size": 11.0,

"highlight_modified_tabs": true,

"line_padding_bottom": 0,

"line_padding_top": 0,

"scroll_past_end": false,

"show_minimap": false,

"tab_size": 4,

"translate_tabs_to_spaces": true,

"trim_trailing_white_space_on_save": true,

"wide_caret": true,

"word_wrap": true,
}
最后編輯于
?著作權歸作者所有,轉載或內容合作請聯系作者
平臺聲明:文章內容(如有圖片或視頻亦包括在內)由作者上傳并發布,文章內容僅代表作者本人觀點,簡書系信息發布平臺,僅提供信息存儲服務。