Documentation
¶
Overview ¶
Package ui is the terminal front: prompts (huh) and the live progress board (mpb).
Index ¶
- func Confirm(title, description, yes, no string) (bool, error)
- func ConfirmTarget(target, summary string) error
- func EditProfile(drivers []driver.Driver, p *config.Profile, taken []string) error
- func ManageProfiles(store *config.Store, drivers []driver.Driver) error
- func Narrow(ctx context.Context, src driver.Endpoint, jobs []clone.Job) ([]clone.Job, error)
- func Pick(available []clone.Job, existing map[string]bool, target string) ([]clone.Job, error)
- func PrintError(err error)
- func PrintReport(r preflight.Report)
- func SelectProfile(title string, names []string, def string) (string, error)
- type Bar
- type Board
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConfirmTarget ¶ added in v0.2.0
ConfirmTarget makes the user type the target's name before writing to a remote server.
func EditProfile ¶ added in v0.2.0
EditProfile asks for a profile's name and its connection settings for every engine, prefilled with p. Leaving an engine's fields empty means the profile has no such engine.
func ManageProfiles ¶ added in v0.2.0
ManageProfiles lets the user add, edit and delete profiles until they choose Done.
func Narrow ¶
Narrow lets the user restrict some of the picked databases to specific tables or collections. Databases left unticked in the first step are cloned whole.
func Pick ¶
Pick lets the user tick the databases to clone; existing marks the ones already on the target.
func PrintError ¶ added in v0.1.1
func PrintError(err error)
PrintError shows a failure inline, e.g. a source connection that does not work.
func PrintReport ¶ added in v0.1.1
PrintReport shows the local-setup checklist, with the fix under each failed line.
Types ¶
type Bar ¶
type Bar struct {
// contains filtered or unexported fields
}
Bar implements clone.Reporter.