more accurately describe editor behavior
This commit is contained in:
parent
a1fc383e6f
commit
0d55865545
@ -52,6 +52,16 @@ Variables that influence kitty behavior
|
||||
files. Defaults to :file:`~/.config/kitty`. For full details of the config
|
||||
directory lookup mechanism see, :option:`kitty --config`.
|
||||
|
||||
.. envvar:: EDITOR
|
||||
|
||||
The terminal editor (such as `vi` or `nano`) for editing config files.
|
||||
Overridden by :envvar:`VISUAL`.
|
||||
|
||||
.. envvar:: VISUAL
|
||||
|
||||
The terminal editor (such as `vi` or `nano`) for editing config files.
|
||||
Takes precedence over :envvar:`EDITOR`.
|
||||
|
||||
|
||||
.. envvar:: VISUAL
|
||||
|
||||
|
||||
@ -17,9 +17,10 @@ Then hold down :kbd:`ctrl+shift` and click the name of the file.
|
||||
|
||||
|kitty| will ask you what you want to do with the remote file. You can choose
|
||||
to *Edit* it in which case kitty will download it and open it locally in your
|
||||
``EDITOR``. As you make changes to the file, they are automatically transferred
|
||||
to the remote computer. Note that this happens without needing to install *any*
|
||||
special software on the server, beyond ``ls`` that supports hyperlinks.
|
||||
:envvar:`EDITOR`. As you make changes to the file, they are automatically
|
||||
transferred to the remote computer. Note that this happens without needing
|
||||
to install *any* special software on the server, beyond ``ls`` that supports
|
||||
hyperlinks.
|
||||
|
||||
.. versionadded:: 0.19.0
|
||||
|
||||
|
||||
@ -2418,13 +2418,13 @@ starts in interactive mode and reads its startup rc files.
|
||||
opt('editor', '.',
|
||||
long_text='''
|
||||
The console editor to use when editing the kitty config file or similar tasks.
|
||||
The default value of ``.`` means to use the environment variables :envvar:`VISUAL`
|
||||
and :envvar:`EDITOR` in that order. Note that these environment variables have
|
||||
to be set when kitty starts, so if they're only set in shell startup scripts, but
|
||||
kitty is launched directly from your desktop, kitty will not see them. kitty does try
|
||||
to read the values from the shell as well, but this process is not entirely robust since
|
||||
there are a myriad different shells out there. In that case you're better off naming
|
||||
your favorite editor here.
|
||||
|
||||
The default value of . means to use the environment variables :envvar:`VISUAL`
|
||||
and :envvar:`EDITOR` in that order. If these variables aren't set, kitty will
|
||||
run your shell (`$SHELL -l -c env`) to see if your shell config files set
|
||||
:envvar:`VISUAL` or :envvar:`EDITOR`. If that doesn't work, kitty will cycle
|
||||
through various known editors (`vim`, `emacs`, etc) and take the first one
|
||||
that exists on your system.
|
||||
'''
|
||||
)
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user