Skip to content

Commit e48f934

Browse files
committed
Run commands before loading wp
1 parent 81cb071 commit e48f934

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/SQLite_Command.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ class SQLite_Command extends WP_CLI_Command {
2020
* # Import the database from a file
2121
* $ wp sqlite import wordpress_dbase.sql
2222
* Success: Imported from 'import wordpress_dbase.sql'.
23+
*
24+
* @when before_wp_load
2325
*/
2426
public function import( $args, $assoc_args ) {
2527

@@ -73,6 +75,8 @@ public function import( $args, $assoc_args ) {
7375
* # Export all tables except specific tables
7476
* $ wp sqlite export --exclude_tables=wp_posts,wp_users
7577
* Success: Exported to 'wordpress_dbase.sql'.
78+
*
79+
* @when before_wp_load
7680
*/
7781
public function export( $args, $assoc_args ) {
7882
WP_CLI::success( 'Exporting database...' );

0 commit comments

Comments
 (0)