Skip to content

Possible to truncate filename in logger #888

@mLjH

Description

@mLjH

Is there anyway to truncate the whole absolute path when logging?

Right now, my layout for logging is

"layout": {
   "type": "pattern",
   "pattern": "[%d{yyyy-MM-ddThh:mm:ss.SSS}] [%p] %c %f %l - %m"
},

But the filename option is printing out the whole absolute path to the file. I would like to have possibly the option to see either
filename.js OR .../folder/filename.js

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions