diff options
author | Minteck <46352972+Minteck@users.noreply.github.com> | 2021-07-20 01:30:23 +0200 |
---|---|---|
committer | Minteck <46352972+Minteck@users.noreply.github.com> | 2021-07-20 01:30:23 +0200 |
commit | 44210691ee8444509ac466a362337af77f2bcd49 (patch) | |
tree | 4dc2f242cf5fd4daa3fc6f9e42516e7d55b73538 /modding/compiler.js | |
parent | efa5fc926071de7087836d399c42f53e701b4cff (diff) | |
download | kartik-client-44210691ee8444509ac466a362337af77f2bcd49.tar.gz kartik-client-44210691ee8444509ac466a362337af77f2bcd49.tar.bz2 kartik-client-44210691ee8444509ac466a362337af77f2bcd49.zip |
Commit
Diffstat (limited to 'modding/compiler.js')
-rw-r--r-- | modding/compiler.js | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/modding/compiler.js b/modding/compiler.js new file mode 100644 index 0000000..240c9a9 --- /dev/null +++ b/modding/compiler.js @@ -0,0 +1,17 @@ +class BuildError extends Error { + constructor(orig, ...params) { + super(...params); + this.name = "BuildError"; + this.stack = this.stack + "\n" + orig.stack; + } +} + +const tsbuild = require('../typescript/builder'); + +for (file of importedTypeScriptFiles) { + try { + tsbuild(file.file, homedir + "/.kartik/build/" + file.output); + } catch (e) { + throw new BuildError(e, "Error while building " + file.file + " from package " + file.pkg) + } +}
\ No newline at end of file |