We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0793a11 commit 3649ddbCopy full SHA for 3649ddb
1 file changed
pkg/client/pull/events/progress.go
@@ -22,3 +22,10 @@ func (p Progress) HumanCurrent() string {
22
func (p Progress) HumanTotal() string {
23
return units.HumanSize(float64(p.Total))
24
}
25
+
26
+func (p Progress) Number() float32 {
27
+ if p.Total == 0 {
28
+ return 0
29
+ }
30
+ return float32(p.Current) / float32(p.Total)
31
+}
0 commit comments