[ic] Catalog error.log timestamp format?

Mike Heins mike at perusion.com
Wed Jan 23 16:18:31 UTC 2013


Quoting IC (ic at tvcables.co.uk):
> Hi Folks,
> 
> Where is the catalog error.log timestamp defined, I need to change the
> format so it only shows the first 3 letters of the month, eg Jan rather than
> January

Right now it isn't configurable, it is set to the HTTP common logtime
format. However, you could modify lib/Vend/Util.pm and make the
logtime() routine configurable:

# Returns time in HTTP common log format
sub logtime {
    return POSIX::strftime($::Variable->{MV_LOGTIME_FORMAT} || "[%d/%B/%Y:%H:%M:%S %z]", localtime());
}

Then in catalog.cfg:

    Variable MV_LOGTIME_FORMAT [%d/%b/%Y:%H:%M:%S %z]

-- 
Mike Heins
Perusion -- Expert Interchange Consulting    http://www.perusion.com/
phone +1.765.253.4194  <mike at perusion.com>

"I find that a great part of the information I have was acquired
by looking up something and finding something else on the way."
-- Franklin Pierce Adams



More information about the interchange-users mailing list