Documentation
¶
Overview ¶
Package editorname maps the user's configured external editor (VISUAL or EDITOR) to a friendly display name used in TUI key-binding hints.
The lookup is intentionally a pure function so that it is trivial to test across platforms and editor configurations without touching the actual process environment.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FromEnv ¶
FromEnv returns a friendly display name for the configured external editor. It reads VISUAL first, then falls back to EDITOR. When neither is set, it returns the platform-specific fallback ("Notepad" on Windows, "Vi" elsewhere) that matches the actual command that will be launched.
FromEnv is pure: it takes the raw environment values as parameters so that tests can exercise every code path without mutating os.Environ.
Types ¶
This section is empty.