From 3133770a1ff257b2c44bdad69620af6c7629f61e Mon Sep 17 00:00:00 2001 From: peefy Date: Tue, 1 Aug 2023 16:41:07 +0800 Subject: [PATCH] feat: add arch and os in the version string --- install.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/install.go b/install.go index 5c30b767..10913fe2 100644 --- a/install.go +++ b/install.go @@ -1,6 +1,7 @@ package kclvm_artifact import ( + "fmt" "os" "os/exec" "path/filepath" @@ -37,7 +38,7 @@ func checkVersion(kclvmVersionDir string) (bool, error) { return false, err } - return KCLVM_VERSION == string(version), nil + return fmt.Sprintf("%s-%s-%s", KCLVM_VERSION, runtime.GOOS, runtime.GOARCH) == string(version), nil }