tomalexander / orgmode-mediawiki Goto Github PK
View Code? Open in Web Editor NEWA mediawiki export for Emacs org-mode
A mediawiki export for Emacs org-mode
Hi,
I've just installed this package from MELPA. I am trying to export a simple Org file. This is its content:
#+STARTUP: showall
#+TITLE: prova media wiki
* prova
** ciao
Whether I pick "To temporary buffer" (M
) or "To file" (m
), I always get this error: http://pastebin.com/kTbkUpd8
I didn't see a mechanism to create xwiki style links, but figured other folks might find themselves looking for them as I was. This advice will make the export output xwiki links.
(defun xwiki-link-syntax (orig-fun &rest args)
"Turns [link text] into [[text>>link]] to satisfy xwiki link formatting"
(let ((res (apply orig-fun args)))
(save-match-data
(if (string-match "\\[\\(.*\\) \\(.*\\)\\]" res)
(let ((link (match-string 1 res))
(text (match-string 2 res)))
(format "[[%s>>%s]]" text link))
res))))
(advice-add 'org-mw-link :around #'xwiki-link-syntax)
Eager macro-expansion failure: (wrong-number-of-arguments #[(old new) "\302\303� E\304�\305 FE\207" [old new progn defalias put (quote byte-obsolete-variable)] 6] 3)
Problems while trying to load export back-end `html'
Eager macro-expansion failure: (wrong-number-of-arguments #[(old new) "\302\303� E\304�\305 FE\207" [old new progn defalias put (quote byte-obsolete-variable)] 6] 3)
define-obsolete-variable-alias: Wrong number of arguments: #[(old new) "ÂÃ� EÄ�Å FE�" [old new progn defalias put (quote byte-obsolete-variable)] 6], 3
Just to let you know, i'm in the process of proposing the recipe of orgmode-mediawiki.
https://github.com/ardumont/melpa/blob/add-recipe-ox-mediawiki/recipes/ox-mediawiki
Melpa is just another simpler way of packaging (the maintainer has little to do but follow the package conventions).
This is related to #8.
Also, there is already a recipe for el-get https://github.com/dimitri/el-get/blob/master/recipes/orgmode-mediawiki.rcp
Cheers,
I am using an org-mode underscore markup element as in e.g. _word_
. AFAICS, Mediawiki does not have its own markup for that, but uses HTML tags.
Are org-mode _underlines_
supposed to work? If not, feature is obviously low priority, but will leave open for comments. Close anytime.
I use this mode and its good - so why is it not part of org-mode or in the marmelade repo?
I'm trying to use org-mode to export org documents to mediawiki for the gentoo wiki. It uses "templates" for various code blocks, for example
{{Cmd|echo "a command"}}
{{RootCmd|echo "a root command"}}
This ends up looking like this.
My question is: Can I already achieve this using orgmode-mediawiki? Or is extending it to add support for these templates required. If it does require extending, how should I go about doing it? I'm an org noob, so this may be not possible, but I was thinking something like this:
#+begin_src bash :template "Cmd"
echo "this is a command"
#+end_src
Output:
{{Cmd|echo "This is a command"}}
Is this possible? Any pointers or tips?
Is subtree export supposed to work? I get the following error on a very simple subtree:
Initializing asynchronous export process
save-current-buffer: Wrong type argument: stringp, (lambda (p status) (let ((proc-buffer (process-buffer p))) (when (eq (process-status p) (quote exit)) (unwind-protect (if (zerop (process-exit-status p)) (unwind-protect (let ((results (with-current-buffer proc-buffer ... ... ...))) (funcall (lambda (output) (with-current-buffer ... ... ... ... ... ... ...)) results)) (unless org-export-async-debug (and (get-buffer proc-buffer) (kill-buffer proc-buffer)))) (org-export-add-to-stack proc-buffer nil p) (ding) (message "Process '%s' exited abnormally" p)) (unless org-export-async-debug (delete-file "/var/folders/03/g441ctw52xjgcv3mhhw3053h0000gn/T/org-export-process2711hlu"))))))
Process 'org-export-process' exited abnormally
if subtree export is supposed to work, please give me a hint on where to look next.
Great tool! Just what I was looking for. However, I do need footnotes to work. I see that it looks like this is work that has not been done yet:
(footnote-definition . ignore)
(footnote-reference . ignore)
Is this work planned at all? I know a bit of lisp and would not mind trying my hand at adding this functionality as I have free time, which is not a lot. Have you done any research here, any pointers, gotchas or stuff like that?
Thanks again.
I really like the idea of your function and it could be really useful for me to export directly from org to wiki, but I cant seem to get it working. I am able to run the two functions:
`org-mw-export-as-mediawiki' but get the error:
org-export-execute-babel-code: Symbol's function definition is void: org-babel-exp-process-buffer
`org-mw-export-to-mediawiki' and get the error:
org-export-output-file-name: Symbol's function definition is void: org-file-equal-p
Do you know what might cause this problem? Any help is much appreciated.
Johan
org-export-output-file-name: Symbol's function definition is void: org-file-equal-p
An org file containing the following:
=test=
or
~test~
Causes org-mw-export-to-mediawiki
and org-mw-export-as-mediawiki
to fail with the message org-mw-verbatim: Wrong type argument: stringp, nil
.
As referenced in #9, list items currently export with new lines in between them which makes each list a new list rather than all part of a single list.
I'm not sure how to fix that just yet. Do you have an idea?
I will say that ox-md
does export them in one list block.
org-babel-exp processing... [17 times]
org-trim: Wrong type argument: stringp, nil
org-babel-exp processing... [17 times]
org-trim: Wrong type argument: stringp, nil
exporting to text and html work fine
In the call to org-export-define-derived-backend
the menu entry uses ?m
which conflicts with the built-in ox-md (markdown exporter, added in org-mode 8.0.1).
If both ox-md and ox-mediawiki backends are enabled, ox-mediawiki clobbers the C-c C-e m
binding.
Perhaps you can use ?M
?
Org:
- a :: b
- c :: d
MediaWiki output:
* b
* d
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.