(prompt, defaultValue string, blankAllowed bool)
| 271 | } |
| 272 | |
| 273 | func (p *huhPrompter) MarkdownEditor(prompt, defaultValue string, blankAllowed bool) (string, error) { |
| 274 | form, result := p.buildMarkdownEditorForm(prompt, blankAllowed) |
| 275 | err := p.runForm(form) |
| 276 | if err != nil { |
| 277 | return "", err |
| 278 | } |
| 279 | |
| 280 | if *result == "skip" { |
| 281 | return "", nil |
| 282 | } |
| 283 | |
| 284 | text, err := surveyext.Edit(p.editorCmd, "*.md", defaultValue, p.stdin, p.stdout, p.stderr) |
| 285 | if err != nil { |
| 286 | return "", err |
| 287 | } |
| 288 | |
| 289 | return text, nil |
| 290 | } |
nothing calls this directly
no test coverage detected