Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
ollama
Commits
95b9acd3
Commit
95b9acd3
authored
Nov 19, 2023
by
Jeffrey Morgan
Browse files
improve pull percentage rendering
parent
04cbf5cc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
progress/bar.go
progress/bar.go
+2
-1
No files found.
progress/bar.go
View file @
95b9acd3
...
@@ -2,6 +2,7 @@ package progress
...
@@ -2,6 +2,7 @@ package progress
import
(
import
(
"fmt"
"fmt"
"math"
"os"
"os"
"strings"
"strings"
"time"
"time"
...
@@ -55,7 +56,7 @@ func (b *Bar) String() string {
...
@@ -55,7 +56,7 @@ func (b *Bar) String() string {
pre
.
WriteString
(
" "
)
pre
.
WriteString
(
" "
)
}
}
fmt
.
Fprintf
(
&
pre
,
"%.0f%% "
,
b
.
percent
())
fmt
.
Fprintf
(
&
pre
,
"%
3
.0f%% "
,
math
.
Floor
(
b
.
percent
())
)
fmt
.
Fprintf
(
&
suf
,
"(%s/%s, %s/s, %s)"
,
fmt
.
Fprintf
(
&
suf
,
"(%s/%s, %s/s, %s)"
,
format
.
HumanBytes
(
b
.
currentValue
),
format
.
HumanBytes
(
b
.
currentValue
),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment