From bd8a2dbfd68289a4f025964647320f8ef5e857aa Mon Sep 17 00:00:00 2001 From: Evan Prodromou Date: Mon, 24 Aug 2009 11:23:02 -0400 Subject: test script for schema code --- scripts/showtable.php | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 scripts/showtable.php (limited to 'scripts') diff --git a/scripts/showtable.php b/scripts/showtable.php new file mode 100644 index 000000000..30f0bb5a9 --- /dev/null +++ b/scripts/showtable.php @@ -0,0 +1,41 @@ +#!/usr/bin/env php +. + */ + +define('INSTALLDIR', realpath(dirname(__FILE__) . '/..')); + +$helptext = << +Shows the structure of a table + +END_OF_SHOWTABLE_HELP; + +require_once INSTALLDIR.'/scripts/commandline.inc'; + +if (count($args) != 1) { + show_help(); +} + +$name = $args[0]; + +$schema = Schema::get(); + +$td = $schema->getTableDef($name); + +print_r($td); -- cgit v1.2.3-54-g00ecf