解決Sublime Text 3 亂碼

來源:互聯網
上載者:User

轉載自:http://www.1990day.com/solve-sublime-text3-garbled/

1、開啟Sublime Text 3,按Ctrl+~開啟控制行,複製粘貼以下python代碼,然後斷行符號運行。 
複製並粘貼如下代碼:

import urllib.request,os,hashlib; h = 'eb2297e1a458f27d836c04bb0cbaf282' + 'd0e7a3098092775ccb37ca9d6b2e4b7d'; 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)  

如果不能使用,點擊packagecontrol 該網址,在該網址複製新的代碼,並執行。

2、重啟Sublime text3,command+shift+P開啟命令列

輸入 "install package" 最下面有個“=”在一直走,等靜止不動

3、繼續輸入converttoutf8 ,下面也會有提示,點擊

4、如果開啟的時候還是亂碼,並且提示有error。再次執行步驟3然後輸入Codecs33

新遇到的問題,sublime Text 總提示更新,很煩人。

1、找到Preferences -> Settings-User(設定使用者) 
2、在最後一個花括弧結尾(“}”)前添加

    ,"update_check":false

關閉重啟sublime Text即可。

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

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.