【发布时间】:2016-06-14 23:26:04
【问题描述】:
我一直在使用 sublime-phpfmt 插件没有问题,但一直收到以下错误:
engine file is missing: /Users/iMac/Library/Application Support/Sublime Text 3/Packages/phpfmt/php-cs-fixer
我全局安装了 php-cs-fixer 并按照自述文件中的说明将 php-cs-fixer.phar 文件放入本地目录,但它仍然像这样出现。控制台输出如下:
FileNotFoundError: [Errno 2] No such file or directory: 'phpcs'
我对python一无所知,但它是在寻找不同的文件还是什么?
编辑
插件似乎有些讨价还价,详细信息在这里https://news.ycombinator.com/item?id=11896851 和https://github.com/nanch/sublime-phpfmt 普遍共识是手动安装包并检查旧提交,如下所示:
- 从包控制中删除 phpfmt(如果你是这样安装的)
- 克隆 https://github.com/nanch/sublime-phpfmt.git 到你的包目录(
~/Library/Application Support/Sublime Text 3/Packages在 Mac 上) - cd 到
sublime-phpfmt和git checkout 6125cf9
这对我有用,而且它也不会自动更新(据我所知)。
【问题讨论】:
-
好像
phpfmt已经商业化,需要您购买许可证才能使用它:github.com/phpfmt/issues/issues/17
标签: sublimetext3