perhaps you misunderstand my problem. I do not need to
extract the vqwiki topics from a database, I can simply process them
directly, since they already reside on disk (I use file-based
persistence). My translation program could add some
functionality to extract topic source from the database.
Using sql functions like replace to translate wiki source into a
different wiki syntax is an interesting approach, but I think the
problem is a bit harder than that.
At 12:37 PM +0200 7/21/10, Johan Lindell wrote:
Hi again Russ,
Well, if you were able to switch to a
database (like mysql or ms sql server) you would be able
the actual text in the topics rather than the html presentation of the
texts on each page/topic and
- Use sql
functions like replace to change the wiki syntax.
Depending on the amount of information it
could be worthwhile to explore this alternative.
From: Russ Tremain
Sent: Tuesday, July 20, 2010 7:57 PM
To: Marcello Teodori
Cc: Johan Lindell;
Subject: Re: [veryquickwiki-users] convert vqwiki to
I'm not sure how exporting from the
database helps me, since the issue is translation from vqwiki syntax
to mediawiki syntax in source documents, and I don't even use a
Since my post, I have tried a few things,
and made some progress.
First, I tried to use a perl-based
html-to-wiki translator (found here):
html2wiki --dialect MediaWiki topic_file ...
This failed miserably even for simple
If you think about it, it seems like a
much harder problem to convert html-ified wiki content, verses just
translating the original wiki source form. Ultimately, I decided
to take the latter approach, and have written a translator to do the
job. The translator takes this approach:
I. tokenize the original
vqwiki sources to a generalized intermediate form (some have used XML
for this; I did not)
II. define mediawiki macros to
translate the intermediate form to a different syntax.
As an simple example, here is the
intermediate form for a Topic:
So if I define:
VQ_TOPIC_LQ = [[
VQ_TOPIC_RQ = ]]
then I can output mediaWiki syntax
(actually vqwiki already allows this input syntax, along with
back-tick quotes, but you get the idea.)
Obviously the full problem is deeper than
this, but I believe I have solved most of it. I will post the
sources somewhere after I do some more testing.
Step II. could theoretically be any
arbitrary wiki syntax, though at the present time I am only interested
As an aside, I also had the idea of
switching vqwiki to use mediawiki input syntax, by
However, it doesn't seem to do much. Either I'm not doing it
right, or the work was never finished on this lexer. I followed
the instructions here.
I think this is a better long term
approach for the community, since it would allow vqwiki as an
alternative to JAM and/or the full MediaWiki behemoth. In my
case, the only goal is to force myself to start using media-wiki
syntax. There are serveral things I like about vqwiki over other
wiki's, like the fact that I don't have to use a database for a small
installation on my laptop. Keeping the topics in the filesystem
makes it very easy to move around and to backup.
At 5:42 PM +0100 7/20/10, Marcello
Hi, thanks for this useful info, it's something that
should be added to the documentation as a FAQ entry or somewhere
I've been thinking a lot about adding a sort of driver
concept support to the Export2HTML feature to allow exporting to
different file formats, mostly with the Creole format in mind to avoid
vqwiki syntax lock-in and also allow changing the syntax at a future
On 16/lug/2010, at 14.15, Johan Lindell wrote:
If you switch to database mode you can retrieve the
contents from the Topic table. If you set up database persistence you
can import the wiki-pages/files to the database and the retrieve them
Med Vänliga Hälsningar
+46 73 600 27 93
216 19 MALMÖ
From: Russ Tremain
Sent: Monday, July 12, 2010 6:47 PM
Subject: [veryquickwiki-users] convert vqwiki to
I've written a lot of content in vqwiki, but unfortunately
my current employer uses media wiki for mark-up.
Any hints on the easiest way to convert content from
vqwiki to mediawiki?
I'm currently using vqwiki 2.8.1.
Possibly I can go the Export2HTML route, but that seems
P.S. here is a useful post, which summarized a
bunch of conversion tools last year. Seems like Atlassian has
the most mature tool, but it is to convert everything to Confluence
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first_______________________________________________
veryquickwiki-users mailing list