Something went wrong. Try again.
source dump of claude code forked from oppi.li/claude-code
Something went wrong. Try again.
618 B · 22 lines
TypeScript
at main
1234567891011121314151617181920212223/** * Detects if the current runtime is Bun. * Returns true when: * - Running a JS file via the `bun` command * - Running a Bun-compiled standalone executable */export function isRunningWithBun(): boolean { // https://bun.com/guides/util/detect-bun return process.versions.bun !== undefined}
/** * Detects if running as a Bun-compiled standalone executable. * This checks for embedded files which are present in compiled binaries. */export function isInBundledMode(): boolean { return ( typeof Bun !== 'undefined' && Array.isArray(Bun.embeddedFiles) && Bun.embeddedFiles.length > 0 )}