From eb7bc9cd6db5d70a8e44881aa8a13a3c57b0d118 Mon Sep 17 00:00:00 2001 From: klaus01 Date: Sun, 11 Jan 2009 20:43:15 +0000 Subject: [PATCH] attr global logdir git-svn-id: svn://svn.code.sf.net/p/fhem/code/trunk@321 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/fhem.pl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/fhem/fhem.pl b/fhem/fhem.pl index 7512f1a80..8236c37e1 100755 --- a/fhem/fhem.pl +++ b/fhem/fhem.pl @@ -149,7 +149,7 @@ my %intAt; # Internal at timer hash. my $nextat; # Time when next timer will be triggered. my $intAtCnt=0; my $AttrList = "room comment"; -my $cvsid = '$Id: fhem.pl,v 1.63 2009-01-09 17:31:43 rudolfkoenig Exp $'; +my $cvsid = '$Id: fhem.pl,v 1.64 2009-01-11 20:43:15 klaus01 Exp $'; my $namedef = "where is either:\n" . "- a single device name\n" . @@ -165,7 +165,7 @@ $modules{_internal_}{LOADED} = 1; $modules{_internal_}{AttrList} = "archivecmd allowfrom archivedir configfile lastinclude logfile " . "modpath nrarchive pidfilename port statefile title userattr " . - "verbose:1,2,3,4,5 mseclog version nofork"; + "verbose:1,2,3,4,5 mseclog version nofork logdir"; $modules{_internal_}{AttrFn} = "GlobalAttr"; @@ -1716,6 +1716,7 @@ ResolveDateWildcards($@) my $j = sprintf("%03d", $t[7]+1); $f =~ s/%j/$j/g; my $U = sprintf("%02d", int(($t[7]-$t[6]+6)/7)); $f =~ s/%U/$U/g; my $V = sprintf("%02d", int(($t[7]-$t[6]+7)/7)+1); $f =~ s/%V/$V/g; + $f =~ s/%ld/$attr{global}{logdir}/g if($attr{global}{logdir}); #log directory return $f; }