tools

package
v0.18.0 Latest Latest
Warning

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

Go to latest
Published: Oct 6, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package tools knows the programs workline calls but does not ship — the optional tools a role `uses`, the agents, the forges' CLIs — and how each one is installed, so a missing one is named with the command that installs it on this machine.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Command

func Command(install string) bool

Command says whether an install answer is a command to run, rather than a page to read.

Types

type Tool

type Tool struct {
	Name string
	// For says who needs it and what goes unchecked without it.
	For string
	// Local: what runs on a machine uses it (a commit, a push); otherwise it
	// serves what usually runs on a forge, gardening, and is offered only.
	Local bool
	// Ways to install it, most fitting first; the first whose program is on
	// this machine is the one given.
	Ways []Way
	Page string // where it is documented, when no way fits
}

Tool is a program workline may call.

func Lookup

func Lookup(name string) Tool

Lookup returns what workline knows of a tool; an unknown one has its name only.

func (Tool) Install

func (t Tool) Install() string

Install returns the command that installs the tool on this machine, or, when none fits, where to read how.

func (Tool) Present

func (t Tool) Present() bool

Present says whether the tool is on PATH.

type Way

type Way struct {
	Needs   string // a program on PATH: brew, go, cargo, npm, curl
	OS      string // runtime.GOOS it is for; empty: any
	Command string
}

Way is one command installing a tool, and the program it needs.

Jump to

Keyboard shortcuts

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