Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.maint.python > #12630

Bug#962239: RFP: jc -- converts command output to JSON

From Kelly Brazil <kellyjonbrazil@gmail.com>
Newsgroups linux.debian.maint.python
Subject Bug#962239: RFP: jc -- converts command output to JSON
Date 2020-06-05 23:40 +0200
Message-ID <Aesee-1Qw-3@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


Hi Python Team!

I’m the developer of jc - a tool that converts the output of dozens of command and file-types to JSON so you can use tools like jq to parse the output.

For example:

$ ls -l /usr/bin | jc --ls | jq '.[] | select(.size > 50000000)'
{
  "filename": "docker",
  "flags": "-rwxr-xr-x",
  "links": 1,
  "owner": "root",
  "group": "root",
  "size": 68677120,
  "date": "Aug 14 19:41"
}

or using the alternative "magic" syntax:

$ jc ls -l /usr/bin | jq '.[] | select(.size > 50000000)'
{
  "filename": "docker",
  "flags": "-rwxr-xr-x",
  "links": 1,
  "owner": "root",
  "group": "root",
  "size": 68677120,
  "date": "Aug 14 19:41"
}

I have a Request For Package open at https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=962239.

Please consider packaging jc. It is currently packaged for OpenSUSE, NixOS, macOS (Homebrew), and FreeBSD (ports). jc is currently in process for packaging on Fedora.

Thank you,
Kelly Brazil

Back to linux.debian.maint.python | Previous | Next | Find similar | Unroll thread


Thread

Bug#962239: RFP: jc -- converts command output to JSON Kelly Brazil <kellyjonbrazil@gmail.com> - 2020-06-05 23:40 +0200

csiph-web