uninstall

package
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Package uninstall removes triage and its local files.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PrintPaths

func PrintPaths(out io.Writer) error

PrintPaths writes the locations triage uses.

func Run

func Run(args []string, in io.Reader, out, errOut io.Writer, interactive Interactive) error

Types

type Interactive added in v0.3.2

type Interactive func(Plan) error

Run implements `triage uninstall`. Interactive presents a plan and carries it out, for terminals. Run uses it when set, unless --yes or --dry-run asks for plain output.

type Plan

type Plan struct {
	Executable string
	Paths      config.Paths
	KeepData   bool
	// Unsent counts changes in the outbox that would be lost.
	Unsent int
	// contains filtered or unexported fields
}

Plan lists what an uninstall removes.

func TestPlan added in v0.3.2

func TestPlan(paths ...string) Plan

TestPlan builds a plan that removes the given files, for tests of code that presents plans.

func (Plan) Remove added in v0.3.2

func (p Plan) Remove(i int) error

Remove deletes the plan's i-th target. Call Validate first.

func (Plan) Targets added in v0.3.2

func (p Plan) Targets() []Target

Targets lists what the plan removes, in order.

func (Plan) Validate added in v0.3.2

func (p Plan) Validate() error

Validate refuses plans that would delete something that isn't triage's.

type Target added in v0.3.2

type Target struct {
	Kind string
	Path string
}

Target is one thing an uninstall removes.

Jump to

Keyboard shortcuts

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