From 64c47cbbb3f0825432876786fb72737089732f55 Mon Sep 17 00:00:00 2001 From: Christian Rocha Date: Sun, 26 Apr 2026 20:01:01 -0400 Subject: [PATCH] fix(ui): restore 'update available' notification --- internal/ui/model/ui.go | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/internal/ui/model/ui.go b/internal/ui/model/ui.go index 46d96e9c358091075d82cfd4eb260f3c48fa0dd6..8ffe3b69df8d657011839bf5aa289808d1ef79e4 100644 --- a/internal/ui/model/ui.go +++ b/internal/ui/model/ui.go @@ -864,6 +864,18 @@ func (m *UI) Update(msg tea.Msg) (tea.Model, tea.Cmd) { ttl = DefaultStatusTTL } cmds = append(cmds, clearInfoMsgCmd(ttl)) + case app.UpdateAvailableMsg: + text := fmt.Sprintf("Crush update available: v%s → v%s.", msg.CurrentVersion, msg.LatestVersion) + if msg.IsDevelopment { + text = fmt.Sprintf("This is a development version of Crush. The latest version is v%s.", msg.LatestVersion) + } + ttl := 10 * time.Second + m.status.SetInfoMsg(util.InfoMsg{ + Type: util.InfoTypeUpdate, + Msg: text, + TTL: ttl, + }) + cmds = append(cmds, clearInfoMsgCmd(ttl)) case util.ClearStatusMsg: m.status.ClearInfoMsg() case completions.CompletionItemsLoadedMsg: