MCPcopy Create free account
hub / github.com/cli/cli / CommentableEditSurvey

Function CommentableEditSurvey

pkg/cmd/pr/shared/commentable.go:435–443  ·  view source on GitHub ↗
(cf func() (gh.Config, error), io *iostreams.IOStreams)

Source from the content-addressed store, hash-verified

433}
434
435func CommentableEditSurvey(cf func() (gh.Config, error), io *iostreams.IOStreams) func(string) (string, error) {
436 return func(initialValue string) (string, error) {
437 editorCommand, err := cmdutil.DetermineEditor(cf)
438 if err != nil {
439 return "", err
440 }
441 return surveyext.Edit(editorCommand, "*.md", initialValue, io.In, io.Out, io.ErrOut)
442 }
443}
444
445func CommentableConfirmDeleteLastComment(p Prompt) func(string) (bool, error) {
446 return func(body string) (bool, error) {

Callers 1

NewCmdCommentFunction · 0.92

Calls 2

DetermineEditorFunction · 0.92
EditFunction · 0.92

Tested by

no test coverage detected