Re: editing the output of a shell cmd
- Michael Naumann wrote:
>Perhaps I misunderstood what Moshe wanted. I assume when he tried ":edit
> 29.08.2002 04:04:35, Benji Fisher <benji@...> wrote:
> >Moshe Kaminsky wrote:
> >> Hi,
> >> Is there a reason I can't edit the output of a shell command, like with
> >> read and write?. I mean, eg,
> >> :edit !ls
> >> doesn't work. Also I tried
> >> :edit +read\ !ls
> >> this doesn't work, I don't see why (it says `Can't open file !ls')
> > Did you try
> >:execute "edit" system("ls")
> What's this supposed to do?
> I think this will almost always only produce a vim error-message, stating that
> :edit only accepts one filename.
> Either way, it does not put the output into a buffer, like Moshe wanted.
!ls" he wanted (if the directory contained files foo.txt and bar.txt) to edit
the files foo.txt and bar.txt . Maybe I should have suggested "args" or
"argadd" instead of "edit".