cmd

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jun 26, 2024 License: BSD-3-Clause-Clear Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Container = lipgloss.NewStyle().Padding(1)
View Source
var DescriptionStyle = lipgloss.NewStyle().Foreground(KeyForeground)
View Source
var ErrorStyle = lipgloss.NewStyle().
	Foreground(lipgloss.Color("#DF2935")).
	PaddingTop(1).
	PaddingBottom(1).
	PaddingLeft(2).
	PaddingRight(2)
View Source
var KeyForeground = lipgloss.AdaptiveColor{Light: "#8D8D8D", Dark: "#5F5F5F"}
View Source
var KeyStyle = lipgloss.NewStyle().
	Foreground(KeyForeground).
	BorderStyle(lipgloss.NormalBorder()).
	BorderBottom(true).
	BorderBottomForeground(KeyForeground).Width(24)
View Source
var TitleForeground = lipgloss.Color("#00BCEB")
View Source
var TitleStyle = lipgloss.NewStyle().Foreground(TitleForeground)
View Source
var ValForeground1 = lipgloss.AdaptiveColor{Light: "#07C592", Dark: "#06D6A0"}
View Source
var ValForeground2 = lipgloss.AdaptiveColor{Light: "#07C592", Dark: "#50D8D7"}
View Source
var ValStyle1 = lipgloss.NewStyle().Foreground(ValForeground1).PaddingLeft(1).Bold(true)
View Source
var ValStyle2 = lipgloss.NewStyle().Foreground(ValForeground2).PaddingLeft(1).Bold(true)

Functions

func Error

func Error(ctx *kong.Context, err error) error

func KeyValue

func KeyValue(ctx *kong.Context, valRenderer lipgloss.Style, key, value string) error

func Run

func Run()

Types

type CLI

type CLI struct {
	Encode Encode `cmd:"encode" aliases:"e" help:"${encode_help}"`
	Decode Decode `cmd:"decode" aliases:"d" help:"${decode_help}"`
}

type Decode

type Decode struct {
	Value string `arg:"" name:"value" help:"Value to decode"`
}

func (*Decode) Run

func (c *Decode) Run(ctx *kong.Context) error

type Encode

type Encode struct {
	Value string `arg:"" name:"value" help:"Value to encode"`
}

func (*Encode) Run

func (c *Encode) Run(ctx *kong.Context) error

Jump to

Keyboard shortcuts

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