Tuesday, May 4, 2010

Re: escape sequence in output

> # prints a green 'foo'
> $ echo ${GREEN}foo${NOCOLOR}
> foo
>
> # (myod is like od, but mine)
> $ echo ${GREEN}foo${NOCOLOR} | myod -T
> 00000000 1b 5b 33 32 6d 66 6f 6f 1b 5b 30 6d 0a ».[32mfoo.[0m¬«
>
> # '| col -b' doesn't seem to strip most things out:
> $ echo ${GREEN}foo${NOCOLOR} | col -b
> 32mfoo0m


If makefile is written in this way, you can disable
colors by invoking make as follows:

$ make GREEN= NOCOLOR=

In vim, you can do:

:set makeprg=make\ GREEN=\ NOCOLOR=

-- Dominique

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments: