From: Andrea R. <and...@in...> - 2009-04-09 17:47:05
|
On Thu, Apr 09, 2009 at 02:18:35AM -0700, panyasan wrote: > Andrea, thank you. My problem is that I would need a binary that I > can configure with command-line options. I don't know Haskell, so I > cannot write it myself. Maybe this would be a useful addition to > your library that would not need much documentation? Something that > can be compiled on each platform and then called like > > citeproc-hs --style apa.cls --infile myreferences.txt --bibdata mybibdb.bib --format bibtex --outfile bibliography.html --format html > > or something like this? The command line parameters would not need > to change at all even when you refactor your code. Writing something like this would be trivial, except for the fact that the html format is not supported yet (due for 0.3 and needed for the test suite). citeproc-hs is a library: writing C bindings should be easy (BTW there are pandoc C bindings, so...:-). Which means that writing a PHP extension that calls citeproc-hs directly should be easy too (even though I'm not sure I'd be able to do it). Easier then writing a PHP implementation from scratch I think (I've never read the code of the implementation there were rumors about, even thought I'd have loved to). The API is going to change a bit in the next few weeks - needed by the most recent additions to CSL -, but I would like to have a more stable API along with CSL 1.0, so I would expect something like what you would like to see could be feasible by the end of the summer, reasonably. Andrea |