Friday, May 20, 2011

Re: bash script using vim commands?


On May 21, 2011 12:30 AM, "Antonio Recio" <amdx64bt@gmail.com> wrote:
>
> The two commands to delete the comments of C++ files are:
> :%s!\s*//.*\|/\*\_.\{-}\*/
> :g/^\s*$/d
>
> How I can add this commands to my bash script?
>

The right tool for the job I think: sed, awk, perl, lisp, etc. I don't think vim is the right tool.

That said, I'm sure there's a way. OTOH, if you're a hammer, everything looks like a nail :)

--
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: