Re: [O] mlorg : yet another parser for org-mode (Written in OCaml contained in org-mode files)

2012-03-01 Thread Nicolas Goaziou
Hello,

Simon Castellan simon.castel...@iuwt.fr writes:

 Thank you very much for this pointer, This is what I was looking for :
 a list of syntaxic construction in org-mode. I'd say though that it
 lacks a more-or-less formal syntaxic definition of constructions.

It lacks that, indeed, among many other things. On the other hand, it's
a work in progress, so I guess that explains why.

I had postponed such a definition of constructions, since the model used
to describe the Org format wasn't (and still isn't) complete. Actually,
the list that you can observe in org-element.el will change a little
during the next few weeks.

Anyway, I agree that a document formally describing each element/object
in Org has to be written at some point. Even if I think it's one or two
months too early for that task, I'll gladly offer my help if you decide
to undertake it nonetheless. Do not hesitate to ask if you need more
information.


Regards,

-- 
Nicolas Goaziou



Re: [O] mlorg : yet another parser for org-mode (Written in OCaml contained in org-mode files)

2012-03-01 Thread Simon Castellan
Hello,

Thanks for your answer. I think indeed that a description of org's syntax would
be better in a separate document. For now I am rebasing my parser on your
categories (I must say I was lacking a lot). Please let me know when you change
your syntaxic categories (by change you mean additions only or removals as well
?). I will try in my sources to document meanings and (very) informal syntax of
handled constructions.

Besides, what are export snippets ? I can't find a reference to it in the 
manual.

Simon



Re: [O] mlorg : yet another parser for org-mode (Written in OCaml contained in org-mode files)

2012-03-01 Thread Nicolas Goaziou
Simon Castellan simon.castel...@iuwt.fr writes:

 For now I am rebasing my parser on your categories (I must say I was
 lacking a lot). Please let me know when you change your syntaxic
 categories (by change you mean additions only or removals as well ?).

I have a couple additions in mind: I'd like to refine table parsing.
I'll probably add table-row and table-cell elements. I'd like to
introduce a new type of drawers too, but that's another story.

There's no removal in sight, though.

I'll keep you informed on changes in that area.

 I will try in my sources to document meanings and (very) informal
 syntax of handled constructions.

This could be a starter for the complete document to come.

 Besides, what are export snippets ? I can't find a reference to it
 in the manual.

They're an experimental syntax I introduced to replace and generalize
HTML tags (@tag). They are, more or less, the inline counterpart of
export blocks. For example, one should be able to use @html{tag}, but
also @latex{\hfill{}}, etc. and back-ends filter out all but one
category.


Regards,

-- 
Nicolas Goaziou



Re: [O] mlorg : yet another parser for org-mode (Written in OCaml contained in org-mode files)

2012-02-28 Thread Simon Castellan
On lun. 27/févr. (09:52), Eric Schulte wrote:
 Simon Castellan simon.castel...@iuwt.fr writes:
 
  On lun. 27/févr. (15:27), Alan Schmitt wrote:
  On 26 févr. 2012, at 17:41, Simon Castellan wrote:
  
   I have been writing a parser for mlorg files in OCaml. This started as an
   experiment to see if the literate programming mode of org-mode could 
   scale to a
   full application (among other things).
  
  This looks very interesting, and would very much help in the
  dissemination of org-mode. Have you thought of announcing it on the
  caml mailing list?
  
  Alan
 
  I have but prefer to wait mlorg to be more complete. This post was meant 
  mainly
  to gather info/document about org's syntax. (But as I said feedbacks 
  welcome.)
 
 
 Hi Simon,
 
 Nicolas Goaziou has been working recently on a new emacs-lisp parser of
 Org-mode files, with the goals of
 1. standardizing the formal syntax of Org-mode files
 2. parsing Org-mode files to a canonical emacs-lisp list-based
representation in memory (like an Org-mode AST)
 3. re-basing the existing Org-mode exporters off of this canonical
representation
 
 This work is contained in contrib/lisp/org-element.el, which includes a
 large amount of useful commentary at the top of the file.  This should
 serve as a starting point for learning more about the formal syntax of
 Org-mode files (as it is defined).  I think that developing parsers for
 this syntax in multiple language should be very useful to ensure that a
 usable syntax is developed separate from any particular implementation.
 
 Cheers,
 

Thank you very much for this pointer, This is what I was looking for : a list of
syntaxic construction in org-mode. I'd say though that it lacks a more-or-less
formal syntaxic definition of constructions.

Simon.



Re: [O] mlorg : yet another parser for org-mode (Written in OCaml contained in org-mode files)

2012-02-27 Thread Alan Schmitt
On 26 févr. 2012, at 17:41, Simon Castellan wrote:

 I have been writing a parser for mlorg files in OCaml. This started as an
 experiment to see if the literate programming mode of org-mode could scale to 
 a
 full application (among other things).

This looks very interesting, and would very much help in the dissemination of 
org-mode. Have you thought of announcing it on the caml mailing list?

Alan


Re: [O] mlorg : yet another parser for org-mode (Written in OCaml contained in org-mode files)

2012-02-27 Thread Simon Castellan
On lun. 27/févr. (15:27), Alan Schmitt wrote:
 On 26 févr. 2012, at 17:41, Simon Castellan wrote:
 
  I have been writing a parser for mlorg files in OCaml. This started as an
  experiment to see if the literate programming mode of org-mode could scale 
  to a
  full application (among other things).
 
 This looks very interesting, and would very much help in the dissemination of 
 org-mode. Have you thought of announcing it on the caml mailing list?
 
 Alan

I have but prefer to wait mlorg to be more complete. This post was meant mainly
to gather info/document about org's syntax. (But as I said feedbacks welcome.)

Simon.



Re: [O] mlorg : yet another parser for org-mode (Written in OCaml contained in org-mode files)

2012-02-27 Thread Eric Schulte
Simon Castellan simon.castel...@iuwt.fr writes:

 On lun. 27/févr. (15:27), Alan Schmitt wrote:
 On 26 févr. 2012, at 17:41, Simon Castellan wrote:
 
  I have been writing a parser for mlorg files in OCaml. This started as an
  experiment to see if the literate programming mode of org-mode could scale 
  to a
  full application (among other things).
 
 This looks very interesting, and would very much help in the
 dissemination of org-mode. Have you thought of announcing it on the
 caml mailing list?
 
 Alan

 I have but prefer to wait mlorg to be more complete. This post was meant 
 mainly
 to gather info/document about org's syntax. (But as I said feedbacks welcome.)


Hi Simon,

Nicolas Goaziou has been working recently on a new emacs-lisp parser of
Org-mode files, with the goals of
1. standardizing the formal syntax of Org-mode files
2. parsing Org-mode files to a canonical emacs-lisp list-based
   representation in memory (like an Org-mode AST)
3. re-basing the existing Org-mode exporters off of this canonical
   representation

This work is contained in contrib/lisp/org-element.el, which includes a
large amount of useful commentary at the top of the file.  This should
serve as a starting point for learning more about the formal syntax of
Org-mode files (as it is defined).  I think that developing parsers for
this syntax in multiple language should be very useful to ensure that a
usable syntax is developed separate from any particular implementation.

Cheers,


 Simon.


-- 
Eric Schulte
http://cs.unm.edu/~eschulte/