join

package
v0.0.0-...-6c7f99c Latest Latest
Warning

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

Go to latest
Published: Jan 26, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package join provides a shell script interface for the lipgloss JoinHorizontal and JoinVertical commands. It allows you to join multi-line text to build different layouts.

For example, you can place two bordered boxes next to each other: Note: We wrap the variable in quotes to ensure the new lines are part of a single argument. Otherwise, the command won't work as expected.

$ gum join --horizontal "$BUBBLE_BOX" "$GUM_BOX"

╔══════════════════════╗╔═════════════╗ ║ ║║ ║ ║ Bubble ║║ Gum ║ ║ ║║ ║ ╚══════════════════════╝╚═════════════╝

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Options

type Options struct {
	Text []string `arg:"" help:"Text to join."`

	Align      string `help:"Text alignment" enum:"left,center,right,bottom,middle,top" default:"left"`
	Horizontal bool   `help:"Join (potentially multi-line) strings horizontally"`
	Vertical   bool   `help:"Join (potentially multi-line) strings vertically"`
}

Options is the set of options that can configure a join.

func (Options) Run

func (o Options) Run() error

Run is the command-line interface for the joining strings through lipgloss.

Jump to

Keyboard shortcuts

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