Add live activity progress and logs

This commit is contained in:
Mikei386
2026-06-14 14:26:13 +02:00
parent 5a1b9588e1
commit 3e3c63070e
14 changed files with 254 additions and 38 deletions
+10
View File
@@ -141,6 +141,16 @@ func (q *Queue) Snapshot() []model.Run {
return q.snapshotLocked()
}
func (q *Queue) UpdateActive(id string, update func(*model.Run)) bool {
q.mu.Lock()
defer q.mu.Unlock()
if q.active == nil || q.active.ID != id {
return false
}
update(q.active)
return true
}
func (q *Queue) snapshotLocked() []model.Run {
result := append([]model.Run{}, q.history...)
if q.active != nil {