1
0
forked from aniani/vim

patch 8.0.0151: passing buffer content to system() is clumsy

Problem:    To pass buffer content to system() and systemlist() one has to
            first create a string or list.
Solution:   Allow passing a buffer number. (LemonBoy, closes #1240)
This commit is contained in:
Bram Moolenaar
2017-01-08 13:26:03 +01:00
parent 7069bf18e1
commit 12c4492dd3
6 changed files with 60 additions and 5 deletions

View File

@@ -7561,7 +7561,11 @@ system({expr} [, {input}]) *system()* *E677*
If {input} is given and is a |List| it is written to the file
in a way |writefile()| does with {binary} set to "b" (i.e.
with a newline between each list item with newlines inside
list items converted to NULs).
list items converted to NULs).
When {input} is given and is a number that is a valid id for
an existing buffer then the content of the buffer is written
to the file line by line, each line terminated by a NL and
NULs characters where the text has a NL.
Pipes are not used, the 'shelltemp' option is not used.