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


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

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

Started byKelly Brazil <kellyjonbrazil@gmail.com>
First post2020-06-05 23:40 +0200
Last post2020-06-05 23:40 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.debian.maint.python


Contents

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

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

FromKelly Brazil <kellyjonbrazil@gmail.com>
Date2020-06-05 23:40 +0200
SubjectBug#962239: RFP: jc -- converts command output to JSON
Message-ID<Aesee-1Qw-3@gated-at.bofh.it>
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

[toc] | [standalone]


Back to top | Article view | linux.debian.maint.python


csiph-web