Re: XML XML::LibXML declarations issue

2003-08-27 Thread muppet
On Tue, 2003-08-26 at 11:59, Andy Wardley wrote: Robin Berjon wrote: Hands up who thinks XML Schema sucks? Now both my hands are up in the air. I'm typing this with my dick. mental note: do not use andy's keyboard. i bought the o'reilley book on xml so i could find out definitively what

Re: golf and reversed emails

2003-08-27 Thread Andrew Savige
Nick Cleaton wrote: On Sun, Aug 24, 2003 at 05:29:02PM +0100, Scott McWhirter wrote: perl -e 'print `rev`' Can anyone beat 11 characters? yeah... remove the space... Or even perl -e 'exec rev' Or even perl -eexec\ rev To reverse file f.tmp, I've tried: perl

Re: golf and reversed emails

2003-08-27 Thread Andrew Savige
To reverse file f.tmp, I've tried: perl -e'`rev2`'f.tmp perl -e'exec rev'f.tmp perl -eexec\ revf.tmp rev f.tmp|perl -pe# To reverse the order of the lines (rather than their content), can anyone shorten this? perl -e'print reverse' f.tmp /-\ http://search.yahoo.com.au - Yahoo! Search -

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Robin Berjon
Nigel Hamilton wrote: Most tab-delimited files start with the first row defining the column headings, so no problems there. But the escaping problems are pretty much the same. And the absence of enforced character encoding is a bloody nightmare. US-ASCII people rarely understand the huge

RE: XML XML::LibXML declarations issue

2003-08-27 Thread Clayton, Nik [IT]
Now both my hands are up in the air. I'm typing this with my dick. 'winky', surely. Assuming that you're 'that' Andy Wardley, obviously. N -- 11 2 3 4 5 6 77 0 0 0 0 0 0 0

Re: XML XML::LibXML declarations issue

2003-08-27 Thread David Cantrell
On Tue, Aug 26, 2003 at 08:01:02PM -0400, muppet wrote: about the only benefits i see are self-documenting data files It's only self-documenting if it's readable. As soon as you go beyond the trivial, XML seems to become unreadable.

Re: golf and reversed emails

2003-08-27 Thread David Cantrell
On Wed, Aug 27, 2003 at 01:25:41PM +1000, Andrew Savige wrote: To reverse the order of the lines (rather than their content), can anyone shorten this? perl -e'print reverse' f.tmp perl -pe'reverse'f.tmp -- David Cantrell | http://www.cantrell.org.uk/david attractivating: inducing the

Re: golf and reversed emails

2003-08-27 Thread Philip Newton
On 27 Aug 2003 at 10:10, David Cantrell wrote: On Wed, Aug 27, 2003 at 01:25:41PM +1000, Andrew Savige wrote: To reverse the order of the lines (rather than their content), can anyone shorten this? perl -e'print reverse' f.tmp perl -pe'reverse'f.tmp This calls 'reverse' on each

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Robin Berjon
David Cantrell wrote: It's only self-documenting if it's readable. As soon as you go beyond the trivial, XML seems to become unreadable. Just like Perl. Unless you make the effort to learn it. Oh, just like Perl. And even with those stock parsers, I have to write so much supporting code that it

Re: golf and reversed emails

2003-08-27 Thread Roger Burton West
On Wed, Aug 27, 2003 at 01:25:41PM +1000, Andrew Savige wrote: To reverse the order of the lines (rather than their content), can anyone shorten this? perl -e'print reverse' f.tmp perl -e 'exec tac' f.tmp R

Re: golf and reversed emails

2003-08-27 Thread Simon Wistow
On Wed, Aug 27, 2003 at 10:10:30AM +0100, David Cantrell said: perl -pe'reverse'f.tmp rev f.tmp|perl -pe'' ... not that these do what I originally wanted to do :)

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Simon Wistow
On Wed, Aug 27, 2003 at 11:19:07AM +0200, Robin Berjon said: I wouldn't want to write SVG, or XHTML, or XilBook into a Storable file. Presumably SVG into an optimised Storable file would become, if optimised, SWF. Which is a doddle to parse. ... Oh, wait. -- the illusion of knowledge

Notice for SpamAssassin users

2003-08-27 Thread Elizabeth Mattijsen
http://slashdot.org/articles/03/08/27/0214238.shtml Notice by Randal Schwartz on Perl Monks: ( http://www.perlmonks.org/index.pl?node_id=286882 ) If you use Mail::SpamAssassin and the default configuration, and have enabled the default relay checks but disabled bayes testing, or you have

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Robin Berjon
Simon Wistow wrote: On Wed, Aug 27, 2003 at 11:19:07AM +0200, Robin Berjon said: I wouldn't want to write SVG, or XHTML, or XilBook into a Storable file. Presumably SVG into an optimised Storable file would become, if optimised, SWF. Which is a doddle to parse. Doubtful. The rendering of an SVG

request for supercited mails

2003-08-27 Thread Simon Wistow
It's a an odd request but if people have got examples of heinesously and pathologically supercited mails then I'd be grateful if they could send them to me. Replacing all words to 'foo' is acceptable - I just want to test my de-superciter against odd cases. I especially want multiply cited

Re: stop this slrn nonsense

2003-08-27 Thread Dominic Mitchell
Sam Vilain [EMAIL PROTECTED] wrote: It's screwing up the threading! I'm sorry about that. It's just a lot easier to gate the list to a newsgroup... I can see what's going wrong though. It looks like my m2n gateway is changing all the messageid's to include the name of the newsgroup. Urgh.

Re: XML::Schema (Re: XML XML::LibXML declarations issue)

2003-08-27 Thread Dominic Mitchell
Andy Wardley [EMAIL PROTECTED] wrote: One of these days I'll get around to writing the generic schema representation tool that I've been thinking about since then. Something that works independantly of any particular data representation method like XML. If you confine yourself to XML, your

Re: golf and reversed emails

2003-08-27 Thread David Cantrell
On Wed, Aug 27, 2003 at 11:22:55AM +0200, Philip Newton wrote: On 27 Aug 2003 at 10:10, David Cantrell wrote: perl -pe'reverse'f.tmp This calls 'reverse' on each line in turn, rather than on the entire file. It also doesn't assign the result of 'reverse' to anything, nor does it print it.

Re: XML::Schema (Re: XML XML::LibXML declarations issue)

2003-08-27 Thread Robin Berjon
Dominic Mitchell wrote: Andy Wardley [EMAIL PROTECTED] wrote: One of these days I'll get around to writing the generic schema representation tool that I've been thinking about since then. Something that works independantly of any particular data representation method like XML. If you confine

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Nigel Hamilton
As for file truncation, having to wait for the last XML tag to arrive can be a showstopper too. On which planet do you have to do that? Planets where your module needs to build the whole XML tree in RAM (if it fits) before you can start processing it - XML::Simple, XML::TreeBuilder,

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Robin Berjon
Nigel Hamilton wrote: As for file truncation, having to wait for the last XML tag to arrive can be a showstopper too. On which planet do you have to do that? Planets where your module needs to build the whole XML tree in RAM (if it fits) before you can start processing it - XML::Simple,

Re: golf and reversed emails

2003-08-27 Thread Jasper McCrea
Andrew Savige wrote: This is more hard-core: #!perl -wlp use strict; s;\s+$;;;y;/[-]{}()`';\\]/[}{)('`;;($==y===c)$-($-=$=); @}=($_,@})}for(map$x-(y---c-$-).reverse,@}){ Improving that: #!perl -wlp use strict; s/\s+$//;y#/[-]{}()`'#\\]/[}{)('`#;$_[y///c]++;

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Ben
On Wed, Aug 27, 2003 at 12:52:48PM +0200, Robin Berjon wrote: Nigel Hamilton wrote: For example, a bank I previously worked at has trashed a lot of its SOAP transaction system because it was too slow. The reason? The byte size of the XML wrappers dwarfed the actual payload of data. Too

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Dominic Mitchell
Ben [EMAIL PROTECTED] wrote: IME the parsing of a non-trivial binary format is a much nastier task than parsing text, especially structured text like XML. Vendors are generally pretty shit at providing even a decent interoperable *text*-based protocol (viz variously and gloriously broken

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Robin Berjon
Ben wrote: On Wed, Aug 27, 2003 at 12:52:48PM +0200, Robin Berjon wrote: Yes, I'm aware of the issue, which is probably why I ended up on the program committee of this[0] Thing With A Horrible Name :) [0]http://www.w3.org/2003/07/binary-xml-cfp.html Pardon me for being thick here, but what

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Robin Berjon
Dominic Mitchell wrote: An ASN.1 neural implant? ;-) Yuck. -- Robin Berjon [EMAIL PROTECTED] Research Engineer, Expwayhttp://expway.fr/ 7FC0 6F5F D864 EFB8 08CE 8E74 58E6 D5DB 4889 2488

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Ben
On Wed, Aug 27, 2003 at 02:16:32PM +0200, Robin Berjon wrote: Ben wrote: On Wed, Aug 27, 2003 at 12:52:48PM +0200, Robin Berjon wrote: [0]http://www.w3.org/2003/07/binary-xml-cfp.html Pardon me for being thick here, but what possible gains are there for this in general-purpose use over

Re: request for supercited mails

2003-08-27 Thread Lusercop
On Wed, Aug 27, 2003 at 10:57:20AM +0100, Simon Wistow wrote: I especially want multiply cited sources and preferably multiply nested super cites if such a thing exists. OK, I shouldn't do this, but...: No such thing exists because supershiters are too few and far between. If everybody used

Re: request for supercited mails

2003-08-27 Thread Joel Bernstein
On Wed, Aug 27, 2003 at 05:41:47PM +0100, Lusercop wrote: On Wed, Aug 27, 2003 at 10:57:20AM +0100, Simon Wistow wrote: I especially want multiply cited sources and preferably multiply nested super cites if such a thing exists. OK, I shouldn't do this, but...: snip thinly veiled personal

Re: request for supercited mails

2003-08-27 Thread Dominic Mitchell
Lusercop `the.lusercop'@lusercop.net wrote: On Wed, Aug 27, 2003 at 10:57:20AM +0100, Simon Wistow wrote: I especially want multiply cited sources and preferably multiply nested super cites if such a thing exists. OK, I shouldn't do this, but...: No such thing exists because supershiters

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Robin Berjon
Michael Stevens wrote: Sun have an article on something they seem to call Fast Web Services, which appears to be keeping standard web services APIs, but putting the data in an efficient binary format on the wire at

Re: request for supercited mails

2003-08-27 Thread Peter Sergeant
OK, I shouldn't do this, but...: Right, you shouldn't, because, as you quite rightly said[1], ad-hominem attacks help no-one... +Pete [1] http://london.pm.org/pipermail/london.pm/Week-of-Mon-20030428/018794.html

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Robin Berjon
Ben wrote: This would be essentially a form of chunked parsed encoding, no? The idea being that an app continues to chuck around its data structures in (some possibly trivially transformed version of) the wire format? So that an 'XML editor' really does mean that (in some sense) the data is

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Michel Rodriguez
On Wed, 27 Aug 2003, Robin Berjon wrote: There is no doubt at all that gzip, bzip, and friends are the best at compressing any random bitstream. But, when it comes to compressing XML, it's more than possible to do better (and of course has been done). Given a grammar (ie a schema) you can

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Robin Berjon
Michel Rodriguez wrote: On Wed, 27 Aug 2003, Robin Berjon wrote: There is no doubt at all that gzip, bzip, and friends are the best at compressing any random bitstream. But, when it comes to compressing XML, it's more than possible to do better (and of course has been done). Given a grammar (ie a

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Michel Rodriguez
On Wed, 27 Aug 2003, Robin Berjon wrote: Michel Rodriguez wrote: Oh! You mean re-inventing for XML the markup minimization features that made SGML too complex? Yes! large-grin/ Except here it'll be done in a separate space to avoid complexity-pollution, and we are sworn to use only

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Robin Berjon
Michel Rodriguez wrote: On Wed, 27 Aug 2003, Robin Berjon wrote: Yes! large-grin/ Except here it'll be done in a separate space to avoid complexity-pollution, and we are sworn to use only sensible names and to call a Name a Name, and never a GI. You mean a NamespaceURI + a Name don't you? Wasn't

Re: golf and reversed emails

2003-08-27 Thread Mark
tac heresySometimes perl ain't the best way to do it./heresy Mark. On Wed, 27 Aug 2003, Andrew Savige wrote: Date: Wed, 27 Aug 2003 13:25:41 +1000 (EST) From: Andrew Savige [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Re: golf and reversed emails To

Re: golf and reversed emails

2003-08-27 Thread Chris Devers
On Wed, 27 Aug 2003, Mark wrote: tac heresySometimes perl ain't the best way to do it./heresy Mark. As this thread shows: the original question was how to tersely reverse the input file in a Perl oneliner. Calling out to a program that does this for you rather than doing it in pure Perl

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Nicholas Clark
On Wed, Aug 27, 2003 at 09:40:54PM +0200, Robin Berjon wrote: Come on Michel, you know that I have special powers to make you join *any* thread :) How come you argue about it here, but not on paris.pm? I smell a conspiracy. :-) Mmm. Meanwhile, where are the Esperanto translations? dahut.pm

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Michel Rodriguez
On Wed, 27 Aug 2003, Nicholas Clark wrote: On Wed, Aug 27, 2003 at 09:40:54PM +0200, Robin Berjon wrote: Come on Michel, you know that I have special powers to make you join *any* thread :) How come you argue about it here, but not on paris.pm? I smell a conspiracy. :-) I am afraid we

Re: XML XML::LibXML declarations issue

2003-08-27 Thread Nicholas Clark
On Wed, Aug 27, 2003 at 11:56:59PM +0200, Michel Rodriguez wrote: I am afraid we can argue anywhere, especially in places where we shouldn't be in the first place. shouldn't be ? Eh. What's this should not business? London.pm welcomes anyone. You don't even have to like perl to be a member,

Re: XML XML::LibXML declarations issue

2003-08-27 Thread David Landgren
Nicholas Clark wrote: On Wed, Aug 27, 2003 at 09:40:54PM +0200, Robin Berjon wrote: Come on Michel, you know that I have special powers to make you join *any* thread :) How come you argue about it here, but not on paris.pm? I smell a conspiracy. :-) No, we're still teaching Michel how to use