UNPKG

@synaptic-simulations/mach

Version:

The last MSFS instrument bundler you'll ever need.

25 lines 1.02 kB
"use strict"; /* * SPDX-FileCopyrightText: 2022 Synaptic Simulations and its contributors * SPDX-License-Identifier: MIT */ Object.defineProperty(exports, "__esModule", { value: true }); exports.machBuild = machBuild; exports.machWatch = machWatch; const esbuild_1 = require("./esbuild"); const logger_1 = require("./logger"); /** * Run a one-off build with provided instruments and arguments. * @returns List of all build results. */ async function machBuild(instruments, args) { return Promise.allSettled(instruments.map((instrument) => (0, esbuild_1.buildInstrument)(args, instrument, new logger_1.BuildLogger(instrument.name, args.verbose)))); } /** * Continuously build instruments when files are updated. * @returns list of initial build results. */ async function machWatch(instruments, args) { return Promise.allSettled(instruments.map((instrument) => (0, esbuild_1.watchInstrument)(args, instrument, new logger_1.BuildLogger(instrument.name, args.verbose)))); } //# sourceMappingURL=mach.js.map