From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marcelo de Moraes Serpa Subject: Re: Formal description of Org files Date: Fri, 15 Jul 2011 13:07:25 -0500 Message-ID: References: <4213EBED-2EFC-413F-8618-2A594AECEDCF@gmail.com> <877hav8lup.fsf@gmail.com> <2970.1302892280@alphaville.americas.hpqcorp.net> <20110420123741.GA21304@buga.lan> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=bcaec54315d2922be604a81f8552 Return-path: Received: from eggs.gnu.org ([140.186.70.92]:44894) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QhmnU-0008Ec-4C for emacs-orgmode@gnu.org; Fri, 15 Jul 2011 14:07:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QhmnP-0004Iy-Kf for emacs-orgmode@gnu.org; Fri, 15 Jul 2011 14:07:31 -0400 Received: from mail-ew0-f41.google.com ([209.85.215.41]:42888) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QhmnP-0004Is-30 for emacs-orgmode@gnu.org; Fri, 15 Jul 2011 14:07:27 -0400 Received: by ewy9 with SMTP id 9so928321ewy.0 for ; Fri, 15 Jul 2011 11:07:25 -0700 (PDT) In-Reply-To: <20110420123741.GA21304@buga.lan> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Olivier Schwander Cc: Nick Dokos , emacs-orgmode mailing list , Carsten Dominik --bcaec54315d2922be604a81f8552 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi guys, I was going to create a new thread, but this one seems to fit exactly what I'm looking for. I'm creating a web app that interacts with orgmode files and allows you to edit orgmode files on the browser. The edit part is not done. I'm quite goo= d at Javascript, and I wouldn't mind hacking something akin to orgmode elisp code and this will be what I'll do if everything else fails, but wouldn't using a grammar be a cleaner and more elegant solution? Thanks, Marcelo. On Wed, Apr 20, 2011 at 7:37 AM, Olivier Schwander < olivier.schwander@chadok.info> wrote: > Le 15 Apr 2011 14:31, Nick Dokos a =E9crit: > > Eric Schulte wrote: > > > > > If one goal of such a formal description of Org-mode would be to pars= e > > > text Org-mode files into an abstract syntax tree ... > > > > > > > I think this should be the starting point: what are the goals for all > this? > > Providing a formal description in EBNF is one thing. Preparing an > attribute > > grammar for input into a specific tool is another (and probably an orde= r > of > > magnitude - or two - harder) - what would the resulting parser(s) be us= ed > for? > > > > Clear(er) answers to these questions should go a long way towards > figuring out > > what specific tool(s) should be used - or whether it's at all necessary > to > > worry about that. > > The primary goal I see for such a formal description is to provide a > specification that third party parsers are supposed to respect. Writing > a real parser may be too much project specific and difficult to > generalize in a way usable by the community. > > During the development of neo[1], I was confronted to the need of > defining what is an org file (actually, what is an headline, a todo > keyword, a tag, a drawer, a timestamp, etc) and determining what is the > expected output of a parser. > > Maybe the most appropriate format for such a description would be free > text, letting parser developers choosing between context-free grammars, > regexps or whatever they want ( with a bunch of example org files for > reference and tests). > > Regards, > > Olivier > > [1] I am just discovering this thread > > --bcaec54315d2922be604a81f8552 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi guys,

I was going to create a new thread, but this on= e seems to fit exactly what I'm looking for.

I= 'm creating a web app that interacts with orgmode files and allows you = to edit orgmode files on the browser. The edit part is not done. I'm qu= ite good at Javascript, and I wouldn't mind hacking something akin to o= rgmode elisp code and this will be what I'll do if everything else fail= s, but wouldn't using a grammar be a cleaner and more elegant solution?=

Thanks,

Marcelo.

On Wed, Apr 20, 2011 at 7:37 AM, Olivier S= chwander <olivier.schwander@chadok.info> wrote:
Le 15 Apr 2011 14:31, Nick Dokos a =E9crit:=
> Eric Schulte <schulte.eric@gmail.com> wrote:
>
> > If one goal of such a formal description of Org-mode would be to = parse
> > text Org-mode files into an abstract syntax tree ...
> >
>
> I think this should be the starting point: what are the goals for all = this?
> Providing a formal description in EBNF is one thing. Preparing an attr= ibute
> grammar for input into a specific tool is another (and probably an ord= er of
> magnitude - or two - harder) - what would the resulting parser(s) be u= sed for?
>
> Clear(er) answers to these questions should go a long way towards figu= ring out
> what specific tool(s) should be used - or whether it's at all nece= ssary to
> worry about that.

The primary goal I see for such a formal description is to prov= ide a
specification that third party parsers are supposed to respect. Writing
a real parser may be too much project specific and difficult to
generalize in a way usable by the community.

During the development of neo[1], I was confronted to the need of
defining what is an org file (actually, what is an headline, a todo
keyword, a tag, a drawer, a timestamp, etc) and determining what is the
expected output of a parser.

Maybe the most appropriate format for such a description would be free
text, letting parser developers choosing between context-free grammars,
regexps or whatever they want ( with a bunch of example org files for
reference and tests).

Regards,

Olivier

[1] I am just discovering this thread


--bcaec54315d2922be604a81f8552--