php代码美化程序PHP_Beautifier试用手记

在pear的rss列表上看到了PHP_Beautifier 0.1.1 beta发布,便下载回来试用:
>>pear install PHP_Beautifier
………………………………………..

顺利完成,看了下帮助,还带有命令行工具,方便:

D:xamppphp>php_beautifier –help

Usage: php_beautifier [options]
and/or can be ‘-‘, which means stdin/stdout.
you can use ? and * for batch processing
can be a dir (ending with ‘/’ or a real dir)
or a file (without ‘/’)
multiple ins and one out = merge all files in one output
Options:
–input or -f input file – default: stdin
–output or -o output dir or file – default: stdout
–indent_tabs or -t indent with tabs
–indent_spaces or -s indent with spaces – default
–filters or -l Add filter(s)
–directory_filters or -d Include dirs for filters
–compress or -c Compress output
–recursive or -r Search in subdir recursively
–help or -? display help/usage (this message)

Filter definition:
–filters "Filter1(setting1=value1,setting2=’value2′) Filter2()"

不过试用下来,处理的不是太完美,比如复杂点php代码美化后不整齐之类的,期待更好的版本出现 [@more@]

Leave a Reply

Your email address will not be published.