feat: bootstrap bun toolchain skeleton and smoke test

Co-authored-by: Eriyc <50216491+Eriyc@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2026-03-04 02:54:12 +00:00
parent c5c4e152ab
commit d88a29403a
17 changed files with 261 additions and 1 deletions

21
bun/toolchain.bzl Normal file
View File

@@ -0,0 +1,21 @@
BunToolchainInfo = provider(fields = ["bun_bin", "version"])
def _bun_toolchain_impl(ctx):
return [
platform_common.ToolchainInfo(
bun = BunToolchainInfo(
bun_bin = ctx.executable.bun,
version = ctx.attr.version,
),
),
]
bun_toolchain = rule(
implementation = _bun_toolchain_impl,
attrs = {
"bun": attr.label(allow_single_file = True, executable = True, cfg = "exec"),
"version": attr.string(mandatory = True),
},
)