Bugzilla – Attachment 121448 Details for
Bug 28386
Replace dev_map.yaml from release_tools with .mailmap
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 28386: Sort authors by lastname || firstname
Bug-28386-Sort-authors-by-lastname--firstname.patch (text/plain), 1.31 KB, created by
Jonathan Druart
on 2021-05-27 12:41:52 UTC
(
hide
)
Description:
Bug 28386: Sort authors by lastname || firstname
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2021-05-27 12:41:52 UTC
Size:
1.31 KB
patch
obsolete
>From 8aec505d93406c3385302df444fd3ed848c0ea74 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Thu, 27 May 2021 14:38:44 +0200 >Subject: [PATCH] Bug 28386: Sort authors by lastname || firstname > >If several authors have the same lastname, they are swapped in the list between the different runs. > >This is reusing the code from the release_tools, see issue #24 >--- > about.pl | 13 +++++++++---- > 1 file changed, 9 insertions(+), 4 deletions(-) > >diff --git a/about.pl b/about.pl >index 3cba9cec28b..9b59a6aa655 100755 >--- a/about.pl >+++ b/about.pl >@@ -719,10 +719,15 @@ for my $version ( sort { $a <=> $b } keys %{$teams->{team}} ) { > my @people = map { > { name => $_, ( $contributors->{$_} ? %{ $contributors->{$_} } : () ) } > } sort { >- my ($alast) = ( split( /\s/, $a ) )[-1]; >- my ($blast) = ( split( /\s/, $b ) )[-1]; >- lc($alast) cmp lc($blast) >-} keys %{$contributors}; >+ my ($alast) = $a =~ /(\S+)$/; >+ my ($blast) = $b =~ /(\S+)$/; >+ my $cmp = lc($alast||"") cmp lc($blast||""); >+ return $cmp if $cmp; >+ >+ my ($a2last) = $a =~ /(\S+)\s\S+$/; >+ my ($b2last) = $b =~ /(\S+)\s\S+$/; >+ lc($a2last||"") cmp lc($b2last||""); >+} keys %$contributors; > > $template->param( contributors => \@people ); > $template->param( maintenance_team => $teams->{team}->{$dev_team} ); >-- >2.20.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 28386
:
121153
|
121154
|
121155
|
121156
|
121157
|
121158
|
121159
|
121160
|
121161
|
121162
|
121177
|
121180
|
121245
|
121246
|
121247
|
121248
|
121249
|
121250
|
121251
|
121252
|
121253
|
121254
|
121255
|
121256
|
121329
|
121330
|
121331
|
121332
|
121354
|
121355
|
121378
|
121384
|
121420
|
121447
| 121448