martanne / vis

A vi-like editor based on Plan 9's structural regular expressions
Other
4.25k stars 258 forks source link

vis:pipe on the unattached string instead of just range #1021

Closed mcepl closed 2 years ago

mcepl commented 2 years ago

https://github.com/martanne/vis/blob/eb96e0ce8143804f5a7a37eb76a4b86d8871dd76/vis.c#L1717-L1718

I am perfectly aware of http://lua-users.org/lists/lua-l/2007-10/msg00189.html and how difficult it is to make bidirectional pipe, but I don’t ask that. What I would like to get is just the equivalent of the Python’s subprocess.Popen() (present there since 2.4), system() in VimScript, certainly something in Emacs:

I don’t know if it would be just a new signature of vis:pipe, e.g., vis:pipe(nil, input-string, cmd) or completely new function, but I am afraid that without that authors of vis plugins will be in the significant disadvantage against their “competitors” writing plugins for other editors.

mcepl commented 2 years ago

Transferred to https://todo.sr.ht/~martanne/vis/5.