0

我正在使用带有一些插件的 Sublime Text 2。我似乎无法使用 Phpcs 插件,因为保存文件后,它给了我一个丑陋的错误:

Writing file /Applications/XAMPP/xamppfiles/htdocs/myProject/application/libraries/Authentication.php with encoding UTF-8
Exception in thread Thread-15:
Traceback (most recent call last):
File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/threading.py", line 532, in __bootstrap_inner
self.run()
File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/threading.py", line 484, in run
self.__target(*self.__args, **self.__kwargs)
File "./phpcs.py", line 398, in run
File "./phpcs.py", line 128, in get_errors
File "./phpcs.py", line 194, in execute
File "./phpcs.py", line 197, in parse_report
File "./phpcs.py", line 149, in shell_out
File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/subprocess.py", line 623, in __init__
errread, errwrite)
File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/subprocess.py", line 1141, in _execute_child
raise child_exception
OSError: [Errno 2] No such file or directory

我也尝试查看各自的文件,但我根本不知道 python,所以我不知道该怎么做:-/

能否请你帮忙 ?

4

1 回答 1

0

我最终使用了 SublimeLinter 插件,它提供了我想要从 phpcs 插件中获得的显示潜在错误功能。

该插件位于THIS GITHUB REPO中。

希望这可以帮助任何在使用 phpcs 库时遇到问题的人。

@daniel:感谢您的帮助

于 2013-09-10T15:51:56.570 回答