From: Moritz Bunkus Date: Wed, 5 Jun 2013 08:00:42 +0000 (+0200) Subject: locales.pl: Suche nach nicht benutzten Templates gefixt X-Git-Tag: release-3.1.0beta1~364 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=24bff6e45ea380c65791b68745f615763d9472ab;p=kivitendo-erp.git locales.pl: Suche nach nicht benutzten Templates gefixt --- diff --git a/scripts/locales.pl b/scripts/locales.pl index d8df86296..c4adf1cf1 100755 --- a/scripts/locales.pl +++ b/scripts/locales.pl @@ -43,6 +43,10 @@ our $self = {}; our $missing = {}; our @lost = (); +my %ignore_unused_templates = ( + map { $_ => 1 } qw(common/help_overlay.html ct/testpage.html generic/autocomplete.html oe/periodic_invoices_email.txt part/testpage.html t/render.html t/render.js) +); + my (%referenced_html_files, %locale, %htmllocale, %alllocales, %cached, %submit, %jslocale); my ($ALL_HEADER, $MISSING_HEADER, $LOST_HEADER); @@ -655,7 +659,7 @@ sub search_unused_htmlfiles { if (-d $entry) { push @unscanned_dirs, $entry; - } elsif (($entry =~ /_master.html$/) && -f $entry && !$referenced_html_files{$entry}) { + } elsif (!$ignore_unused_templates{strip_base($entry)} && -f $entry && !$referenced_html_files{$entry}) { print "W: unused HTML template: " . strip_base($entry) . "\n"; }