From 8e2183304589dd01c7d20be89d463ecac1433cdc Mon Sep 17 00:00:00 2001 From: Ludvig Liljenberg Date: Thu, 27 Jul 2023 12:12:58 -0700 Subject: [PATCH] Added .exe extension for buf download to prevent 404 (#2841) * added .exe extension Signed-off-by: Ludvig Liljenberg --- CONTRIBUTORS.md | 1 + mage/setup/tools.go | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index 847a186b5..8891ecb46 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -85,3 +85,4 @@ and we will add you. **All** contributors belong here. 💯 * [Tomi Paananen](https://github.com/tompaana) * [Troy Connor](https://github.com/troy0820) * [Phill Gibson](https://github.com/phillipgibson) +* [Ludvig Liljenberg](https://github.com/ludfjig) diff --git a/mage/setup/tools.go b/mage/setup/tools.go index 189f78883..f28289959 100644 --- a/mage/setup/tools.go +++ b/mage/setup/tools.go @@ -57,6 +57,11 @@ func EnsureBufBuild() { "amd64": "x86_64", }, } + + if runtime.GOOS == "windows" { + opts.Ext = ".exe" + } + err := downloads.DownloadToGopathBin(opts) mgx.Must(err) }