implement 'history' command
authorAntoine Musso <hashar@users.mediawiki.org>
Sat, 3 Dec 2005 17:46:21 +0000 (17:46 +0000)
committerAntoine Musso <hashar@users.mediawiki.org>
Sat, 3 Dec 2005 17:46:21 +0000 (17:46 +0000)
maintenance/mcc.php

index a4e1978..9515737 100755 (executable)
@@ -42,6 +42,10 @@ function mccShowHelp($command) {
                        print "delete: deletes something\n";
                if($onlyone) { break; }
 
+               case 'history':
+                       print "history: show command line history\n";
+               if($onlyone) { break; }
+
                case 'dumpmcc':
                        print "dumpmcc: shows the whole thing\n";
                if($onlyone) { break; }
@@ -123,6 +127,14 @@ do {
                        }
                        break;
 
+               case 'history':
+                       if ( function_exists( 'readline_list_history' ) ) {
+                               print_r(readline_list_history());
+                       } else {
+                               print "readline_list_history() not available\n";
+                       }
+                       break;
+
                case 'dumpmcc':
                        var_dump( $mcc );
                        break;