patch 9.1.0574: ex: wrong handling of commands after bar
Problem: ex: wrong handling of commands after bar
Solution: for :append, :insert and :change use the text after the bar
as input for those commands. This is what POSIX requests.
(Mohamed Akram)
See the POSIX Spec:
https://pubs.opengroup.org/onlinepubs/9699919799/utilities/ex.html#tag_20_40_13_03
Section 12.c
closes: #15229
Signed-off-by: Mohamed Akram <mohd.akram@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
diff --git a/runtime/doc/insert.txt b/runtime/doc/insert.txt
index 08bf4f3..d48018f 100644
--- a/runtime/doc/insert.txt
+++ b/runtime/doc/insert.txt
@@ -1,4 +1,4 @@
-*insert.txt* For Vim version 9.1. Last change: 2024 Jul 12
+*insert.txt* For Vim version 9.1. Last change: 2024 Jul 13
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -1995,6 +1995,16 @@
containing only a ".". Watch out for lines starting with a backslash, see
|line-continuation|.
+Text typed after a "|" command separator is used first. So the following
+command in ex mode: >
+ :a|one
+ two
+ .
+ :visual
+<appends the following text, after the cursor line: >
+ one
+ two
+<
NOTE: These commands cannot be used with |:global| or |:vglobal|.
":append" and ":insert" don't work properly in between ":if" and
":endif", ":for" and ":endfor", ":while" and ":endwhile".