diff --git a/bunfig.toml b/bunfig.toml new file mode 100644 index 000000000..9a5d6cceb --- /dev/null +++ b/bunfig.toml @@ -0,0 +1,13 @@ +# Bun configuration file + +[test] +preload = ["./packages/ai/src/types.d.ts"] + +# Configure loaders for different file types +[loader] +# Load .txt files as text content +".txt" = "text" + +# Development path mappings - uncomment to use source files directly +# [install.scopes] +# "@buster/ai" = { "path" = "./packages/ai/src" } \ No newline at end of file diff --git a/packages/ai/package.json b/packages/ai/package.json index 6d6a54f5b..7e469cee9 100644 --- a/packages/ai/package.json +++ b/packages/ai/package.json @@ -6,16 +6,18 @@ "exports": { ".": { "types": "./dist/index.d.ts", + "bun": "./src/index.ts", "default": "./dist/index.js" }, "./*": { "types": "./dist/*.d.ts", + "bun": "./src/*.ts", "default": "./dist/*.js" } }, "scripts": { "prebuild": "[ \"$SKIP_ENV_CHECK\" = \"true\" ] || tsx scripts/validate-env.ts", - "build": "tsc", + "build": "tsc && (cd src && find . -name '*.txt' -exec sh -c 'mkdir -p ../dist/$(dirname {}) && cp {} ../dist/{}' \\;) || true", "build:dry-run": "tsc", "typecheck": "tsc --noEmit", "dev": "tsc --watch",