X-Authentication-Warning: delorie.com: mail set sender to geda-user-bounces using -f X-Recipient: geda-user AT delorie DOT com X-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=F47lNkNo6KxM6K493zWc8khqDLbQeox8EeBlcQL7dkc=; b=OPaeUKqSjFGJ1wxEdijb4/+lKZU2W9+fSdNHl13sbEzen8tpBwGTroACIM3DrlnFVW 1HLtcCtzmvxU0vJ26kuESiPKJ4RhyCSJMu7Rmdl+XJrSEYm65Rqcuw2LmCFoW1v3NP5c 2Wjp3cach0yInKs/EVR5NhiTCsb2MRQIw1eWG+AqMLexKTusNpg57X3ckNF7kSdkWPWd LaOk4KjbfOkIRdt5e99/bN49BGMCI7Q22pkkOrzqg8zivj9C4vUuqtfYBy51HqUqoqCH dpBWuu9SPRejBnR4fE+oRgK45v5koApUVx2kEyBEfU082VoMRDYj72osnCtvz2JmQKfv 1a9w== MIME-Version: 1.0 X-Received: by 10.194.6.196 with SMTP id d4mr51288022wja.120.1451189070557; Sat, 26 Dec 2015 20:04:30 -0800 (PST) In-Reply-To: References: <1512221837 DOT AA25291 AT ivan DOT Harhan DOT ORG> <20151222232230 DOT 12633 DOT qmail AT stuge DOT se> <0F6F1D0F-4F07-48EA-90FE-836EAD4E2354 AT noqsi DOT com> <0FCF3774-F93C-4BFF-BB61-636F75DCCACB AT noqsi DOT com> Date: Sat, 26 Dec 2015 19:04:30 -0900 Message-ID: Subject: Re: [geda-user] A fileformat library From: "Britton Kerin (britton DOT kerin AT gmail DOT com) [via geda-user AT delorie DOT com]" To: geda-user AT delorie DOT com Content-Type: multipart/alternative; boundary=047d7b5d49760d7bbc0527d9494d Reply-To: geda-user AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: geda-user AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk --047d7b5d49760d7bbc0527d9494d Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Fri, Dec 25, 2015 at 12:13 PM, John Doty wrote: > > On Dec 25, 2015, at 1:38 PM, Britton Kerin (britton DOT kerin AT gmail DOT com) [via > geda-user AT delorie DOT com] wrote: > > > > On Thu, Dec 24, 2015 at 1:39 PM, John Doty wrote: > >> >> On Dec 24, 2015, at 12:53 PM, Britton Kerin (britton DOT kerin AT gmail DOT com) >> [via geda-user AT delorie DOT com] wrote: >> >> Agreed. I like YAML for this reason. You get a parser in every languag= e >> for free, without any other library material required. >> >> AWK? sed? grep? cut? sort? >> > > Why not? Unless a newline in your regex really frightens you that much..= . > > >> Records separated by newline with fields separated by whitespace is >> *better* supported than YAML or any of the other candidates mentioned. T= he >> only things it lacks for our purposes is a spiffy name and the need for >> extra layers of lasagna code. >> > > Fine. Put your money where your mouth is. Send me a full parser for pcb > files with binding for perl, python, ruby, C, and virtually every other > extant language. > > > I=E2=80=99m not talking about pcb. I=E2=80=99m talking about geda-gaf > > Geda-gaf is a much cleaner design. The pcb format doesn=E2=80=99t even re= present a > proper model of what a printed circuit board is. > > Writing a parser for geda-gaf files is simpler than penetrating an API > wrapping such a parser. That doesn=E2=80=99t mean you can do either in an= instant. > Highly unlikely for .sch, no chance whatsoever for pcb. We're talking about one function call in each direction form YAML/JSON. Not that I would advocate doing anything to sch format. > It's easy so you should be able to get it to me BEFORE your next bs email= . > > If having common parser makes things so easy, you should be able to > document API=E2=80=99s > I thought you were the one who thought accessible file formats were a good idea, and bundling big APIs around them not necessarily? So there's nothing to document. Parsers are relatively easy but as you admit not exactly instantaneous, so why not use a setup that obviates the need for them? The major difference for people wanting to parse things themselves is that the fields have names, so you just read the name rather than digging through the spec or running a little experiment to figure out which positional field is which. In other words its easier for that purpose too. Using an accessible format is entirely in keeping with the toolbox philosophy which you normally advocate so strongly for in gEDA. Why should pcb be the only program that can easily fully parse pcb files? Britton --047d7b5d49760d7bbc0527d9494d Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable


On Fri, Dec 25, 2015 at 12:13 PM, John Doty <jpd AT noqsi DOT com> = wrote:

On Dec 25, 2015, at 1:38 PM, Britton Kerin (britton DOT kerin AT gmail DOT com) = [via geda-user AT d= elorie.com] <geda-user AT delorie DOT com> wrote:



On Thu, Dec 24, 2015 at 1:39 PM, John Doty <jpd AT noqsi DOT com> = wrote:

On Dec 24, 2015, at 12:53 PM, Britton Kerin (britton DOT kerin AT gmail DOT c= om) [via ged= a-user AT delorie DOT com] <geda-user AT delorie DOT com> wrote:

Agreed.=C2=A0 = I like YAML for this reason.=C2=A0 You get a parser in every language for f= ree, without any other library material required.
=
AWK? sed? grep? cut? sort?

Why not?=C2=A0 Unless a newline in your regex really frightens you = that much...
=C2=A0
Records separated by newline with fields separa= ted by whitespace is *better* supported than YAML or any of the other candi= dates mentioned. The only things it lacks for our purposes is a spiffy name= and the need for extra layers of lasagna code.

=
Fine.=C2=A0 Put your money where your mouth is.=C2=A0 Send me a = full parser for pcb files with binding for perl, python, ruby, C, and virtu= ally every other extant language.
=
I=E2=80=99m not talking about pcb. I=E2=80=99m talking about geda= -gaf

=C2=A0
Geda-gaf is a muc= h cleaner design. The pcb format doesn=E2=80=99t even represent a proper mo= del of what a printed circuit board is.

Writing a = parser for geda-gaf files is simpler than penetrating an API wrapping such = a parser. That doesn=E2=80=99t mean you can do either in an instant.
<= /div>

Highly unlikely for .sch, = no chance whatsoever for pcb.=C2=A0 We're talking about one function ca= ll in each direction form YAML/JSON.=C2=A0 Not that I would advocate doing = anything to sch format.
It's easy so you s= hould be able to get it to me BEFORE your next bs email.
<= /div>
If having common parser makes things so easy, you should = be able to document API=E2=80=99s

<= div style=3D"">I thought you were the one who thought accessible file forma= ts were a good idea, and bundling big APIs around them not necessarily?=C2= =A0 So there's nothing to document.=C2=A0 Parsers are relatively easy b= ut as you admit not exactly instantaneous, so why not use a setup that obvi= ates the need for them? The major difference for people wanting to parse th= ings themselves is that the fields have names, so you just read the name ra= ther than digging through the spec or running a little experiment to figure= out which positional field is which.=C2=A0 In other words its easier for t= hat purpose too.

Using an ac= cessible format is entirely in keeping with the toolbox philosophy which yo= u normally advocate so strongly for in gEDA.=C2=A0 Why should pcb be the on= ly program that can easily fully parse pcb files?

Britton
--047d7b5d49760d7bbc0527d9494d--