File: README.md

package info (click to toggle)
golang-code.cloudfoundry-bytefmt 0.0~git20190818.854d396-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, forky, sid, trixie
  • size: 104 kB
  • sloc: makefile: 2
file content (15 lines) | stat: -rw-r--r-- 337 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
bytefmt
=======

**Note**: This repository should be imported as `code.cloudfoundry.org/bytefmt`.

Human-readable byte formatter.

Example:

```go
bytefmt.ByteSize(100.5*bytefmt.MEGABYTE) // returns "100.5M"
bytefmt.ByteSize(uint64(1024)) // returns "1K"
```

For documentation, please see http://godoc.org/code.cloudfoundry.org/bytefmt