Skip to content

Instantly share code, notes, and snippets.

@kddlb
Last active September 19, 2016 23:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kddlb/761465d463dcf62f51263604cef60fbf to your computer and use it in GitHub Desktop.
Save kddlb/761465d463dcf62f51263604cef60fbf to your computer and use it in GitHub Desktop.
ZNC Log JSON
[{
"time": "19:37:11",
"nickname": "Nimono",
"message": "I need hugs"
}, {
"time": "17:21:23",
"nickname": "NickServ",
"notice": "You are now identified for KDDLB."
}, {
"time": "17:18:56",
"nickname": "gold_lightning",
"hostmask": {
"username": "gl",
"hostmask": "745B72.C9F57F.DE94CD.3FB971"
},
"happening": "join"
}, {
"time": "23:36:24",
"nickname": "RingtailedFox",
"hostmask": {
"username": "FoxFoxFox",
"hostmask": "bdnk-c9282f80.home.cgocable.net"
},
"happening": "part",
"reason": "\"Leaving\""
}, {
"time": "19:46:26",
"nickname": "Xenesis",
"hostmask": {
"username": "Xenesis",
"hostmask": "bdnk-d1a24292.iinet.net.au"
},
"happening": "quit",
"reason": "Ping timeout: 121 seconds"
}, {
"time": "22:22:57",
"formerNickname": "GrumpeiYokoi",
"newNickname": "MathOnNapkins"
}, {
"time": "15:33:46",
"nickname": "Aceaddo",
"action": "hatpats"
}, {
"time": "09:24:57",
"nickname": "Server",
"mode": "+nst"
}, {
"time": "02:31:44",
"nickname": "ChanServ",
"mode": "+o",
"targets": "CaptainJistuce"
}]

Message: ^\[(?'Date'\d{2}:\d{2}:\d{2})\] <(?'Nickname'.*)> (?'Message'.*)$

Notice: ^\[(?'Date'\d{2}:\d{2}:\d{2})\] -(?'Nickname'.*)- (?'Message'.*)$

Joins: ^\[(?'Date'\d{2}:\d{2}:\d{2})\] \*\*\* (?'Happening'Joins): (?'Nickname'.*) \((?'Hostmask'(?'Username'.*)@(?'Hostname'.*))\)$

PartsOrQuits: ^\[(?'Date'\d{2}:\d{2}:\d{2})\] \*\*\* (?'Happening'Parts|Quits): (?'Nickname'.*) \((?'Hostmask'(?'Username'.*)@(?'Hostname'.*))\) \((?'QuitReason'.*)\)$

NicknameChange: ^\[(?'Date'\d{2}:\d{2}:\d{2})\] \*\*\* (?'FormerNickname'.*) is now known as (?'NewNickname'.*)$

Action: ^\[(?'Date'\d{2}:\d{2}:\d{2})\] \* (?'Nickname'\w*) (?'Action'.*)$

ModeChange: ^\[(?'Date'\d{2}:\d{2}:\d{2})\] \*\*\* (?'Nickname'\w*) sets mode: (?'Mode'.*)( (?'Target'.*))?$

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment