Documentation
¶
Overview ¶
Package tips decides the one "> Tip:" line shown after an emulator start. Tips are selected at random from a set of possible tips. Some tips are only relevant once a detector function has been run, and provides the necessary output.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Select ¶
func Select(ctx context.Context, emulatorType config.EmulatorType, firstRun, interactive bool, detectorTips []Tip, logger log.Logger) string
Select returns the one tip to show after a start of emulatorType, or "" for none (including when nothing was started). Rank a new tip in here rather than adding an emit site.
Types ¶
type Tip ¶
type Tip struct {
// contains filtered or unexported fields
}
Tip is one post-start tip: static text, or a detector that decides at selection time whether it has anything to say.
func NewDeployTip ¶
NewDeployTip suggests `lstk deploy` when `lstk deploy detect` finds IaC in the working directory. It is eligible only for AWS and when a deploy extension resolves; resolving is a filesystem lookup, and detect runs only once the tip is picked. authToken is what extension dispatch conveys (cfg.AuthToken).