Skip to content

Latest commit

 

History

History
31 lines (22 loc) · 1 KB

README.md

File metadata and controls

31 lines (22 loc) · 1 KB

ansi

Latest Release Build Status Coverage Status Go ReportCard GoDoc

Raw ANSI sequence helpers

ANSI Writer

import "github.com/muesli/ansi"

w := ansi.Writer{Forward: os.Stdout}
w.Write([]byte("\x1b[31mHello, world!\x1b[0m"))
w.Close()

Compressor

The ANSI compressor eliminates unnecessary/redundant ANSI sequences.

import "github.com/muesli/ansi/compressor"

w := compressor.Writer{Forward: os.Stdout}
w.Write([]byte("\x1b[31mHello, world!\x1b[0m"))
w.Close()