function drush_xhprof_list in XHProf 8
Same name and namespace in other branches
- 6 xhprof.drush.inc \drush_xhprof_list()
- 7 xhprof.drush.inc \drush_xhprof_list()
A command callback.
File
- ./
xhprof.drush.inc, line 105
Code
function drush_xhprof_list() {
$runs = drush_xhprof_get_runs();
$rows = [];
$headers = [];
foreach ($runs as $run) {
$row = [];
foreach ($run as $key => $value) {
if (!in_array($key, $headers)) {
$headers[] = $key;
}
$row[] = $value;
}
$rows[] = array_reverse($row);
}
$headers = array_reverse($headers);
array_unshift($rows, $headers);
drush_print_table($rows, TRUE);
}