Re: delete only the short sentences

2010-11-08 Thread Christian Brabandt
Hi AMDx64BT! On Mo, 08 Nov 2010, AMDx64BT wrote: > :%s/\_^\(.\{,40}\n\)\{4,}// works very well. I would like to do > another question. > Could be possible to delete all the sentences < 40 characters only > when they are more than 3 times consecutives "but now keeping the last > one undeleted of e

Re: delete only the short sentences

2010-11-08 Thread AMDx64BT
:%s/\_^\(.\{,40}\n\)\{4,}// works very well. I would like to do another question. Could be possible to delete all the sentences < 40 characters only when they are more than 3 times consecutives "but now keeping the last one undeleted of each group". I want to say this: Begining with this: xxx

Re: delete only the short sentences

2010-11-07 Thread rameo
or this one: :v/^.\{41,}/d -- 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

Re: delete only the short sentences

2010-11-07 Thread Christian Brabandt
Hi AMDx64BT! On So, 07 Nov 2010, AMDx64BT wrote: > Thanks for the solution. It works. I would like to know how I can > delete sentences < 40 characters only when they are more than 3 times > consecutives. > > For example, with this text: > > xx > xx > xx > xx

Re: delete only the short sentences

2010-11-07 Thread AMDx64BT
Thanks for the solution. It works. I would like to know how I can delete sentences < 40 characters only when they are more than 3 times consecutives. For example, with this text: xx xx xx

Re: delete only the short sentences

2010-11-01 Thread ZyX
Reply to message «Re: delete only the short sentences», sent 17:21:40 01 November 2010, Monday by Tim Chase: > On 11/01/10 07:40, Joan Miquel Torres Rigo wrote: > > 2010/11/1 Tim Chase: > >> :v/\%40c./d > >> > >> ("if there's a character at posi

Re: delete only the short sentences

2010-11-01 Thread Tim Chase
On 11/01/10 07:40, Joan Miquel Torres Rigo wrote: > 2010/11/1 Tim Chase: :v/\%40c./d ("if there's a character at position 40, don't delete this row; otherwise, delete it") Then you will also remove rows with 61 to 80 characters. But the strategy is probably good. (I'm not fully expert with

Re: delete only the short sentences

2010-11-01 Thread Tim Chase
On 10/31/10 23:14, Joan Miquel Torres Rigo wrote: 2010/11/1 AMDx64BT: And to keep only the sentences in the range 40-60 characters long and delete the rest? :g/^.\{,39\}$/d and :g/\(^.\{,39\}$\)\|\(^.\{61,\}$\)/d And to reverse the condition, one could use something like :v/\%40c./d ("

Re: delete only the short sentences

2010-10-31 Thread Joan Miquel Torres Rigo
2010/11/1 AMDx64BT : > And to keep only the sentences in the range 40-60 characters long and > delete the rest? :g/^.\{,39\}$/d and :g/\(^.\{,39\}$\)\|\(^.\{61,\}$\)/d should work. > > On Nov 1, 4:32 am, AMDx64BT wrote: >> I want to delete all the lines with long < 40 characters (including >>

Re: delete only the short sentences

2010-10-31 Thread AMDx64BT
And to keep only the sentences in the range 40-60 characters long and delete the rest? On Nov 1, 4:32 am, AMDx64BT wrote: > I want to delete all the lines with long < 40 characters (including > white-spaces) and keep the others. Is there any command to do that? -- You received this message from

delete only the short sentences

2010-10-31 Thread AMDx64BT
I want to delete all the lines with long < 40 characters (including white-spaces) and keep the others. Is there any command to do that? -- 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:/