Tuesday, May 22, 2012

Re: Using vim to syntax highlight stdin

On May 22, 2012, at 12:14 AM, Magnus Woldrich wrote:

On May 22, Scott (Scott) wrote:
My question is about preventing pagination. I'd like to use Vim syntax
highlighting to highlight my program output but I do NOT want to Vim to
paginate the output.

You want the data highlighted on stdout?

https://github.com/trapd00r/utils/blob/master/v


Magnus,

Nice job with v.  However, it doesn't work under OSX (10.6.8 Snow Leopard) (it does in linux).

I'm pretty sure its because STDOUT is not /proc/self/fd/9 on OSX.  I tried /dev/fd/1 but this didn't work.

return writefile(retv, '/proc/self/fd/9')

Could you provide a patch for OSX? 

Thanks

Matt

No comments: