(ctx context.DnoteCtx, fpath string)
| 75 | } |
| 76 | |
| 77 | func newEditorCmd(ctx context.DnoteCtx, fpath string) (*exec.Cmd, error) { |
| 78 | args := strings.Fields(ctx.Editor) |
| 79 | args = append(args, fpath) |
| 80 | |
| 81 | return exec.Command(args[0], args[1:]...), nil |
| 82 | } |
| 83 | |
| 84 | // GetEditorInput gets the user input by launching a text editor and waiting for |
| 85 | // it to exit |