mirror of
https://github.com/pgsty/minio.git
synced 2026-07-20 20:50:22 +03:00
A better way to print prettified json syntax error msg
This commit is contained in:
committed by
Harshavardhana
parent
db293aedb7
commit
b5ea05d839
+28
@@ -0,0 +1,28 @@
|
||||
ts (Terminal Size)
|
||||
==
|
||||
|
||||
[](https://travis-ci.org/olekukonko/ts) [](https://sourcegraph.com/github.com/olekukonko/ts)
|
||||
|
||||
Simple go Application to get Terminal Size. So Many Implementations do not support windows but `ts` has full windows support.
|
||||
Run `go get github.com/olekukonko/ts` to download and install
|
||||
|
||||
#### Example
|
||||
|
||||
```go
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"github.com/olekukonko/ts"
|
||||
)
|
||||
|
||||
func main() {
|
||||
size, _ := ts.GetSize()
|
||||
fmt.Println(size.Col()) // Get Width
|
||||
fmt.Println(size.Row()) // Get Height
|
||||
fmt.Println(size.PosX()) // Get X position
|
||||
fmt.Println(size.PosY()) // Get Y position
|
||||
}
|
||||
```
|
||||
|
||||
[See Documentation](http://godoc.org/github.com/olekukonko/ts)
|
||||
Reference in New Issue
Block a user