NAME
pq - jq for protobuf - parse protobuf generically
SYNOPSIS
pq [
--msgtype=STRING] [
--stream=DELIMITER] [
--trail=DELIMITER]
DESCRIPTION
pq parses a compiled protobuf message with .fdset files located in
'~/.pq/'. See more at https://github.com/sevagh/pqrs.
pq operates on stdin by default. Use files with the <filename pipe.
OPTIONS
- --msgtype=STRING
-
Use this message type to decode protobuf - must be a fully qualified message
name e.g. 'com.example.dog.Dog'. Default behavior is to try to guess the
message type. Guessing and msgtype apply to every message in a stream.
**WARNING 1**: since protobuf treats fields as positional, similar
protos (e.g. Dog: <Int: age, String: breed>, Person: <Int: ssn,
String: name>) are indistinguishable.
**WARNING 2**: guessing cannot distinguish between user-specified
nulls and empty fields. E.g., if you specify an <Int, String,
String> as <5, "hello", null>, pqrs discards the
correct schema because of the null.
- --stream=DELIMITER
-
Parse a delimited stream. The delimiter is specified as a string. For now
the only supported delimiter is "varint" (this is the way it's
done by Google in delimited_message_util).
- --trail=NUM
-
Delete NUM number of trailing characters between streamed messages.
ENVIRONMENT VARIABLES
- FDSET_PATH
-
Specify alternative fdset path. Default is '~/.pq/'.