Categorygithub.com/wayneashleyberry/terminal-dimensions
repositorypackage
1.1.0
Repository: https://github.com/wayneashleyberry/terminal-dimensions.git
Documentation: pkg.go.dev

# README

Go Go Reference Go Report Card

go get github.com/wayneashleyberry/terminal-dimensions
package main

import (
	"fmt"

	terminal "github.com/wayneashleyberry/terminal-dimensions"
)

func main() {
	x, y, err := terminal.Dimensions()
	if err != nil {
		panic(err)
	}

	fmt.Printf("Terminal is %d wide and %d high", x, y)
}