gat

package
v0.26.0 Latest Latest
Warning

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

Go to latest
Published: Dec 21, 2025 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PrintFormats

func PrintFormats(w io.Writer) error

func PrintLanguages

func PrintLanguages(w io.Writer) error

func PrintThemes

func PrintThemes(w io.Writer, withColor bool) error

Types

type Config

type Config struct {
	Language       string
	Format         string
	Theme          string
	RenderMarkdown bool
	ForceBinary    bool
	NoResize       bool
}

type Gat

type Gat struct {
	// contains filtered or unexported fields
}

func New

func New(cfg *Config) (*Gat, error)

func (*Gat) Print

func (g *Gat) Print(w io.Writer, r io.Reader, opts ...PrintOption) error

type Language added in v0.23.0

type Language struct {
	Name    string
	Aliases []string
}

type PrintOption

type PrintOption func(*printOption)

func WithFilename

func WithFilename(name string) PrintOption

func WithMask added in v0.26.0

func WithMask(m bool) PrintOption

func WithPretty

func WithPretty(p bool) PrintOption

Jump to

Keyboard shortcuts

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