forked from LeenkxTeam/LNXSDK
Update Files
This commit is contained in:
32
Kha/Tools/khamake/out/Exporters/Exporter.js
Normal file
32
Kha/Tools/khamake/out/Exporters/Exporter.js
Normal file
@ -0,0 +1,32 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.Exporter = void 0;
|
||||
const fs = require("fs-extra");
|
||||
class Exporter {
|
||||
constructor() {
|
||||
}
|
||||
writeFile(file) {
|
||||
this.out = fs.openSync(file, 'w');
|
||||
}
|
||||
closeFile() {
|
||||
fs.closeSync(this.out);
|
||||
}
|
||||
p(line = '', indent = 0) {
|
||||
let tabs = '';
|
||||
for (let i = 0; i < indent; ++i)
|
||||
tabs += '\t';
|
||||
let data = Buffer.from(tabs + line + '\n');
|
||||
fs.writeSync(this.out, data, 0, data.length, null);
|
||||
}
|
||||
copyFile(from, to) {
|
||||
fs.copySync(from, to, { overwrite: true });
|
||||
}
|
||||
copyDirectory(from, to) {
|
||||
fs.copySync(from, to, { overwrite: true });
|
||||
}
|
||||
createDirectory(dir) {
|
||||
fs.ensureDirSync(dir);
|
||||
}
|
||||
}
|
||||
exports.Exporter = Exporter;
|
||||
//# sourceMappingURL=Exporter.js.map
|
Reference in New Issue
Block a user