Hi Bram!

On So, 05 Apr 2009, Bram Moolenaar wrote:

> 
> Did you try removing "octal" from 'nrformats'?
> 

I thought so too and tried that, and it didn't work. Is this may be a 
bug? It surprised me, that 'nrformats' did not work.

Alternatively you could use str2nr to force the match to be 
interprated as decimal and then add 1:

:%s/^\d\+/\=printf("%04d",str2nr(submatch(0),10)+1)/

regards,
Christian
-- 
:wq!

--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Reply via email to