summaryrefslogtreecommitdiff
path: root/docs/users_guide/ghci.rst
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2020-12-08 13:07:17 -0500
committerMarge Bot <ben+marge-bot@smart-cactus.org>2021-01-30 14:11:48 -0500
commitf5d62eb2d5a1058f355aaa1fd0a959694d160ec4 (patch)
tree19f568ae8d1ee963bc21b15b9dea502330314264 /docs/users_guide/ghci.rst
parentbd0b27267985c6c3482578ccf71a3cab9a1d7b12 (diff)
downloadhaskell-f5d62eb2d5a1058f355aaa1fd0a959694d160ec4.tar.gz
ghci: Take editor from VISUAL environment variable
Following the example of `git`, as noted in #19030. Fixes #19030.
Diffstat (limited to 'docs/users_guide/ghci.rst')
-rw-r--r--docs/users_guide/ghci.rst14
1 files changed, 11 insertions, 3 deletions
diff --git a/docs/users_guide/ghci.rst b/docs/users_guide/ghci.rst
index 93b72979b8..78c74c5dc3 100644
--- a/docs/users_guide/ghci.rst
+++ b/docs/users_guide/ghci.rst
@@ -2443,9 +2443,17 @@ commonly used commands.
Opens an editor to edit the file ⟨file⟩, or the most recently loaded
module if ⟨file⟩ is omitted. If there were errors during the last
loading, the cursor will be positioned at the line of the first
- error. The editor to invoke is taken from the :envvar:`EDITOR` environment
- variable, or a default editor on your system if :envvar:`EDITOR` is not
- set. You can change the editor using :ghci-cmd:`:set editor`.
+ error. The editor to invoke is taken from the :envvar:`VISUAL` or
+ :envvar:`EDITOR` environment variables, or a default editor on your system
+ if neither is not set. You can change the editor using :ghci-cmd:`:set
+ editor`.
+
+.. envvar:: VISUAL
+
+ :hidden:
+
+ .. This declaration simply avoids undefined reference warnings as Sphinx
+ doesn't know about VISUAL
.. ghci-cmd:: :enable; * | ⟨num⟩ ...