(p prompter.Prompter, io *iostreams.IOStreams)
| 201 | } |
| 202 | |
| 203 | func runInput(p prompter.Prompter, io *iostreams.IOStreams) error { |
| 204 | fmt.Fprintln(io.Out, "Demonstrating Text Input") |
| 205 | text, err := p.Input("Favorite meal?", "Breakfast") |
| 206 | if err != nil { |
| 207 | return err |
| 208 | } |
| 209 | fmt.Fprintf(io.Out, "You typed: %s\n", text) |
| 210 | return nil |
| 211 | } |
| 212 | |
| 213 | func runPassword(p prompter.Prompter, io *iostreams.IOStreams) error { |
| 214 | fmt.Fprintln(io.Out, "Demonstrating Password Input") |