patch 8.2.4594: need to write script to a file to be able to source them
Problem: Need to write script to a file to be able to source them.
Solution: Make ":source" use lines from the current buffer. (Yegappan
Lakshmanan et al., closes #9967)
diff --git a/runtime/doc/repeat.txt b/runtime/doc/repeat.txt
index ce88a10..a775af0 100644
--- a/runtime/doc/repeat.txt
+++ b/runtime/doc/repeat.txt
@@ -197,6 +197,12 @@
:so[urce] {file} Read Ex commands from {file}. These are commands that
start with a ":".
Triggers the |SourcePre| autocommand.
+
+:[range]so[urce] Read Ex commands from the [range] of lines in the
+ current buffer. When sourcing commands from the
+ current buffer, the same script-ID |<SID>| is used
+ even if the buffer is sourced multiple times.
+
*:source!*
:so[urce]! {file} Read Vim commands from {file}. These are commands
that are executed from Normal mode, like you type