diff options
author | Joas Schilling <nickvergessen@gmx.de> | 2014-03-23 13:50:57 +0100 |
---|---|---|
committer | Joas Schilling <nickvergessen@gmx.de> | 2014-03-29 10:54:06 +0100 |
commit | 9d56e60c6692e461644b29e2db0cc14fa9a1040a (patch) | |
tree | 6638cbc5aebe361ccdd10ce9a900a52777d82568 | |
parent | 34677006702941a3ed9313d1c3f1fde44a021413 (diff) | |
download | forums-9d56e60c6692e461644b29e2db0cc14fa9a1040a.tar forums-9d56e60c6692e461644b29e2db0cc14fa9a1040a.tar.gz forums-9d56e60c6692e461644b29e2db0cc14fa9a1040a.tar.bz2 forums-9d56e60c6692e461644b29e2db0cc14fa9a1040a.tar.xz forums-9d56e60c6692e461644b29e2db0cc14fa9a1040a.zip |
[ticket/11459] Use new migration/schema_generator to create schema files
PHPBB3-11459
-rw-r--r-- | phpBB/develop/create_schema_files.php | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/phpBB/develop/create_schema_files.php b/phpBB/develop/create_schema_files.php index dcbe5ec66d..890a113f3f 100644 --- a/phpBB/develop/create_schema_files.php +++ b/phpBB/develop/create_schema_files.php @@ -19,9 +19,19 @@ if (!is_writable($schema_path)) } define('IN_PHPBB', true); - -require(dirname(__FILE__) . '/../phpbb/db/tools.php'); - +define('IN_INSTALL', true); +$phpbb_root_path = (defined('PHPBB_ROOT_PATH')) ? PHPBB_ROOT_PATH : './../'; +$phpEx = substr(strrchr(__FILE__, '.'), 1); +include($phpbb_root_path . 'common.' . $phpEx); + +$phpbb_extension_manager = $phpbb_container->get('ext.manager'); +$finder = $finder + ->core_path('phpbb/db/migration/data/') + ->extension_prefix('migration/'); +$db_tools = new \phpbb\db\tools($db, true); + +$schema_generator = new \phpbb\db\migration\schema_generator($finder, $config, $db, $db_tools, $phpbb_root_path, $phpEx, $table_prefix); +$schema_data = $schema_generator->get_schema(); $dbms_type_map = phpbb\db\tools::get_dbms_type_map(); // A list of types being unsigned for better reference in some db's |