warn on projects with unregistered/unknown "platform" field.
[www.jankratochvil.net.git] / project / Index.pm
index c0ba713..07475ff 100755 (executable)
@@ -43,6 +43,7 @@ print(project::Lib->views("Detailed"));
 print(project::Lib->platforms(undef(),"novskip"=>1));
 
 my %item=project::Lib->name_to_hashref();
+my %item_unused=%item;
 
 my @platforms=@project::Lib::platforms;
 while (@platforms) {
@@ -55,6 +56,7 @@ while (@platforms) {
                        (lc($item{$a}{"name"}) cmp lc($item{$b}{"name"}));
                        } map({ $item{$_}{"platform"} ne $platform_sym ? () : ($_); } keys(%item));
        for my $project (@projects) {
+               delete $item_unused{$project};
                my $t="";
 
                $t.="<h3>".a_href("/project/$project/",$item{$project}{"name"}.": ".$item{$project}{"summary"})."</h3>\n";
@@ -71,6 +73,7 @@ while (@platforms) {
                        }
                }
        }
+cluck "INVALID 'platform': $_" for keys(%item_unused);
 
 
 exit;