WIP: 5739-useDocker_inSalix #5

Closed
alexm wants to merge 4 commits from 5739-useDocker_inSalix into master
2 changed files with 4 additions and 11 deletions
Showing only changes of commit 857994f166 - Show all commits

View File

@ -6,12 +6,8 @@ const fs = require('fs-extra');
* @param {Connection} conn MySQL connection object
* @returns {Array<Result>} The resultset
*/
async function queryFromFile(conn, file, logger) {
async function queryFromFile(conn, file) {
const sql = await fs.readFile(file, 'utf8');
if(logger){
// console.log('TRY', await this.multiQuery(conn, 'SELECT * FROM vn.saleGroup;'));
// console.log('sql: ', sql);
}
return await this.multiQuery(conn, sql);
}

View File

@ -273,15 +273,12 @@ class Push extends Command {
let err;
try {
console.log(versionDir, script.file);
await connExt.queryFromFile(pushConn,
`${versionsDir}/${versionDir}/${script.file}`, versionDir == '10724-maroonOrchid');
`${versionsDir}/${versionDir}/${script.file}`);
} catch (e) {
err = e;
}
console.log('HOLAAAAAAAAAAAAAAAAAAA')
// console.log(await conn.query(`SELECT * FROM versionLog LIMIT 1`))
// console.log(await conn.query(`SELECT * FROM vn.saleGroup LIMIT 1`))
await conn.query(
`INSERT INTO versionLog
SET code = ?,
@ -305,7 +302,7 @@ class Push extends Command {
]
);
if (err) console.log('FALLO', err);
if (err) throw err;
nChanges++;
}