2024-01-06 05:27:34 +00:00
|
|
|
"use strict";
|
|
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
2024-01-08 20:10:39 +00:00
|
|
|
require("dotenv/config");
|
2024-01-06 05:27:34 +00:00
|
|
|
const log_1 = require("./log");
|
2024-01-08 20:10:39 +00:00
|
|
|
const shell_1 = require("./shell");
|
2024-01-06 05:27:34 +00:00
|
|
|
class Generate {
|
|
|
|
constructor() {
|
|
|
|
this.log = (0, log_1.createLog)('generate');
|
|
|
|
this.log.info(`Generating site: ${new Date()}`);
|
|
|
|
}
|
2024-01-08 20:10:39 +00:00
|
|
|
async checkInbox() {
|
|
|
|
}
|
|
|
|
async img(file) {
|
|
|
|
const cmd = ['bash', 'scripts/img.sh', file];
|
|
|
|
const shell = new shell_1.Shell(cmd);
|
|
|
|
try {
|
|
|
|
await shell.execute();
|
|
|
|
}
|
|
|
|
catch (err) {
|
|
|
|
this.log.error(err);
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
this.log.info(`Processed image file for ${file}`);
|
|
|
|
}
|
2024-01-06 05:27:34 +00:00
|
|
|
}
|
|
|
|
new Generate();
|
|
|
|
//# sourceMappingURL=generate.js.map
|