Skip to content
/ ts Public
forked from olekukonko/ts

Simple go Application to get Terminal Size

License

Notifications You must be signed in to change notification settings

Helflym/ts

 
 

Repository files navigation

ts (Terminal Size)

Build Status Total views

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

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

About

Simple go Application to get Terminal Size

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 100.0%