journalctl: add --output-fields= (#7181)
authorLars Karlitski <lars@karlitski.net>
Fri, 27 Oct 2017 03:10:47 +0000 (05:10 +0200)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Fri, 27 Oct 2017 03:10:47 +0000 (12:10 +0900)
commitcc25a67e2af21833f9fef5aba6e16beafa03b0c7
tree404ff13bb957e8b462862c465e01d23b9bfe72be
parenta8caf8b251c1f298efc69d0049d53ead2bc98d57
journalctl: add --output-fields= (#7181)

This option allows restricting the shown fields in the output modes that
would normally show all fields. It allows clients that are only
interested in a subset of the fields to access those more efficiently.
Also, it makes the resulting size of the output more predictable.

It has no effect on the various `short` output modes, because those
already only show a subset of the fields.
man/journalctl.xml
src/journal-remote/journal-gatewayd.c
src/journal/journalctl.c
src/shared/logs-show.c
src/shared/logs-show.h
test/TEST-04-JOURNAL/test-journal.sh