testeranto 0.79.33 → 0.79.35
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/dist/common/Project.js +1 -0
- package/dist/common/Puppeteer.js +5 -4
- package/dist/common/TaskManBackEnd.js +4 -2
- package/dist/common/tsconfig.common.tsbuildinfo +1 -1
- package/dist/module/Project.js +1 -0
- package/dist/module/Puppeteer.js +5 -4
- package/dist/module/TaskManBackEnd.js +4 -2
- package/dist/module/tsconfig.module.tsbuildinfo +1 -1
- package/dist/prebuild/TaskManBackEnd.mjs +13 -2
- package/dist/types/Puppeteer.d.ts +2 -1
- package/dist/types/TaskManBackEnd.d.ts +2 -1
- package/dist/types/tsconfig.types.tsbuildinfo +1 -1
- package/package.json +2 -2
- package/src/Project.ts +12 -0
- package/src/Puppeteer.ts +15 -6
- package/src/TaskManBackEnd.ts +18 -2
package/dist/common/Project.js
CHANGED
|
@@ -60,6 +60,7 @@ class ITProject {
|
|
|
60
60
|
constructor(config) {
|
|
61
61
|
this.mode = `up`;
|
|
62
62
|
this.config = config;
|
|
63
|
+
fs_1.default.writeFileSync(`${config.outdir}/testeranto.json`, JSON.stringify(Object.assign(Object.assign({}, config), { buildDir: process.cwd() + "/" + config.outdir }), null, 2));
|
|
63
64
|
Promise.resolve(Promise.all([...this.getSecondaryEndpointsPoints("web")].map(async (sourceFilePath) => {
|
|
64
65
|
const sourceFileSplit = sourceFilePath.split("/");
|
|
65
66
|
const sourceDir = sourceFileSplit.slice(0, -1);
|
package/dist/common/Puppeteer.js
CHANGED
|
@@ -5,7 +5,6 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
const readline_1 = __importDefault(require("readline"));
|
|
7
7
|
const fs_1 = __importDefault(require("fs"));
|
|
8
|
-
const jsonc_1 = require("jsonc");
|
|
9
8
|
const main_js_1 = require("./PM/main.js");
|
|
10
9
|
const utils_js_1 = require("./utils.js");
|
|
11
10
|
var mode = process.argv[2] === "-dev" ? "DEV" : "PROD";
|
|
@@ -21,8 +20,11 @@ process.stdin.on("keypress", (str, key) => {
|
|
|
21
20
|
process.exit();
|
|
22
21
|
}
|
|
23
22
|
});
|
|
24
|
-
|
|
25
|
-
|
|
23
|
+
exports.default = async (configs) => {
|
|
24
|
+
fs_1.default.writeFileSync(`${configs.outdir}/testeranto.json`, JSON.stringify(Object.assign(Object.assign({}, configs), { buildDir: process.cwd() + "/" + configs.outdir }), null, 2));
|
|
25
|
+
// const configs = jsonc.parse(
|
|
26
|
+
// (await fs.readFileSync("./docs/testeranto.json")).toString()
|
|
27
|
+
// ) as IBuiltConfig;
|
|
26
28
|
const pm = new main_js_1.PM_Main(configs);
|
|
27
29
|
await pm.startPuppeteer({
|
|
28
30
|
waitForInitialPage: false,
|
|
@@ -101,4 +103,3 @@ const main = async () => {
|
|
|
101
103
|
}
|
|
102
104
|
});
|
|
103
105
|
};
|
|
104
|
-
main();
|
|
@@ -19,7 +19,6 @@ const mongooseSchemas_1 = require("./mongooseSchemas");
|
|
|
19
19
|
// },
|
|
20
20
|
// ],
|
|
21
21
|
// });
|
|
22
|
-
const app = (0, express_1.default)();
|
|
23
22
|
const port = 3000;
|
|
24
23
|
function findTextFiles(dir, fileList = []) {
|
|
25
24
|
const files = fs_1.default.readdirSync(dir);
|
|
@@ -60,7 +59,9 @@ function listToTree(fileList) {
|
|
|
60
59
|
}
|
|
61
60
|
return root.children;
|
|
62
61
|
}
|
|
63
|
-
exports.default = () => {
|
|
62
|
+
exports.default = (config) => {
|
|
63
|
+
fs_1.default.writeFileSync(`${config.outdir}/testeranto.json`, JSON.stringify(Object.assign(Object.assign({}, config), { buildDir: process.cwd() + "/" + config.outdir }), null, 2));
|
|
64
|
+
const app = (0, express_1.default)();
|
|
64
65
|
new mongodb_1.MongoClient(`mongodb://${process.env.MONGO_HOST || "127.0.0.1"}:27017`)
|
|
65
66
|
.connect()
|
|
66
67
|
.then(async (conn) => {
|
|
@@ -98,6 +99,7 @@ exports.default = () => {
|
|
|
98
99
|
// });
|
|
99
100
|
app.get("/testeranto.json", (req, res) => {
|
|
100
101
|
res.sendFile(`${process.cwd()}/docs/testeranto.json`);
|
|
102
|
+
// res.json(config);
|
|
101
103
|
});
|
|
102
104
|
app.get("/", (req, res) => {
|
|
103
105
|
res.send(`<!DOCTYPE html>
|