Skip to content

Commit 85828ed

Browse files
committed
fix(tinygo): use .zip extension for Windows Go downloads
Windows Go distributions use .zip format, not .tar.gz: Failing: https://go.dev/dl/go1.25.3.windows-amd64.tar.gz (404) Correct: https://go.dev/dl/go1.25.3.windows-amd64.zip (✓) Added conditional logic to select the correct archive format: - Windows: .zip - Linux/macOS: .tar.gz This fixes TinyGo toolchain setup on Windows.
1 parent 39a12e2 commit 85828ed

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

toolchains/tinygo_toolchain.bzl

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,9 @@ def _download_go(repository_ctx, version, platform):
4646
if not go_platform:
4747
fail("Unsupported platform for Go SDK: {}".format(platform))
4848

49-
go_url = "https://go.dev/dl/go{}.{}.tar.gz".format(go_version, go_platform)
49+
# Windows uses .zip, others use .tar.gz
50+
go_extension = ".zip" if platform == "windows_amd64" else ".tar.gz"
51+
go_url = "https://go.dev/dl/go{}.{}{}".format(go_version, go_platform, go_extension)
5052

5153
print("Downloading Go {} for TinyGo from: {}".format(go_version, go_url))
5254

0 commit comments

Comments
 (0)