Re: [PUSHED] Release notes: use bug titles instead of commit messages if possible

2012-05-18 Thread Ivan Timofeev

On 18.05.2012 20:44, Ivan Timofeev wrote:

Maybe adding 'use utf8;' to the script will solve the problem?


or using \N{U+2013} instead of '-':
http://perldoc.perl.org/perlunicode.html
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [PUSHED] Release notes: use bug titles instead of commit messages if possible

2012-05-18 Thread Ivan Timofeev

On 18.05.2012 20:21, Petr Mladek wrote:

1. Novell bugzilla does not return any title.


Yeah, it requires login...


2. The titles from other bugzillas were ignored because "-" in the title
was  wide character here. I am not sure why it worked for you.
Probably something with UTF-8 locales. Anyway, I solved it by
replacing:

-   if ( $title =~ s/^Bug \d+ - // ) {
+   if ( $title =~ s/^Bug \d+ . // ) {

It is not perfect but... Any better solution is welcome.


I simply copied that character (en dash) from what the $response->title 
returns and pasted it to the regular expression...

Maybe adding 'use utf8;' to the script will solve the problem?


If you agree with my changes, I will push it also for 3-5 branch.


Sure!

Thanks for reviewing,
Ivan
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [PUSHED] Release notes: use bug titles instead of commit messages if possible

2012-05-18 Thread Petr Mladek
Ivan Timofeev píše v Pá 18. 05. 2012 v 18:56 +0400:
> Hi Petr,
> 
> On 18.05.2012 18:13, Petr Mladek wrote:
> > I like it very much. The only problem is that I havn't got any title
> > from bugzilla :-)
> 
> LOL :)

Ah, there were two problems here:

1. Novell bugzilla does not return any title. I know that you mentioned
   it. Unfortunately, the first 5 bugs of my query were from this
   bugzilla and I forgot it during the deeper debugging :-)


2. The titles from other bugzillas were ignored because "-" in the title
   was  wide character here. I am not sure why it worked for you.
   Probably something with UTF-8 locales. Anyway, I solved it by
   replacing:

-   if ( $title =~ s/^Bug \d+ - // ) {
+   if ( $title =~ s/^Bug \d+ . // ) {
 
   It is not perfect but... Any better solution is welcome.


Next, your debug info is useful. It is good that it prints something
when looking for the titles. It takes time if you have many bugs.

Finally, I added some more sorting and pushed everything into master:
http://cgit.freedesktop.org/libreoffice/core/commit/?id=a8b77a529047d2d26b1633df3c0f6511fc379305
http://cgit.freedesktop.org/libreoffice/core/commit/?id=b47213604b69df85837b504917caf550c008459f
http://cgit.freedesktop.org/libreoffice/core/commit/?id=dd15b51ddaf4a143d494076a6dd554a059d91489

If you agree with my changes, I will push it also for 3-5 branch.


Thanks a lot for this cool improvement!

Best Regards,
Petr

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice