Documentation ¶
Index ¶
- Constants
- func MakeBracketWrapped[T any](sfw interfaces.StringFormatWriter[T]) interfaces.StringFormatWriter[T]
- func MakeCliFormatFields(truncate CliFormatTruncation, co ColorOptions) *fieldsWriter
- func MakeColor[T any](o ColorOptions, fsw interfaces.StringFormatWriter[T], c ColorType) interfaces.StringFormatWriter[T]
- func MakeDefaultDatePrefixFormatWriter[T any](clock Clock, f interfaces.StringFormatWriter[T]) interfaces.StringFormatWriter[T]
- func MakeDelim[T any](delim string, w1 interfaces.WriterAndStringWriter, ...) func(T) error
- func MakeFunc[T any](f interfaces.FuncStringWriterFormat[T]) interfaces.StringFormatWriter[T]
- func MakeIndentedHeader(o ColorOptions) interfaces.StringFormatWriter[string]
- func MakeQuotedString[T ~string]() interfaces.StringFormatWriter[T]
- func MakeRightAligned() interfaces.StringFormatWriter[string]
- func MakeString[T ~string]() interfaces.StringFormatWriter[T]
- func StringPrefixFromOptions(options options_print.V0) string
- func WriteStringPrefixFormat(w interfaces.WriterAndStringWriter, prefix, body string) (n int64, err error)
- type Box
- type BoxHeader
- type CliFormatTruncation
- type Clock
- type ColorOptions
- type ColorType
- type Date
- type Field
- type HeaderWriter
- type OutputOptions
Constants ¶
View Source
const ( StringDRArrow = "↳" StringNew = "new" StringSame = "same" StringChanged = "changed" StringDeleted = "deleted" StringUpdated = "updated" StringArchived = "archived" StringInternal = "internal" StringUnchanged = "unchanged" StringUntracked = "untracked" StringConflicted = "conflicted" StringRecognized = "recognized" StringCheckedOut = "checked out" StringBlobMissing = "blob missing" StringWouldDelete = "would delete" StringUnrecognized = "unrecognized" StringFormatDateTime = "06-01-02 15:04:05" StringIndent = " " StringIndentWithSpace = " " LenStringMax = len(StringIndent) // TODO-P4 use reflection? ColorTypeNormal = ColorType(colorNone) ColorTypeId = ColorType(colorBlue) ColorTypeHash = ColorType(colorItalic) ColorTypeError = ColorType(colorRed) ColorTypeType = ColorType(colorYellow) ColorTypeUserData = ColorType(colorCyan) ColorTypeHeading = ColorType(colorRed) )
View Source
const ( CliFormatTruncationNone = CliFormatTruncation(iota) CliFormatTruncation66CharEllipsis )
Variables ¶
This section is empty.
Functions ¶
func MakeBracketWrapped ¶
func MakeBracketWrapped[T any]( sfw interfaces.StringFormatWriter[T], ) interfaces.StringFormatWriter[T]
func MakeCliFormatFields ¶
func MakeCliFormatFields( truncate CliFormatTruncation, co ColorOptions, ) *fieldsWriter
func MakeColor ¶
func MakeColor[T any]( o ColorOptions, fsw interfaces.StringFormatWriter[T], c ColorType, ) interfaces.StringFormatWriter[T]
func MakeDefaultDatePrefixFormatWriter ¶
func MakeDefaultDatePrefixFormatWriter[T any]( clock Clock, f interfaces.StringFormatWriter[T], ) interfaces.StringFormatWriter[T]
func MakeDelim ¶
func MakeDelim[T any]( delim string, w1 interfaces.WriterAndStringWriter, f interfaces.StringFormatWriter[T], ) func(T) error
func MakeFunc ¶
func MakeFunc[T any]( f interfaces.FuncStringWriterFormat[T], ) interfaces.StringFormatWriter[T]
func MakeIndentedHeader ¶
func MakeIndentedHeader( o ColorOptions, ) interfaces.StringFormatWriter[string]
func MakeQuotedString ¶
func MakeQuotedString[T ~string]() interfaces.StringFormatWriter[T]
func MakeRightAligned ¶
func MakeRightAligned() interfaces.StringFormatWriter[string]
func MakeString ¶
func MakeString[T ~string]() interfaces.StringFormatWriter[T]
func StringPrefixFromOptions ¶
func StringPrefixFromOptions( options options_print.V0, ) string
func WriteStringPrefixFormat ¶
func WriteStringPrefixFormat( w interfaces.WriterAndStringWriter, prefix, body string, ) (n int64, err error)
Types ¶
type CliFormatTruncation ¶
type CliFormatTruncation int
type ColorOptions ¶
type ColorOptions struct {
OffEntirely bool
}
func (ColorOptions) SetOffEntirely ¶
func (co ColorOptions) SetOffEntirely(v bool) ColorOptions
type Date ¶
type Date[T any] struct { Clock Format string interfaces.StringFormatWriter[T] }
func (*Date[T]) WriteStringFormat ¶
func (f *Date[T]) WriteStringFormat( w interfaces.WriterAndStringWriter, e T, ) (n int64, err error)
type HeaderWriter ¶
type OutputOptions ¶
type OutputOptions struct { ColorOptionsOut ColorOptions ColorOptionsErr ColorOptions }
Click to show internal directories.
Click to hide internal directories.