Josip Rodin wrote: > On Mon, May 28, 2001 at 11:17:46AM +0200, Martin Schulze wrote: > > Thus what do you think about this patch for such situations? > > In short, slices will be added a space at the end of a line when > > the a slice is splitted. > [...] > > +<: > > +my $slices = q{ > > [EN:See the Debian <A href="$(HOME)/contact">contact page</A> for > > information on contacting us.:] > [...] > > [RU:óÍÏÔÒÉÔÅ ËÁË Ó ÎÁÍÉ Ó×ÑÚÁÔØÓÑ ÎÁ ÓÔÒÁÎÉÃÅ <A > > href="$(HOME)/contact">ËÁË Ó ÎÁÍÉ Ó×ÑÚÁÔØÓÑ</A>.:] > > +}; > > +$slices =~ s/([^:][^ \]])\n/$1 \n/g; > > +print $slices; > > +:> > > Presuming it works... I'm in no condition right now to be able to figure out > that regexp, too much partying :)
I've tested it before I posted it. However I failed to find a page that used <sendcomments> so I had to create one of my own. > Be sure to test how much does it slow down the build if you're going to add > this to a lot of pages (by adding it to the important templates). There are not too many multiline slices: finlandia!joey(pts/53):/home/project/Debian/CVS/webwml> find -type f|xargs grep '\[EN:' |wc -l 643 finlandia!joey(pts/53):/home/project/Debian/CVS/webwml> find -type f|xargs grep '\[EN:' |grep ':\]'|wc -l 626 finlandia!joey(pts/53):/home/project/Debian/CVS/webwml> find english/template -type f|xargs grep '\[EN:' |wc -l 219 finlandia!joey(pts/53):/home/project/Debian/CVS/webwml> find english/template -type f|xargs grep '\[EN:' |grep ':\]'|wc -l 215 ==> total 643 slices, 643-626 multiline total 219 slices in english/templates, 219-215 multiline (plus some slices that are multiline only in non-english) Regards, Joey -- If you come from outside of Finland, you live in wrong country. -- motd of irc.funet.fi