You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
boundary/internal/cmd/base/ui.go

26 lines
342 B

// Copyright (c) HashiCorp, Inc.
// SPDX-License-Identifier: BUSL-1.1
package base
import (
"os"
"github.com/mitchellh/cli"
"golang.org/x/term"
)
type BoundaryUI struct {
cli.Ui
Format string
}
var TermWidth uint = 80
func init() {
width, _, err := term.GetSize(int(os.Stdin.Fd()))
if err == nil {
TermWidth = uint(width)
}
}