Files
bitburner-scripts/build.mjs
Nils Ramstöck de2e43d911 add mirror option
2023-10-12 10:53:49 +02:00

31 lines
677 B
JavaScript

import { context } from 'esbuild';
import { BitburnerPlugin } from 'esbuild-bitburner-plugin';
const createContext = async () => await context({
entryPoints: [
'servers/**/*.js',
'servers/**/*.jsx',
'servers/**/*.ts',
'servers/**/*.tsx',
],
outbase: "./servers",
outdir: "./dist",
plugins: [
BitburnerPlugin({
port: 12525,
types: 'NetscriptDefinitions.d.ts',
mirror: {
'mirror/own': ['home', 'grindr-1', 'grindr-2', 'non'],
'mirror/other': ['n00dles', 'foodnstuff']
}
})
],
bundle: true,
format: 'esm',
platform: 'browser',
logLevel: 'info'
});
let ctx = await createContext();
ctx.watch();