ansitty

package module
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 26, 2024 License: MIT Imports: 4 Imported by: 1

README

ansitty GoDoc Build Status Coverage Status

A go package with utilities to enable ANSI escape sequences on terminal output.

Documentation

Overview

Package ansitty provides a function to enable possibility to use ANSI escape sequences in TTY if possible.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Disable

func Disable(writer io.Writer) bool

Disable disables possibility to use ANSI escape sequences in TTY if possible.

func Enable

func Enable(writer io.Writer) bool

Enable enables possibility to use ANSI escape sequences in TTY if possible.

func Stderr

func Stderr() *os.File

Stderr enables possibility to use ANSI escape sequences in TTY if possible to stderr and returns os.Stderr.

func Stdout

func Stdout() *os.File

Stdout enables possibility to use ANSI escape sequences in TTY if possible to stdout and returns os.Stdout.

func Writer

func Writer(writer io.Writer) io.Writer

Writer is a convenience function to enable possibility to use ANSI escape sequences in TTY if possible to writer. It calls Enable on the given writer and returns the same writer.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL