From e30b74e27baa597f2fec24331809d1757f913906 Mon Sep 17 00:00:00 2001 From: Lonnie Ezell Date: Mon, 28 May 2018 23:54:55 -0500 Subject: [PATCH] New command to list namespaces in app. --- system/Commands/Namespaces.php | 123 +++++++++++++++++++++++++++++++++ 1 file changed, 123 insertions(+) create mode 100644 system/Commands/Namespaces.php diff --git a/system/Commands/Namespaces.php b/system/Commands/Namespaces.php new file mode 100644 index 0000000000..8f1d4e9895 --- /dev/null +++ b/system/Commands/Namespaces.php @@ -0,0 +1,123 @@ +psr4 as $ns => $path) + { + $path = realpath($path) ?? $path; + + $tbody[] = [ + $ns, + realpath($path) ?? $path, + is_dir($path) ? "Yes" : "MISSING" + ]; + } + + $thead = ['Namespace', 'Path', 'Found?']; + + CLI::table($tbody, $thead); + } + +}