/** * Dump summary of all items in the index so far. */ public function dumpItems() { $items = $this->index->getItems(); $dimensions = $this->getApplication()->getTerminalDimensions(); $width = $dimensions[0]; foreach ($items as $item) { $out = substr(sprintf(" %-10s %-30s %-15s %-5s", $item->getID(), $item->getName(), $item->getVersion(), $item->getStatus()), 0, $width); $this->output->writeln($out); } }