MCPcopy
hub / github.com/TomWright/dasel / newInteractiveTeaProgram

Function newInteractiveTeaProgram

internal/cli/interactive_tea.go:41–46  ·  view source on GitHub ↗
(initialInput string, initialSelector string, formatIn parsing.Format, formatOut parsing.Format, run interactiveDaselExecutor)

Source from the content-addressed store, hash-verified

39type interactiveDaselExecutor func(selector string, root bool, formatIn parsing.Format, formatOut parsing.Format, in string) (res string, err error)
40
41func newInteractiveTeaProgram(initialInput string, initialSelector string, formatIn parsing.Format, formatOut parsing.Format, run interactiveDaselExecutor) (*tea.Program, func() string) {
42 m := newInteractiveRootModel(initialInput, initialSelector, formatIn, formatOut, run)
43 return tea.NewProgram(m, tea.WithAltScreen()), func() string {
44 return m.sharedData.selector
45 }
46}
47
48type interactiveSharedData struct {
49 formatIn parsing.Format

Callers 1

RunMethod · 0.85

Calls 1

newInteractiveRootModelFunction · 0.85

Tested by

no test coverage detected