We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3b5012c commit e554010Copy full SHA for e554010
cmd/sling/sling_update.go
@@ -223,7 +223,13 @@ func checkUpdate() {
223
if time.Now().Second()%4 != 0 && len(respMap) > 0 {
224
updateVersion = respMap["version_latest"]
225
if isDevChannel {
226
- if core.Version != updateVersion && updateVersion != "" {
+ // convert to slash version for comparison
227
+ parts := strings.Split(strings.TrimSuffix(core.Version, ")"), " (")
228
+ if len(parts) != 2 {
229
+ return
230
+ }
231
+ slashVersion := parts[0] + "/" + parts[1]
232
+ if slashVersion != updateVersion && updateVersion != "" {
233
updateMessage = env.GreenString(g.F("FYI there is a new sling dev build released => %s. You can run `sling update` to download it.", updateVersion))
234
}
235
} else {
0 commit comments