Skip to content

Instantly share code, notes, and snippets.

@skowron-line
Last active December 30, 2023 18:58
Show Gist options
  • Save skowron-line/000733c361f63206cc9e to your computer and use it in GitHub Desktop.
Save skowron-line/000733c361f63206cc9e to your computer and use it in GitHub Desktop.
lnav Monolog format
{
"monolog": {
"title": "Monolog log file",
"description": "Monolog log format",
"url": "https://github.com/Seldaek/monolog",
"regex": {
"default": {
"pattern": "\\[(?P<timestamp>.*)\\] (?P<logger>\\w+).(?P<level>\\w+): (?P<message>[^\\[\\{]+) (?P<context>[\\[\\{].*[\\]\\}]) (?P<extra>[\\[\\{].*[\\]\\}])"
}
},
"level-field" : "level",
"level" : {
"error" : "ERROR",
"debug" : "DEBUG",
"info" : "INFO",
"warning" : "WARNING"
},
"value": {
"logger": {
"kind": "string",
"identifier": true
},
"level": {
"kind": "string",
"identifier": true
},
"message": {
"kind": "string"
},
"context": {
"kind": "string"
},
"extra": {
"kind": "string"
}
},
"sample": [
{
"line": "[2015-08-10 15:05:12] event.DEBUG: Notified event \"kernel.terminate\" to listener \"Symfony\\Component\\HttpKernel\\EventListener\\ProfilerListener::onKernelTerminate\". [] []"
}
]
}
}
@ostrolucky
Copy link

I've created https://github.com/ostrolucky/lnav-formats as a replacement of this

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