Date: Mon, 2 Mar 2015 12:53:10 +0400 From: Arseny Nasokin <eirnym@gmail.com> To: Allan Jude <allanjude@freebsd.org> Cc: freebsd-current <freebsd-current@freebsd.org> Subject: Re: Massive libxo-zation that breaks everything Message-ID: <CAO8GK0oJeHQVZm6t_8f9TTZvjJ94CqVZxncv2zzJ0UMc2UXF5g@mail.gmail.com> In-Reply-To: <54F3C134.5080207@freebsd.org> References: <54F31510.7050607@hot.ee> <54F34B6E.2040809@astrodoggroup.com> <CAG=rPVfcB1Fy_8mHq-t5Ay07yrzuSGthQ0ZcGzvp0XG9gSSzkg@mail.gmail.com> <54F35F29.4000603@astrodoggroup.com> <54F36431.30506@freebsd.org> <CAO8GK0oFwQXb=wKNX%2Bp7fHguK-hk=EXr%2Bbrx1SWvkdnv4z3efQ@mail.gmail.com> <54F3C134.5080207@freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On 2 March 2015 at 04:47, Allan Jude <allanjude@freebsd.org> wrote: > On 2015-03-01 19:20, Arseny Nasokin wrote: > > On 1 March 2015 at 22:10, Allan Jude <allanjude@freebsd.org> wrote: > > > >> On 2015-03-01 13:49, Harrison Grundy wrote: > >>> Thanks! > >>> > >>> That does seem useful, but I'm not sure I see the reasoning behind > >>> putting into base, over a port or package, since processing XML in base > >>> is a pain, and it can't serve up JSON or HTML without additional > >>> utilities anyway. > >>> > >>> (If I'm reviving a long-settled thing, let me know and I'll drop it. > I'm > >>> trying to understand the use case for this.) > >>> > >>> --- Harrison > >>> > >>> On 03/01/15 10:31, Craig Rodrigues wrote: > >>>> On Sun, Mar 1, 2015 at 9:25 AM, Harrison Grundy < > >>>> harrison.grundy@astrodoggroup.com> wrote: > >>>> > >>>>> > >>>>> > >>>>> If someone could summarize what this is, I'd greatly appreciate it. > >>>>> > >>>> > >>>> > https://lists.freebsd.org/pipermail/freebsd-arch/2014-July/015633.html > >>>> _______________________________________________ > >>>> freebsd-current@freebsd.org mailing list > >>>> http://lists.freebsd.org/mailman/listinfo/freebsd-current > >>>> To unsubscribe, send any mail to " > >> freebsd-current-unsubscribe@freebsd.org" > >>>> > >>> _______________________________________________ > >>> freebsd-current@freebsd.org mailing list > >>> http://lists.freebsd.org/mailman/listinfo/freebsd-current > >>> To unsubscribe, send any mail to " > >> freebsd-current-unsubscribe@freebsd.org" > >>> > >> > >> I think you're missing the important bit here. > >> > >> This isn't about adding a parser for anything, this is about making the > >> tools in base, like netstat, wc, uptime, etc, output in JSON or XML, so > >> you can use the data programmatically. > >> > >> Your scripts no longer have to rely on awk/sed/grep magic to get a > >> specific bit of information out of the uptime command, the command can > >> just output the data in a structured machine readable format. > >> > >> I am not sure how you can put netstat into the ports tree. > >> > >> > >> -- > >> Allan Jude > >> > >> > > Hi, > > > > Do we have command-line tools in base which work with XML/JSON from stdin > > or file? > > > > -- Eir Nym > > _______________________________________________ > > freebsd-current@freebsd.org mailing list > > http://lists.freebsd.org/mailman/listinfo/freebsd-current > > To unsubscribe, send any mail to " > freebsd-current-unsubscribe@freebsd.org" > > > > Not really, although there are libraries for such (bsdxml, libucl which > can read JSON) in base. > > I am working on a tool that can do some of this: > > https://github.com/allanjude/uclcmd/ > > -- > Allan Jude > > Allan, What do you think about tools like plutil(1) or defaults(1) from Mac OS X. Plists are dict-like structures (XML and JSON too). -- Eir Nym
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAO8GK0oJeHQVZm6t_8f9TTZvjJ94CqVZxncv2zzJ0UMc2UXF5g>