2016-05-15 01:22:46 +02:00
|
|
|
#!/bin/bash
|
|
|
|
# DELETE ALL TABLES
|
2018-04-27 01:01:12 +02:00
|
|
|
TABLES=$(mysql --host ${MYSQL_HOST} --port ${MYSQL_PORT} -u root development -e "SHOW TABLES IN development;" | awk '{ print $1}' | grep -v '^Tables')
|
2016-05-15 01:22:46 +02:00
|
|
|
|
|
|
|
for t in $TABLES
|
|
|
|
do
|
2018-04-27 01:01:12 +02:00
|
|
|
mysql --host ${MYSQL_HOST} --port ${MYSQL_PORT} -u root development -e "DROP TABLE $t"
|
2016-05-15 01:22:46 +02:00
|
|
|
done
|