在 Sublime Text 2 中,我需要采取哪些步骤才能使 Laravel Blade 模板引擎的语法高亮显示工作?
如 http://daylerees.com/2012/04/06/notable-blade-syntax-support-by-medalink/ 中所述,我拿了https://github.com/Medalink/Laravel-Blade ,解压缩并将文件夹复制到 Sublime 的包文件夹中。
但是,它似乎不起作用(见截图),即使我使用 Tools\Command Palette...\Set Syntax: Blade 手动设置它
这是否仅适用于特定的配色方案(如果是,是哪些),还是我错过了什么? (我今天刚开始使用 Sublime Text)
最佳答案
为 Sublime Text 2 安装插件的最简单方法是通过包控制。
To install Package Control :
Installation is through the Sublime Text 2 console. This is accessed via the ctrl+` shortcut. Once open, paste the following command into the console:
import urllib2,os; pf='Package Control.sublime-package'; ipp=sublime.installed_packages_path(); os.makedirs(ipp) if not os.path.exists(ipp) else None; urllib2.install_opener(urllib2.build_opener(urllib2.ProxyHandler())); open(os.path.join(ipp,pf),'wb').write(urllib2.urlopen('http://sublime.wbond.net/'+pf.replace(' ','%20')).read()); print 'Please restart Sublime Text to finish installation' This command creates the Installed Packages folder for you (if necessary), and then downloads the Package Control.sublime-package into it.
安装包控制后,安装 Blade 语法高亮器所需要做的就是:
关于sublimetext2 - Sublime Text 2 中 Laravel Blade 模板引擎的语法高亮显示,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14278935/