UNPKG

@mastra/core

Version:
26 lines (25 loc) 658 B
import { t as MastraBase } from "../base-BeUQ6mLP.js"; import { readFile } from "fs/promises"; import { parse } from "dotenv"; //#region src/bundler/index.ts var MastraBundler = class extends MastraBase { constructor({ name, component = "BUNDLER" }) { super({ component, name }); } async loadEnvVars() { const envVars = /* @__PURE__ */ new Map(); for (const file of await this.getEnvFiles()) { const config = parse(await readFile(file, "utf-8")); Object.entries(config).forEach(([key, value]) => { envVars.set(key, value); }); } return envVars; } }; //#endregion export { MastraBundler }; //# sourceMappingURL=index.js.map