有没有任何免费的cmd行脚本可以重新格式化PHP源代码? [英] Are there any free cmd-line scripts which can re-format PHP source-code?

查看:133
本文介绍了有没有任何免费的cmd行脚本可以重新格式化PHP源代码?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用一个预提交钩子来检查我们的工作人员提交的PHP源代码,每个人都对结果感到满意。工作人员已经同意,让代码重新格式化以遵循(可定制)样式规则提交将是有用的。有没有可以从命令行执行此操作的任何FOSS脚本?

I'm using a pre-commit hook to lint-check PHP source submitted by our staff, and everyone's really happy with the results. The staff have agreed it would be useful to have the code re-formatted to follow (customizable) style rules on commit. Are there any FOSS scripts which can do this from the command-line?

推荐答案

正在寻找同样的东西,刚刚遇到PEAR存储库中的PHP Beautfier包:

Was looking for the same thing, just came across the PHP Beautfier package in the PEAR repository:

http://pear.php.net/package/PHP_Beautifier

希望这有助!

这篇关于有没有任何免费的cmd行脚本可以重新格式化PHP源代码?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆