diff --git a/fhem/FHEM/98_Installer.pm b/fhem/FHEM/98_Installer.pm index 482b6e475..41a363152 100644 --- a/fhem/FHEM/98_Installer.pm +++ b/fhem/FHEM/98_Installer.pm @@ -1593,12 +1593,17 @@ sub CreateMetadataList ($$$) { next if ( $_ eq '' ); my $authorName; + my $authorEditorOnly; my $authorEmail; my $authorNameEmail; - if ( $_ =~ m/^([^<>\n\r]+)(?:\s+(?:<(.*)>))?$/ ) { - $authorName = $1; - $authorEmail = $2; + if ( $_ =~ +m/^([^<>\n\r]+?)(?:\s+(\(last release only\)))?(?:\s+(?:<(.*)>))?$/ + ) + { + $authorName = $1; + $authorEditorOnly = $2 ? ' ' . $2 : ''; + $authorEmail = $3; } if ( $authorName eq 'unknown' ) { $l .= '-'; @@ -1608,9 +1613,11 @@ sub CreateMetadataList ($$$) { $authorNameEmail = '' - . $authorName . '' + . $authorName + . $authorEditorOnly . '' if ( $html && $authorEmail ); + # add alias name if different if ( defined( $modMeta->{x_fhem_maintainer} ) && ref( $modMeta->{x_fhem_maintainer} ) eq 'ARRAY' && @{ $modMeta->{x_fhem_maintainer} } > 0 @@ -1630,7 +1637,10 @@ sub CreateMetadataList ($$$) { $l .= $lb if ($counter); $l .= $lb . 'Co-' . $mAttrName . ':' . $lb if ( $counter == 1 ); - $l .= $authorNameEmail ? $authorNameEmail : $authorName; + $l .= + $authorNameEmail + ? $authorNameEmail + : $authorName . $authorEditorOnly; $counter++; } diff --git a/fhem/FHEM/Meta.pm b/fhem/FHEM/Meta.pm index 6110579e2..c5539e0d8 100644 --- a/fhem/FHEM/Meta.pm +++ b/fhem/FHEM/Meta.pm @@ -670,7 +670,8 @@ m/(\$Id\: ((?:([0-9]+)_)?([\w]+)\.([\w]+))\s([0-9]+)\s((([0-9]+)-([0-9]+)-([0-9] $vcs[12] = $13; # commit hour $vcs[13] = $14; # commit minute $vcs[14] = $15; # commit second - $vcs[15] = $16; # svn username (COULD be maintainer) + $vcs[15] = $16; # svn username (COULD be maintainer + # if not in MAINTAINER.txt) # These items are added later in the code: # $vcs[16] - commit unix timestamp @@ -1138,16 +1139,41 @@ m/(^#\s+(?:\d{1,2}\.\d{1,2}\.(?:\d{2}|\d{4})\s+)?[^v\d]*(v?(?:\d{1,3}\.\d{1,3}(? # mandatory unless ( $modMeta->{author} ) { - if ( defined( $modMeta->{x_vcs} ) ) { - $modMeta->{author} = [ $modMeta->{x_vcs}[15] . ' <>' ]; + if ( defined( $moduleMaintainers{ $modMeta->{x_file}[4] } ) ) { + foreach ( + split( '/', $moduleMaintainers{ $modMeta->{x_file}[4] }[1] ) ) + { + push @{ $modMeta->{author} }, $_; + } + + # last update was not by one of the named authors + if ( defined( $modMeta->{x_vcs} ) ) { + my $lastEditor = $modMeta->{x_vcs}[15]; + push @{ $modMeta->{author} }, + $modMeta->{x_vcs}[15] . ' (last release only) <>' + unless ( grep( m/^$lastEditor$/i, @{ $modMeta->{author} } ) ); + } } else { $modMeta->{author} = ['unknown <>']; } } unless ( $modMeta->{x_fhem_maintainer} ) { - if ( defined( $modMeta->{x_vcs} ) ) { - $modMeta->{x_fhem_maintainer} = [ $modMeta->{x_vcs}[15] ]; + if ( defined( $moduleMaintainers{ $modMeta->{x_file}[4] } ) ) { + foreach ( + split( '/', $moduleMaintainers{ $modMeta->{x_file}[4] }[1] ) ) + { + push @{ $modMeta->{x_fhem_maintainer} }, $_; + } + + # last update was not by one of the named authors + if ( defined( $modMeta->{x_vcs} ) ) { + my $lastEditor = $modMeta->{x_vcs}[15]; + push @{ $modMeta->{x_fhem_maintainer} }, $modMeta->{x_vcs}[15] + unless ( + grep( m/^$lastEditor$/i, @{ $modMeta->{x_fhem_maintainer} } ) + ); + } } } @@ -1262,6 +1288,7 @@ sub __GetMaintainerdata { . join( ' ', @line ); } else { + $moduleMaintainers{ $maintainer[0][4] } = \@maintainer; } } @@ -1350,6 +1377,13 @@ m/^((\S+) (((....)-(..)-(..))_((..):(..):(..))) (\d+) (?:\.\/)?((.+\/)?((?:(\d+) $update[17] = $17; # FHEM module name $update[18] = $18; # file extension + push @update, + fhemTimeGm( + $update[11], $update[10], $update[9], $update[7], + ( $update[6] - 1 ), + ( $update[5] - 1900 ) + ); + # this is a FHEM core update if ( $15 eq 'fhem.pl' ) { $coreUpdate = undef; @@ -1393,6 +1427,13 @@ m/^((\S+) (((....)-(..)-(..))_((..):(..):(..))) (\d+) (?:\.\/)?((.+\/)?((?:(\d+) $update[17] = $17; # FHEM module name $update[18] = $18; # file extension + push @update, + fhemTimeGm( + $update[11], $update[10], $update[9], $update[7], + ( $update[6] - 1 ), + ( $update[5] - 1900 ) + ); + # this is a FHEM module update if ($16) { if ( defined( $moduleUpdates{$17} ) ) { @@ -1736,12 +1777,6 @@ sub __SetXVersion { "IO::Socket::INET6": 0, "Socket6": 0, "TimeSeries": 0 - }, - "suggests": { - "Compress::Zlib": 0, - "FHEM::WinService": 0, - "IO::Socket::INET6": 0, - "Socket6": 0 } } },