Open weitzman opened 10 years ago
I suppose the reason why CLI was chosen to be excluded is because xhprof interface relies on SERVER_NAME and similar environment variables. This would require either a separate interface for the CLI script execution index or default values to something like "CLI-ENV" and use file path instead of server name.
yes, i think we can find good analogies for those env variables when
running cli requests. implode(' ', $_SERVER["argv"])
is a good value for
REQUEST_URI.
I think CLI support by default would be a great addition. I might need to get it working for a project, if I do I will open a PR.
I would definitly accept a PR against https://github.com/staabm/xhprof.io for CLI support.
:+1:
The prepend and append includes specifically do not support CLI requests. Is that a design choice or merely "noone has written it"? I'm interested in contributing this if there is interest. Any guidelines/tips would be appreciated.