Announcement

Collapse
No announcement yet.

GCC 9 Offering Up Better Error Messages, JSON Output Support

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #11
    Originally posted by skeevy420 View Post

    Not to mention how much easier it would be to write code if there was a standardized output model like that. Being able to source a variable over some weird ass grep/sed/cut one-liner would be nice.

    Just look at all the crap with /usr merges and systemd...we can't even agree on where to save or how to start stuff. We damn sure ain't gonna agree on a standardized output model that every frickin program would somehow be expected to follow, but damn would it be nice.
    You'd have to standardise the schema, a near impossible task. Standardising the serialization format doesn't get you far. Most tools already offer a machine readable format that's easy to parse/deserialize, it's the schema that differs.
    [QUOTE=starshipeleven;n1085318]
    For the love of Bob. Command line is a scriptable user interface.

    If you need to get a real job done use a real scripting programming language like Lua or Python with the appropriate library.[QUOTE]
    This!

    Comment


    • #12
      Originally posted by edgar444 View Post
      PS: I find JSON to be awkward format for humans to manipulate or read.
      I doubt anyone will find it easy to read. It is mostly designed for machine-to-machine communication of "objects", which is a quite alien concept for non-programmers.

      I mean OK if you HAVE to read or write it by hand it's not as cringy and syntax-error-prone as XML, but it does feel like abastract machiney language, unlike yaml and similar.

      Comment


      • #13
        Originally posted by starshipeleven View Post
        For the love of Bob. Command line is a scriptable user interface.

        If you need to get a real job done use a real scripting programming language like Lua or Python with the appropriate library.
        Yes absolutely this.

        Almost every Linux/Unix command line utility is either trivial to do using C or script (ls, find) or the command-line tool is already based on a library (curl, gzip).

        Comment

        Working...
        X