command

package
v1.9.1 Latest Latest
Warning

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

Go to latest
Published: May 15, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func StartPager added in v1.9.1

func StartPager(w io.Writer, noPager bool) (io.Writer, func(), error)

StartPager wraps w with a pager subprocess when all of the following hold:

  • paging hasn't been disabled by --no-pager,
  • w is a TTY (so the user is actually viewing the output interactively),
  • PISTA_PAGER is set to a non-empty command line.

Otherwise it returns w unchanged with a no-op close. The returned close function tears down the pager and waits for it to exit, so callers should always invoke it (typically via defer).

Types

type Apply

type Apply struct {
	pistachio.ApplyOptions
}

func (*Apply) Run

func (cmd *Apply) Run(ctx context.Context, client *pistachio.Client, w io.Writer) error

type Dump

type Dump struct {
	pistachio.DumpOptions
}

func (*Dump) Run

func (cmd *Dump) Run(ctx context.Context, client *pistachio.Client, w io.Writer) error

type Plan

type Plan struct {
	pistachio.PlanOptions
}

func (*Plan) Run

func (cmd *Plan) Run(ctx context.Context, client *pistachio.Client, w io.Writer) error

Jump to

Keyboard shortcuts

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