clog

command module
v0.0.0-...-739f4af Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 9, 2022 License: BSD-3-Clause Imports: 13 Imported by: 0

README

Clog - Cool Log 😎🪵

Pipe structured JSON logging outputs to Clog and let it pretty-print it for you 👨🏻‍🎨

Clog reads JSON logs from Stdin, parses and pretty-prints them according to the configuration. A configuration file can be provided with -c, the default config file path is clog.toml. If the config file isn't found then the defaults apply.

clog -i makes clog ignore OS interrupt signals, this can be useful to allow the process that pipes to clog and handles interrupt signals to exit gracefuly. If you run clog -i without piping anything to its input you can just press CTRL+D (EOF) and exit clog.

Installation

go install -v github.com/romshark/clog@latest

Also make sure go/bin is in your PATH.

Example

cat example.txt | clog

Styling

Supported style attributes:

bold
faint
italic
underline
blinkslow
blinkrapid
reversevideo
concealed
crossedout
fg-black
fg-red
fg-green
fg-yellow
fg-blue
fg-magenta
fg-cyan
fg-white
fg-hiblack
fg-hired
fg-higreen
fg-hiyellow
fg-hiblue
fg-himagenta
fg-hicyan
fg-hiwhite
bg-black
bg-red
bg-green
bg-yellow
bg-blue
bg-magenta
bg-cyan
bg-white
bg-hiblack
bg-hired
bg-higreen
bg-hiyellow
bg-hiblue
bg-himagenta
bg-hicyan
bg-hiwhite

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL