Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func OpenFileCmd ¶
func OpenFileCmd(path string, opts ...CreateEditorCmdOption) *exec.Cmd
OpenFileCmd produces an exec.Cmd to open a path in an editor. It will use the first successful CreateEditorCmdOption. Otherwise it will fallback to "vi".
func OpenFileCmdDefault ¶
func OpenFileCmdDefault(path string, prioritize ...CreateEditorCmdOption) *exec.Cmd
OpenFileCmdDefault produces an exec.Cmd to open a path in an editor. It tries to prioritize the given list of editors before accessing a list of default editors. default editor options with priority: 1. env VISUAL 2. env EDITOR
Types ¶
type CreateEditorCmdOption ¶
func WithCmdString ¶
func WithCmdString(fn func() (string, error)) CreateEditorCmdOption
Click to show internal directories.
Click to hide internal directories.