const require_rolldown_runtime = require('../../../../../../../../_virtual/rolldown_runtime.cjs');
const require_writeJsonIfChanged = require('../writeJsonIfChanged.cjs');
let node_path = require("node:path");
let node_fs_promises = require("node:fs/promises");

//#region ../@intlayer/cli/dist/esm/chokidar/dist/esm/writeConfiguration/index.mjs
const writeConfiguration = async (configuration) => {
	const { content } = configuration;
	const { configDir } = content;
	await (0, node_fs_promises.mkdir)(configDir, { recursive: true });
	await require_writeJsonIfChanged.writeJsonIfChanged((0, node_path.join)(configDir, "configuration.json"), configuration);
};

//#endregion
exports.writeConfiguration = writeConfiguration;
//# sourceMappingURL=index.cjs.map