Library for creating, reading and modifying multi-target application descriptor files
npm install mta-libtypescript
import { mta } from "mta-lib";
mta = new mta(projectPath);
let mtaModule: mta.Module = {
name: this.appName,
type: "my-type",
path: path.relative(this.appOptions.projectPath, this.appPath),
parameters: {
"disk-quota": "DISK_QUOTA",
"memory": "MEMORY"
},
requires: [
{
name: this.appoptions.projectName + "suffix"
}
]
};
await mta.addModule(appMtaModule);
...
try{
await mta.save();
} catch (e) {
console.log(e);
}
}
``