This commit is contained in:
Juan Ferrer 2020-12-04 11:53:11 +01:00
parent 598ecbc535
commit ab81ffb551
4 changed files with 12 additions and 9 deletions

View File

@ -2,7 +2,7 @@
const MyVC = require('./index');
const fs = require('fs-extra');
const path = require('path');
const docker = require('./docker').docker;
const docker = require('./docker');
/**
* Dumps structure and fixtures from remote.

View File

@ -1,7 +1,7 @@
const MyVC = require('./index');
const fs = require('fs-extra');
const path = require('path');
const nodegit = require('nodegit');
/**
* Pushes changes to remote.
@ -132,7 +132,7 @@ class Push {
nChanges++;
}
//await this.updateVersion(nChanges, 'number', dirVersion);
await this.updateVersion(nChanges, 'number', dirVersion);
}
}
@ -205,8 +205,11 @@ class Push {
await pushConn.end();
if (nRoutines > 0) {
const repo = await nodegit.Repository.open(this.opts.workspace);
const head = await repo.getHeadCommit();
await conn.query('FLUSH PRIVILEGES');
//await this.updateVersion(nRoutines, 'gitCommit', version.gitCommit);
await this.updateVersion(nRoutines, 'gitCommit', head.sha());
console.log(` -> ${nRoutines} routines have changed.`);
} else

8
package-lock.json generated
View File

@ -1,6 +1,6 @@
{
"name": "myvc",
"version": "1.1.0",
"version": "1.1.1",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
@ -47,9 +47,9 @@
}
},
"@types/node": {
"version": "14.14.8",
"resolved": "https://registry.npmjs.org/@types/node/-/node-14.14.8.tgz",
"integrity": "sha512-z/5Yd59dCKI5kbxauAJgw6dLPzW+TNOItNE00PkpzNwUIEwdj/Lsqwq94H5DdYBX7C13aRA0CY32BK76+neEUA=="
"version": "14.14.10",
"resolved": "https://registry.npmjs.org/@types/node/-/node-14.14.10.tgz",
"integrity": "sha512-J32dgx2hw8vXrSbu4ZlVhn1Nm3GbeCFNw2FWL8S5QKucHGY0cyNwjdQdO+KMBZ4wpmC7KhLCiNsdk1RFRIYUQQ=="
},
"@types/responselike": {
"version": "1.0.0",

View File

@ -1,6 +1,6 @@
{
"name": "myvc",
"version": "1.1.1",
"version": "1.1.2",
"author": "Verdnatura Levante SL",
"description": "MySQL Version Control",
"license": "GPL-3.0",