@vbilopav/pgmigrations
Advanced tools
Comparing version 0.21.0 to 0.22.0
@@ -61,2 +61,4 @@ const crypto = require('crypto'); | ||
failureExitCode: -1, | ||
testFunctionsSchemaSimilarTo: "test", | ||
@@ -63,0 +65,0 @@ testFunctionsNameSimilarTo: null, |
@@ -378,3 +378,3 @@ const path = require("path"); | ||
error(`Migration file ${script} contains duplicate version ${version} already present in ${upVersions[version]}. Exiting...`); | ||
process.exit(1); | ||
process.exit(config.failureExitCode); | ||
} | ||
@@ -408,3 +408,3 @@ upVersions[version] = script; | ||
error(`Migration file ${script} contains duplicate version ${version} already present in ${downVersions[version]}. Exiting...`); | ||
process.exit(1); | ||
process.exit(config.failureExitCode); | ||
} | ||
@@ -762,3 +762,3 @@ downVersions[version] = script; | ||
} | ||
process.exit(1); | ||
process.exit(config.failureExitCode); | ||
} else { | ||
@@ -773,3 +773,3 @@ console.info("Migration completed successfully."); | ||
} | ||
process.exit(1); | ||
process.exit(config.failureExitCode); | ||
} | ||
@@ -786,3 +786,3 @@ | ||
} | ||
process.exit(1); | ||
process.exit(config.failureExitCode); | ||
} | ||
@@ -789,0 +789,0 @@ } |
{ | ||
"name": "@vbilopav/pgmigrations", | ||
"version": "0.21.0", | ||
"version": "0.22.0", | ||
"description": "PostgreSQL Migration Tool for Node.js and NPM", | ||
@@ -5,0 +5,0 @@ "author": "vb-consulting", |
@@ -345,5 +345,7 @@ # PgMigrations | ||
Defualt is true. | ||
#### dirsOrderReversed | ||
When `dirsOrderedByName` is true, this will reverse order of directories. | ||
When `dirsOrderedByName` is true, this will reverse order of directories. Defualt is false. | ||
@@ -498,2 +500,6 @@ #### tmpDir | ||
#### failureExitCode | ||
Return this error code on failure. Default is -1. | ||
## Contributing | ||
@@ -500,0 +506,0 @@ |
@@ -112,5 +112,5 @@ const { warning, info, error, passed, failed } = require("./log.js"); | ||
// exit process with non-zero status | ||
process.exit(1); | ||
process.exit(config.failureExitCode); | ||
} | ||
} | ||
81136
1433
513