dbgate-api 4.7.4-alpha.15 → 4.7.4-alpha.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.env +7 -6
- package/package.json +5 -5
- package/src/currentVersion.js +2 -2
- package/src/utility/directories.js +11 -1
- package/src/utility/processArgs.js +2 -0
package/.env
CHANGED
|
@@ -4,11 +4,12 @@ DEVMODE=1
|
|
|
4
4
|
# HIDE_APP_EDITOR=1
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
DEVWEB=1
|
|
8
|
-
LOGINS=admin,test
|
|
7
|
+
# DEVWEB=1
|
|
8
|
+
# LOGINS=admin,test
|
|
9
9
|
|
|
10
|
-
LOGIN_PASSWORD_admin=admin
|
|
11
|
-
LOGIN_PERMISSIONS_admin=*
|
|
10
|
+
# LOGIN_PASSWORD_admin=admin
|
|
11
|
+
# LOGIN_PERMISSIONS_admin=*
|
|
12
12
|
|
|
13
|
-
LOGIN_PASSWORD_test=test
|
|
14
|
-
LOGIN_PERMISSIONS_test=~*, widgets/database
|
|
13
|
+
# LOGIN_PASSWORD_test=test
|
|
14
|
+
# LOGIN_PERMISSIONS_test=~*, widgets/database
|
|
15
|
+
# WORKSPACE_DIR=/home/jena/dbgate-data-2
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dbgate-api",
|
|
3
3
|
"main": "src/index.js",
|
|
4
|
-
"version": "4.7.4-alpha.
|
|
4
|
+
"version": "4.7.4-alpha.16",
|
|
5
5
|
"homepage": "https://dbgate.org/",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
@@ -25,9 +25,9 @@
|
|
|
25
25
|
"compare-versions": "^3.6.0",
|
|
26
26
|
"cors": "^2.8.5",
|
|
27
27
|
"cross-env": "^6.0.3",
|
|
28
|
-
"dbgate-query-splitter": "^4.7.4-alpha.
|
|
29
|
-
"dbgate-sqltree": "^4.7.4-alpha.
|
|
30
|
-
"dbgate-tools": "^4.7.4-alpha.
|
|
28
|
+
"dbgate-query-splitter": "^4.7.4-alpha.16",
|
|
29
|
+
"dbgate-sqltree": "^4.7.4-alpha.16",
|
|
30
|
+
"dbgate-tools": "^4.7.4-alpha.16",
|
|
31
31
|
"diff": "^5.0.0",
|
|
32
32
|
"diff2html": "^3.4.13",
|
|
33
33
|
"eslint": "^6.8.0",
|
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
"devDependencies": {
|
|
64
64
|
"@types/fs-extra": "^9.0.11",
|
|
65
65
|
"@types/lodash": "^4.14.149",
|
|
66
|
-
"dbgate-types": "^4.7.4-alpha.
|
|
66
|
+
"dbgate-types": "^4.7.4-alpha.16",
|
|
67
67
|
"env-cmd": "^10.1.0",
|
|
68
68
|
"node-loader": "^1.0.2",
|
|
69
69
|
"nodemon": "^2.0.2",
|
package/src/currentVersion.js
CHANGED
|
@@ -20,8 +20,18 @@ const ensureDirectory = (dir, clean) => {
|
|
|
20
20
|
}
|
|
21
21
|
};
|
|
22
22
|
|
|
23
|
+
function datadirCore() {
|
|
24
|
+
if (process.env.WORKSPACE_DIR) {
|
|
25
|
+
return process.env.WORKSPACE_DIR;
|
|
26
|
+
}
|
|
27
|
+
if (processArgs.workspaceDir) {
|
|
28
|
+
return processArgs.workspaceDir;
|
|
29
|
+
}
|
|
30
|
+
return path.join(os.homedir(), 'dbgate-data');
|
|
31
|
+
}
|
|
32
|
+
|
|
23
33
|
function datadir() {
|
|
24
|
-
const dir =
|
|
34
|
+
const dir = datadirCore();
|
|
25
35
|
ensureDirectory(dir);
|
|
26
36
|
|
|
27
37
|
return dir;
|
|
@@ -10,6 +10,7 @@ const checkParent = process.argv.includes('--checkParent');
|
|
|
10
10
|
const startProcess = getNamedArg('--start-process');
|
|
11
11
|
const isForkedApi = process.argv.includes('--is-forked-api');
|
|
12
12
|
const pluginsDir = getNamedArg('--plugins-dir');
|
|
13
|
+
const workspaceDir = getNamedArg('--workspace-dir');
|
|
13
14
|
|
|
14
15
|
function getPassArgs() {
|
|
15
16
|
const res = [];
|
|
@@ -28,4 +29,5 @@ module.exports = {
|
|
|
28
29
|
isForkedApi,
|
|
29
30
|
getPassArgs,
|
|
30
31
|
pluginsDir,
|
|
32
|
+
workspaceDir,
|
|
31
33
|
};
|