From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/67522 Path: news.gmane.org!not-for-mail From: Aditya Mahajan Newsgroups: gmane.comp.tex.context Subject: Re: wikimedia2context: any existing solutions? Date: Wed, 30 Mar 2011 13:38:59 -0400 (EDT) Message-ID: References: <20110330151629.GA18420@khaled-laptop> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1301506761 8434 80.91.229.12 (30 Mar 2011 17:39:21 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 30 Mar 2011 17:39:21 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Wed Mar 30 19:39:16 2011 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Q4zMS-0004RT-0H for gctc-ntg-context-518@m.gmane.org; Wed, 30 Mar 2011 19:39:16 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 96845CAB72; Wed, 30 Mar 2011 19:38:50 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id Gb8eMuq52Aqh; Wed, 30 Mar 2011 19:38:47 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 15312CAB54; Wed, 30 Mar 2011 19:38:47 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 1BA05CAB54 for ; Wed, 30 Mar 2011 19:38:45 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id epvn35+AgVuG for ; Wed, 30 Mar 2011 19:38:43 +0200 (CEST) Original-Received: from filter3-til.mf.surf.net (filter3-til.mf.surf.net [194.171.167.219]) by balder.ntg.nl (Postfix) with ESMTP id 1A2F7CAB4C for ; Wed, 30 Mar 2011 19:38:43 +0200 (CEST) Original-Received: from tombraider.mr.itd.umich.edu (smtp.mail.umich.edu [141.211.12.86]) by filter3-til.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id p2UHd5AM024639 for ; Wed, 30 Mar 2011 19:39:07 +0200 Original-Received: FROM adi-netbook (bas3-montreal02-1096682363.dsl.bell.ca [65.94.11.123]) By tombraider.mr.itd.umich.edu ID 4D936AB8.5982C.7004 ; Authuser adityam; 30 Mar 2011 13:39:04 EDT In-Reply-To: User-Agent: Alpine 2.01 (LNX 1266 2009-07-14) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=141.211.12.86; country=US; region=MI; city=Ann Arbor; postalcode=48109; latitude=42.2923; longitude=-83.7145; metrocode=505; areacode=734; http://maps.google.com/maps?q=42.2923,-83.7145&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 0eEptD6LU - ce6690eaeeab - 20110330 X-Scanned-By: CanIt (www . roaringpenguin . com) on 194.171.167.219 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:67522 Archived-At: On Wed, 30 Mar 2011, Mojca Miklavec wrote: > On Wed, Mar 30, 2011 at 17:16, Khaled Hosny wrote: >> On Wed, Mar 30, 2011 at 04:47:07PM +0200, Mojca Miklavec wrote: >> >> If you are comfortable with writing PEG grammar (I'm not), writing a >> mediawiki parser for luanamark[1] might be a good choice, it has a >> ConTeXt writer already (and markdown parser). > > This seems like a very reasonable solution, however it will take too > long before I understand LPEG enough to write some useful code. > >> I pet pandoc have mediawiki support as well, so you may try it. > > I started installing it, but then realized that it only supports > output to mediawiki, no input. > > It seems like writing my own parser (a few regular expressions in > language that is not lua) will probably be the fastest solution after > all. Why not work with html output instead? It is easier to convert html to context (either using built in xml parser or pandoc) Aditya ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________