mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Mar 2006
Posts: 47
C
Ameglian cow
OP Offline
Ameglian cow
C
Joined: Mar 2006
Posts: 47
Related to my other thread about allowing customization of default text, how about changing the way text is logged and viewed.

For instance, the way events are logged now, I can't tell the difference between ACTION events and, say, KICK events: default text shows up colorless in logs. I would like an option to have logging add color codes for default text. This leads to my other suggestion: a simple option to view Logs naturally using mIRC windows. Here's the code I'm using for it right now:

Code:
alias logfiles {
  /window -c @Logfiles 
  /window -lex @Logfiles 
  /var %loop = 1, %file
  while (1) {
    %file = $findfile($qt($logdir),*.log,%loop)
    if (!%file) break
    aline @Logfiles %file
    inc %loop
  }
  /filter -awwc @Logfiles @Logfiles logsort
}

;>>>Alias that sorts logfiles first by channel name and then by modification date:
alias logsort {
  if ($gettok($1,1,46) != $gettok($2,1,46)) return $iif($gettok($1,1,46) < $gettok($2,1,46),1,-1)
  if ($file($qt($1)).mtime != $file($qt($2)).mtime) return $iif($file($qt($1)).mtime > $file($qt($2)).mtime,1,-1)
  return 0
}
menu @Logfiles {
  dclick:{
    window -ex @Logfile
    filter -cfw $qt($sline(@Logfiles,1)) @Logfile *
    window -c @Logfiles
  }
}

Joined: Mar 2006
Posts: 47
C
Ameglian cow
OP Offline
Ameglian cow
C
Joined: Mar 2006
Posts: 47
Just as a follow up, I have since realized how stupid that first part was, regarding the color tags. >_< Sorry. The second part still stands. =/

Why does mIRC make [name].N.log files, with sessions that take place before and after the original [name].log file? I'm rewriting that, too, but I can't make a suggestion for something that's probably like that for a good reason...


Link Copied to Clipboard