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
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
}