🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.readers
8 messages
8 total messages Started by Bit Twister Sun, 18 Nov 2007 04:43
slrn kill line greater than 30 chars long
#210176
Author: Bit Twister
Date: Sun, 18 Nov 2007 04:43
29 lines
1948 bytes
Googling and reading the slang expression sections would suggest
	 Score: =-9999
	 Organization: .\{30,\}
should kill org line greater than 30, but is is not killing 40+
character lines.

Any suggestions?


Running slrn on Mandriva Linux release 2008.0

slrn --version
Slrn 0.9.8.1pl2 [2005-02-17]
        * Note: This version is a developer preview.
S-Lang Library Version: 2.1.1
        * Note: This program was compiled against version 2.1.0-0.
Compiled at: Jun  8 2007 11:58:58
Operating System: Linux

 COMPILE TIME OPTIONS:
  Backends: +nntp +slrnpull +spool
  External programs / libs: -canlock -inews -ssl -uudeview
  Features: +charset_mapping +decoding +emphasized_text +end_of_thread
    +fake_refs +gen_msgid -grouplens -msgid_cache +piping +rnlock +slang
    +spoilers -strict_from
 DEFAULTS:
  Default server object:     nntp
  Default posting mechanism: nntp
Re: slrn kill line greater than 30 chars long
#210179
Author: Ted S.
Date: Sun, 18 Nov 2007 05:16
18 lines
1591 bytes
On Sun, 18 Nov 2007 04:43:58 GMT, Bit Twister wrote:

> Googling and reading the slang expression sections would suggest
> 	 Score: =-9999
> 	 Organization: .\{30,\}
> should kill org line greater than 30, but is is not killing 40+
> character lines.
> 
> Any suggestions?

I know that in PCRE you don't need to escape the braces if what you want
is 30 or more characters.  You seem to be looking for a character,
followed by a literal open brace, the number 30, a comma, and a literal
close brace.

-- 
Ted S.
fedya at bestweb dot net
Re: slrn kill line greater than 30 chars long
#210199
Author: Bit Twister
Date: Sun, 18 Nov 2007 17:33
33 lines
2179 bytes
On Sun, 18 Nov 2007 00:16:12 -0500, Ted S. wrote:
> On Sun, 18 Nov 2007 04:43:58 GMT, Bit Twister wrote:
>
>> Googling and reading the slang expression sections would suggest
>> 	 Score: =-9999
>> 	 Organization: .\{30,\}
>> should kill org line greater than 30, but is is not killing 40+
>> character lines.
>> 
>> Any suggestions?
>
> I know that in PCRE you don't need to escape the braces if what you want

Yup, slrn news reader uses slang which follows regexp syntax most of
the time. There are some egrep differences.

http://www.greenend.org.uk/rjk/2002/06/regexp.html#matchmulti

> is 30 or more characters.  You seem to be looking for a character,
> followed by a literal open brace, the number 30, a comma, and a literal
> close brace.

Have tried the following and none appear to work.

       Organization: .\{30,\}
       Organization: .\{30,40\}
       Organization: .{30,}
       Organization: .\(30,\)
       Organization: .\(30,40\)
       Organization: .(30,)
       Organization: .(30,40)

Re: slrn kill line greater than 30 chars long
#210200
Author: Jörg Lüders
Date: Sun, 18 Nov 2007 17:55
16 lines
1492 bytes
Bit Twister <BitTwister@mouse-potato.com>:

> Googling and reading the slang expression sections would suggest
> 	 Score: =-9999
> 	 Organization: .\{30,\}
> should kill org line greater than 30, but is is not killing 40+
> character lines.

The syntax is correct but the count quantifier doesn't work with the 
wildcard.  At least not in the way you intended.

> Any suggestions?

Type thirty dots or use something like "[whatever]\{30\}". No comma 
needed, your pattern doesn't have to match the whole line.
Re: slrn kill line greater than 30 chars long SOLUTION
#210207
Author: Bit Twister
Date: Sun, 18 Nov 2007 19:51
8 lines
1446 bytes
On 18 Nov 2007 17:55:28 GMT, Jörg Lüders wrote:
>
> Type thirty dots or use something like "[whatever]\{30\}". No comma 
> needed, your pattern doesn't have to match the whole line.

Thank you. 
Solution was just a bunch of dots.
      Organization: [..................................]
Re: slrn kill line greater than 30 chars long SOLUTION
#210208
Author: Jörg Lüders
Date: Sun, 18 Nov 2007 20:04
14 lines
1676 bytes
Bit Twister <BitTwister@mouse-potato.com>:

> On 18 Nov 2007 17:55:28 GMT, Jörg Lüders wrote:
>>
>> Type thirty dots or use something like "[whatever]\{30\}". No comma 
>> needed, your pattern doesn't have to match the whole line.
>
> Thank you. 
> Solution was just a bunch of dots.
>       Organization: [..................................]

That's what I meant with my first suggestion, but without the brackets.  
I'd expect your pattern to match anything with a dot in it.
Re: slrn kill line greater than 30 chars long SOLUTION
#210211
Author: Bit Twister
Date: Sun, 18 Nov 2007 20:47
11 lines
1746 bytes
On 18 Nov 2007 20:04:03 GMT, Jörg Lüders wrote:
> Bit Twister <BitTwister@mouse-potato.com>:
>> Thank you. 
>> Solution was just a bunch of dots.
>>       Organization: [..................................]
>
> That's what I meant with my first suggestion, but without the brackets.  
> I'd expect your pattern to match anything with a dot in it.

Dot is a wildcard for any character. Had I wanted a dot match in the text I
would have to escape it with a backslash  \. 
Re: slrn kill line greater than 30 chars long SOLUTION
#210212
Author: Jörg Lüders
Date: Sun, 18 Nov 2007 21:09
18 lines
2030 bytes
Bit Twister <BitTwister@mouse-potato.com>:

> On 18 Nov 2007 20:04:03 GMT, Jörg Lüders wrote:
>> Bit Twister <BitTwister@mouse-potato.com>:
>>> Thank you. 
>>> Solution was just a bunch of dots.
>>>       Organization: [..................................]
>>
>> That's what I meant with my first suggestion, but without the brackets.  
>> I'd expect your pattern to match anything with a dot in it.
>
> Dot is a wildcard for any character. Had I wanted a dot match in the text I
> would have to escape it with a backslash  \. 

In brackets, a dot is just a dot, a member of a list of characters like 
the a in [abc]. So "[.....]" is the same as "[.]", which is the same as 
"\.", which is, er, not what you want. You want ".....".
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads