xarxaprod-wp-theme/vendor/wp-cli/php-cli-tools/examples/menu.php

25 lines
416 B
PHP
Raw Permalink Normal View History

2024-01-09 16:13:20 +01:00
<?php
require_once 'common.php';
$menu = array(
'output' => 'Output Examples',
'notify' => 'cli\Notify Examples',
'progress' => 'cli\Progress Examples',
'table' => 'cli\Table Example',
'colors' => 'cli\Colors example',
'quit' => 'Quit',
);
while (true) {
$choice = \cli\menu($menu, null, 'Choose an example');
\cli\line();
if ($choice == 'quit') {
break;
}
include "{$choice}.php";
\cli\line();
}