jc: Converts the output of popular command-line tools to JSON

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

InfluxDB - Power Real-Time Data Analytics at Scale
Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
  • jc

    CLI tool and python library that converts the output of popular command-line tools, file-types, and common strings to JSON, YAML, or Dictionaries. This allows piping of output to tools like jq and simplifying automation scripts.

  • wireguard-tools

    Mirror only. Official repository is at https://git.zx2c4.com/wireguard-tools

  • Oh, this is cool. I'm a huge proponent of CLI tools supporting sensible JSON output, and things like https://github.com/WireGuard/wireguard-tools/blob/master/con... and PowerShell's |ConvertTo-Json are a huge part of my management/monitoring automation efforts.

    But, unfortunately, sensible is doing some heavy lifting here and reality is... well, reality. While the output of things like the LSI/Broadcom StorCLI 'suffix the command with J' approach and some of PowerShell's COM-hiding wrappers (which are depressingly common) is technically JSON, the end result is so mindbogglingly complex-slash-useless, that you're quickly forced to revert to 'OK, just run some regexes on the plain-text output' kludges anyway.

    Having said that, I'll definitely check this out. If the first example given, parsing dig output, is indeed representative of what this can reliably do, it should be interesting...

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
  • llama.cpp

    LLM inference in C/C++

  • textfsm

    Python module for parsing semi-structured text into python tables.

  • Interesting project! But I expected them to be using textfsm as a first step parser. textfsm is heavily used to implement CLI parsing in networking devices.


  • libxo

    The libxo library allows an application to generate text, XML, JSON, and HTML output using a common set of function calls. The application decides at run time which output style should be produced.

  • > In FreeBSD, this problem was solved with libxo[0]:

    Libxo happens to be in the base system, but it is generally available:

    * https://github.com/Juniper/libxo

    * https://libxo.readthedocs.io/en/latest/

  • nushell

    A new type of shell

  • > In PowerShell, structured output is the default and it seems to work very well.

    PowerShell goes a step beyond JSON, by supporting actual mutable objects. So instead of just passing through structured data, you effectively pass around opaque objects that allow you to go back to earlier pipeline stages, and invoke methods, if I understand correctly: https://learn.microsoft.com/en-us/powershell/module/microsof....

    I'm rather fond of wrappers like jc and libxo, and experimental shells like https://www.nushell.sh/. These still focus on passing data, not objects with executable methods. On some level, I find this comfortable: Structured data still feels pretty Unix-like, if that makes sense? If I want actual objects, then it's probably time to fire up Python or Ruby.

    Knowing when to switch from a shell script to a full-fledged programming language is important, even if your shell is basically awesome and has good programming features.

  • ollama

    Get up and running with Llama 3, Mistral, Gemma, and other large language models.

  • I use ollama (https://ollama.ai/) which supports most of the big new local models you might've heard of: llama2, mistral vicuna etc. Since I have 16GB of RAM, I stick to the 7b models.

  • SaaSHub

    SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives

    SaaSHub logo
NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • What API or program would you like to see re-implemented on top of another platform?

    4 projects | /r/linux | 4 May 2022
  • Unix Shell pipelines that use structured data like CSV, JSON, etc

    4 projects | /r/computerscience | 10 Sep 2021
  • Bringing the Unix Philosophy to the 21st Century: Make JSON a default output option.

    6 projects | /r/programming | 23 Aug 2021
  • You shouldn't parse the output of ls(1)

    4 projects | news.ycombinator.com | 31 Dec 2021
  • Tips on Adding JSON Output to Your CLI App

    2 projects | /r/programming | 6 Dec 2021