Skip to content

Commit

Permalink
Change displaying cloning sessions in progress bars: prepend name
Browse files Browse the repository at this point in the history
  • Loading branch information
pkorotkov committed Mar 14, 2016
1 parent 1f3ec1f commit dac6706
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion status-monitor.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package main

import (
"encoding/gob"
. "fmt"
"net"
"os"

Expand Down Expand Up @@ -47,7 +48,7 @@ func monitorStatus(quit chan os.Signal) {
sessions[m.UUID] = uip.AddBar(10000).AppendCompleted()
bar = sessions[m.UUID]
bar.PrependFunc(func(bar *uip.Bar) string {
return m.UUID[:9] + "..."
return Sprintf("%s[%s...%s]", m.Name, m.UUID[0:6], m.UUID[32:36])
})
}
bar.Set(m.Count)
Expand Down

0 comments on commit dac6706

Please sign in to comment.