mirror of
https://github.com/tickstep/aliyunpan.git
synced 2025-01-23 22:42:15 +08:00
fix macOS arm64 version update check error
This commit is contained in:
parent
02b6d529d0
commit
280421fd88
@ -212,9 +212,6 @@ func CheckUpdate(version string, yes bool) {
|
|||||||
|
|
||||||
builder := &strings.Builder{}
|
builder := &strings.Builder{}
|
||||||
builder.WriteString(ReleaseName + "-" + releaseInfo.TagName + "-" + runtime.GOOS + "-.*?")
|
builder.WriteString(ReleaseName + "-" + releaseInfo.TagName + "-" + runtime.GOOS + "-.*?")
|
||||||
if runtime.GOOS == "darwin" && (runtime.GOARCH == "arm" || runtime.GOARCH == "arm64") {
|
|
||||||
builder.WriteString("arm")
|
|
||||||
} else {
|
|
||||||
switch runtime.GOARCH {
|
switch runtime.GOARCH {
|
||||||
case "amd64":
|
case "amd64":
|
||||||
builder.WriteString("(amd64|x86_64|x64)")
|
builder.WriteString("(amd64|x86_64|x64)")
|
||||||
@ -235,7 +232,6 @@ func CheckUpdate(version string, yes bool) {
|
|||||||
default:
|
default:
|
||||||
builder.WriteString(runtime.GOARCH)
|
builder.WriteString(runtime.GOARCH)
|
||||||
}
|
}
|
||||||
}
|
|
||||||
builder.WriteString("\\.zip")
|
builder.WriteString("\\.zip")
|
||||||
|
|
||||||
exp := regexp.MustCompile(builder.String())
|
exp := regexp.MustCompile(builder.String())
|
||||||
|
Loading…
Reference in New Issue
Block a user