https://github.com/fortio/logc
Convert fortio.org/log JSON structured log back to console/text output
https://github.com/fortio/logc
Last synced: 29 days ago
JSON representation
Convert fortio.org/log JSON structured log back to console/text output
- Host: GitHub
- URL: https://github.com/fortio/logc
- Owner: fortio
- License: apache-2.0
- Created: 2023-06-16T17:08:43.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2025-04-07T21:56:18.000Z (6 months ago)
- Last Synced: 2025-07-03T08:54:05.054Z (3 months ago)
- Language: Go
- Size: 978 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# logc
Converts [fortio.org/log](https://github.com/fortio/log#log) JSON structured log back to console/text output with colorsNote that since log 1.6 output is colorized already by default on terminals. But this is to interpret/colorize server logs. The output is very similar except for attributes where this is simpler/faster output reversing the attributes string "as is".
## Example
```
go run ./levelsDemo 2>&1 | logc
```
If you don't want colors; pass `-no-color`
## Installation
If you have a recent go installation already:
```shell
CGO_ENABLED=0 go install fortio.org/logc@latest
```Or get one of the [binary releases](https://github.com/fortio/logc/releases)
Or using the docker image
```shell
docker run fortio/logc
```Or using brew (mac)
```shell
brew install fortio/tap/logc
```# Development
Run make for both go tests and human check colorization example
```
make
```