lib

package
v1.0.7 Latest Latest
Warning

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

Go to latest
Published: Oct 11, 2022 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// command line flags
	Debug            bool
	XtendedOut       bool
	NoNumbering      bool
	ShowVersion      bool
	Columns          string
	UseColumns       []int
	DefaultSeparator string = `(\s\s+|\t)`
	Separator        string = `(\s\s+|\t)`
	OutflagExtended  bool
	OutflagMarkdown  bool
	OutflagOrgtable  bool
	OutflagShell     bool
	OutputMode       string
	InvertMatch      bool
	Pattern          string

	/*
	 FIXME: make configurable somehow, config file or ENV
	 see https://github.com/gookit/color will be set by
	 io.ProcessFiles() according to currently supported
	 color mode.
	*/
	MatchFG string
	MatchBG string
	NoColor bool

	// colors to be used per supported color mode
	Colors = map[color.Level]map[string]string{
		color.Level16: map[string]string{
			"bg": "green", "fg": "black",
		},
		color.Level256: map[string]string{
			"bg": "lightGreen", "fg": "black",
		},
		color.LevelRgb: map[string]string{

			"bg": "lightGreen", "fg": "black",
		},
	}

	// main program version
	Version = "v1.0.7"

	// generated  version string, used  by -v contains  lib.Version on
	//  main  branch,   and  lib.Version-$branch-$lastcommit-$date  on
	// development branch
	VERSION string
)

Functions

func PrepareColumns

func PrepareColumns() error

func PrepareModeFlags

func PrepareModeFlags() error

func ProcessFiles

func ProcessFiles(args []string) error

Types

type Tabdata

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

contains a whole parsed table

Jump to

Keyboard shortcuts

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