+
Skip to content

Feat: color log output based on level #634

@addshore

Description

@addshore

log output from the logger has a known format...

For example:

[lb.ble] DEBUG: Starting BLE scan with duration: 3000 ms
[lb.i2c.write] DEBUG: Wrote 67 bytes
[lb.h.wifi] INFO: WiFi scan completed, found 3 access points

It could / would be nice to have this be coloured to make spotting errors etc easier within walls of text and logs.

There should be an option to output with no colour, and some automatic detection
eg. https://gitlab.wikimedia.org/repos/releng/cli/-/blob/eb50a6116847c87d6acc782141786d7d85c72eca/internal/util/output/color.go#L9-14

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      点击 这是indexloc提供的php浏览器服务,不要输入任何密码和下载