diff options
author | TheArcaneBrony <myrainbowdash949@gmail.com> | 2022-08-19 18:53:25 +0200 |
---|---|---|
committer | TheArcaneBrony <myrainbowdash949@gmail.com> | 2022-08-19 19:07:10 +0200 |
commit | 9071cbdc25e97153086ac48bd389b04c43e56458 (patch) | |
tree | 8b6685ad362f9906fbc7fafcea5d2157c4d8d998 /scripts/build/plugin_resources.js | |
parent | Merge remote-tracking branch 'Puyodead1/patch/prettier-config' into staging (diff) | |
download | server-9071cbdc25e97153086ac48bd389b04c43e56458.tar.xz |
Updates scripts and tests from dev/plugins
Diffstat (limited to 'scripts/build/plugin_resources.js')
-rw-r--r-- | scripts/build/plugin_resources.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/scripts/build/plugin_resources.js b/scripts/build/plugin_resources.js new file mode 100644 index 00000000..5b4b97f2 --- /dev/null +++ b/scripts/build/plugin_resources.js @@ -0,0 +1,13 @@ +const { execSync } = require("child_process"); +const path = require("path"); +const fs = require("fs"); +const { argv, stdout, exit } = require("process"); +const { execIn, parts, getDirs, walk, sanitizeVarName } = require("../utils"); + +module.exports = function (config) { + console.log(`==> Copying all plugin resources...`); + let pluginFiles = walk(config.pluginDir).filter((x) => !x.endsWith(".ts")); + pluginFiles.forEach((x) => { + fs.copyFileSync(x, x.replace("src", "dist")); + }); +}; |