fix: refs #7759 Change order of myt-run execution #8

Closed
guillermo wants to merge 1 commits from 7759-fixOrder into master
2 changed files with 12 additions and 12 deletions

View File

@ -149,6 +149,17 @@ class Run extends Command {
await server.wait(); await server.wait();
const conn = await myt.createConnection(); const conn = await myt.createConnection();
// Apply changes
const hasTriggers = await fs.exists(`${dumpDataDir}/triggers.sql`);
Object.assign(opts, {
triggers: !hasTriggers,
commit: true,
dbConfig
});
await myt.run(Push, opts);
// Mock date functions // Mock date functions
this.emit('mockingDate'); this.emit('mockingDate');
@ -163,17 +174,6 @@ class Run extends Command {
await connExt.multiQuery(conn, sql); await connExt.multiQuery(conn, sql);
} }
// Apply changes
const hasTriggers = await fs.exists(`${dumpDataDir}/triggers.sql`);
Object.assign(opts, {
triggers: !hasTriggers,
commit: true,
dbConfig
});
await myt.run(Push, opts);
// Apply fixtures // Apply fixtures
this.emit('applyingFixtures'); this.emit('applyingFixtures');

View File

@ -1,6 +1,6 @@
{ {
"name": "@verdnatura/myt", "name": "@verdnatura/myt",
"version": "1.6.12", "version": "1.6.13",
"author": "Verdnatura Levante SL", "author": "Verdnatura Levante SL",
"description": "MySQL version control", "description": "MySQL version control",
"license": "GPL-3.0", "license": "GPL-3.0",