open_editor

Function open_editor 

Source
pub(crate) fn open_editor(path: &Path) -> Result<(), Error>
Expand description

Opens $EDITOR pointed at the given path, if $EDITOR is set.

Uses sh -c to support editors with arguments (e.g., EDITOR="code --wait"). If $EDITOR is not set, returns Ok(()) silently.