From 061d111f563e63a47a3f4d55d389ec76e10592d1 Mon Sep 17 00:00:00 2001 From: rudolfkoenig Date: Tue, 12 Jan 2016 08:26:07 +0000 Subject: [PATCH] commandref_join.pl: noWarnings patch from justme1968 (Forum #46371) git-svn-id: https://svn.fhem.de/fhem/trunk@10471 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/FHEM/98_update.pm | 4 ++-- fhem/contrib/commandref_join.pl | 7 +++++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/fhem/FHEM/98_update.pm b/fhem/FHEM/98_update.pm index 760b2d01d..d2b0aa822 100644 --- a/fhem/FHEM/98_update.pm +++ b/fhem/FHEM/98_update.pm @@ -384,8 +384,8 @@ doUpdate($$$$) if($canJoin && $upd_needJoin && $curr == $max) { chdir($root); - uLog(1, "Calling $^X $cj, this may take a while"); - my $ret = `$^X $cj`; + uLog(1, "Calling $^X $cj -noWarnings, this may take a while"); + my $ret = `$^X $cj -noWarnings`; foreach my $l (split(/[\r\n]+/, $ret)) { uLog(1, $l); } diff --git a/fhem/contrib/commandref_join.pl b/fhem/contrib/commandref_join.pl index e036fe7a8..7ad6f3b8d 100755 --- a/fhem/contrib/commandref_join.pl +++ b/fhem/contrib/commandref_join.pl @@ -8,7 +8,10 @@ use strict; use warnings; # $Id$ + +my $noWarnings = grep $_ eq '-noWarnings', @ARGV; use constant TAGS => qw{ul li code b i u table tr td}; + my %mods; my @modDir = ("FHEM"); foreach my $modDir (@modDir) { @@ -115,12 +118,12 @@ EOF } } print "$lang $mods{$mod}: No a-tag with name=\"$mod\" \n" - if(!$suffix && $docCount && !$hasLink); + if(!$suffix && $docCount && !$hasLink && !$noWarnings); foreach $tag (TAGS) { print("$lang $mods{$mod}: Unbalanced $tag ". "($tagcount{$tag}, last line ok: $llwct{$tag})\n") - if($tagcount{$tag}); + if($tagcount{$tag} && !$noWarnings); } }