text

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2026 License: MIT Imports: 11 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package text groups the tools that work on plain text.

Index

Constants

View Source
const (
	LangUnified = "diff"
	LangSide    = "diff-side"
)

Result.Lang values the TUI uses to colour the output.

Variables

This section is empty.

Functions

This section is empty.

Types

type Case added in v0.2.0

type Case struct{}

Case converts each line between naming styles (camelCase, snake_case…) and text cases (Title, Sentence…).

func (Case) Run added in v0.2.0

func (c Case) Run(ctx context.Context, req tool.Request) (tool.Result, error)

func (Case) Spec added in v0.2.0

func (Case) Spec() tool.Spec

type Diff

type Diff struct{}

Diff compares two texts by lines or by words.

func (Diff) Run

func (d Diff) Run(ctx context.Context, req tool.Request) (tool.Result, error)

func (Diff) Spec

func (Diff) Spec() tool.Spec

type Inspect added in v0.2.0

type Inspect struct{}

Inspect counts characters, words and lines, and sorts, deduplicates or reverses lines.

func (Inspect) Run added in v0.2.0

func (i Inspect) Run(ctx context.Context, req tool.Request) (tool.Result, error)

func (Inspect) Spec added in v0.2.0

func (Inspect) Spec() tool.Spec

Jump to

Keyboard shortcuts

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