"use strict";
/* Socket Lib - Built with rolldown */
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
const require_smol_vfs = require('../../smol/vfs.js');

//#region src/external-tools/sbt/from-vfs.ts
/**
* @file `sbtFromVfs()` — extracts the SBT launcher jar from the smol binary's
*   VFS. Uses the post-alignment `getSmolVfs()` API. The smol-btm builder packs
*   only the launcher (~1.5 MB); the actual SBT distribution downloads into the
*   user's `~/.sbt/boot/` on first run when the launcher reads
*   `project/build.properties`. Returns `undefined` when the binary doesn't
*   have SBT bundled.
*/
/**
* Relative VFS key for the bundled SBT launcher jar.
*/
const SBT_VFS_KEY = "sbt-launch.jar";
async function sbtFromVfs() {
	const vfs = /* @__PURE__ */ require_smol_vfs.getSmolVfs();
	if (!vfs) return;
	/* c8 ignore start - smol Node binary only. */
	if (!vfs.has("sbt-launch.jar")) return;
	return {
		path: await vfs.extract(SBT_VFS_KEY),
		isJar: true,
		source: "vfs"
	};
	/* c8 ignore stop */
}

//#endregion
exports.SBT_VFS_KEY = SBT_VFS_KEY;
exports.sbtFromVfs = sbtFromVfs;