Log File Rules |
Top Previous Next |
Rules have the following format:
log <events> in <targets> from <nicknames> to <output> [options]
<events> The events are thesame as the remote name for that event, ie. "text,notice,join,part,action,kick,quit,nick,mode,topic,all" Multiple events are to be seperated by commas. The event 'all' matches every event. Events can be negated by prefixing them with a exclamation mark (eg. !kick).
<targets> The target is the 'target' of the event. This could be a channel, nickname (for query), a '#' or '?' to match all channel/queries. Seperate targets by commas.
<nicknames> The user(s) triggering the event, seperated by commas. Can be a wildcard. Nicknames can be prefixed with an @ or + to indicate that they must be opped or voiced.
<output> The output is where the log is sent to. This can be a file, a window, a #channel/nick, or a command. Each are prefixed by their type, ie.
window @hi irc nick/#chan file &t.&w.log
you could put specify the window as an /echo switch due to the way it works, such as 'window -a'. Logs will then echo in the active window.
File's have meta-characters starting with &. These are:
&c - active Channel (same as &a) &t - Target (usefull for rules involving both channels AND queries) &n - Nickname &w - Network &dd - date (format yyyy_mm_dd) &dm - date (format mmm_yyyy) &dfyyyy = $asctime(yyyy) &dfyy = $asctime(yy) &dfmmmm = $asctime(mmmm) &dfmmm = $asctime(mmm) &dfmm = $asctime(mm) &dfm = $asctime(m) &dfdddd = $asctime(dddd) &dfddd = $asctime(ddd) &dfdd = $asctime(dd) &dfd = $asctime(d) &dpw - month section (1-4) &dpt - month section (1-8)
Important note: currently all files must be specified in "short" format (ie no spaces).
<options> Options modify the way the event is logged: strip - strip codes from logged text notimestamp - dont timestamp entries in the file noencrypt - dont use encryption in this channel stop - dont trigger subsequent log rules for event
Examples:
** EXAMPLE 1 **
log join,part in # from * to file Logs\modes.&c.log strip notimestamp
This will log all joins and parts in any channel (#) from any nickname to the file modes.<#channelname>.log with no timestamp. The 'strip' on the end means that control codes are stripped from every event.
** EXAMPLE 2 **
To do the standard mIRC logging, add the following rule:
log all in #,? from * to file Logs\&t.&w.log
However, this will make private notices also log to query logs, so you may want to use this:
log !notice,all in #,? from * to file Logs\&t.&w.log
If you were in a channel that you don't want to log, such as #warez, you could make it:
log !notice,all in !#warez,#,? from * to file Logs\&t.&w.log
The !notice MUST come before the 'all', and the !#warez MUST come before the other targets due to the way it's parsed. In other words, make sure you put the negated parameters before the others.
** EXAMPLE 3 **
log mode in #scripters from @* to window @opwatch
This will log all channel modes that ops do into the window @logwatch. Generally only ops can do modes anyway, but you get my point.
** EXAMPLE 4 **
log all in #,? from * to file Logs/&w/&t/&dm.log
This will do standard mirc style logging, but store log files in a directory hierarchy like network/chanell/Date.log
** EXAMPLE 5 **
/mclog add log all in #,? from * to file E:\MYDOCU~1\MISCCO~1\Logs\irc\&w\&dfyyyy\&dfmm&dfmmmm\&t&dpw.log strip
More examples:
log !mode,all in #,? from * to file Logs\Mirc\&dfyyyy\&dfmm&dfmmmm\&t\&dpw&dfmmm&dfyy.log strip stop |