From 5b6bfc3ecb5051a15b15fb232c73203daecd15f1 Mon Sep 17 00:00:00 2001 From: juampy Date: Tue, 15 Jan 2013 23:12:19 +0100 Subject: [PATCH] Issue #698264 by scor, Wim Leers, dalin, greg.1.anderson, juampy: Better handling of structure-tables and skip-tables options Added an example to add tables with a pattern at examples directory. --- examples/sync_skip_pattern.drush.inc | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 examples/sync_skip_pattern.drush.inc diff --git a/examples/sync_skip_pattern.drush.inc b/examples/sync_skip_pattern.drush.inc new file mode 100644 index 0000000..2518190 --- /dev/null +++ b/examples/sync_skip_pattern.drush.inc @@ -0,0 +1,27 @@ + '-N'), array('output' => FALSE)); + if (isset($result['output'])) { + $skip_tables = explode("\n", $result['output']); + if (count($skip_tables)) { + // Add the list of tables to be skipped to the sql-sync command options. + drush_set_option('skip-tables-key', 'extra-tables'); + drush_set_option('skip-tables', array('extra-tables' => $skip_tables)); + } + } +} -- 1.7.10.4