DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:markdowku

This is an old revision of the document!


markdowku Plugin

Compatible with DokuWiki

Adora Belle, Weatherwax, Binky, Ponder Stibbons

plugin Integrates Markdown into DokuWiki syntax

Last updated on
2014-04-21
Provides
Syntax
Repository
Source

This extension has not been updated in over 2 years. It may no longer be maintained or supported and may have compatibility issues.

Similar to commonmark, creole, markdown, markdownextra, mdpage, mediasyntax

Tagged with formatting, markup_language

Installation

Install the plugin using the Plugin Manager and the download URL above, which points to latest version of the plugin. Refer to Plugins on how to install plugins manually.

Examples/Usage

This plugin will go before the overlapping DokuWiki syntax definitions and overrule them with Markdown specifications.

For patterns that are not part of Markdown, you can still use DokuWiki, e.g. you're still able to use DokuWiki tables.

Syntax

This plugins tries to resemble Markdown as closely as possible and does not extend it. It is a best-effort implementation - I didn't try to match the Markdown test suite, but rather provide a look-alike handler for Markdown syntax, as Markdown itself is somewhat underspecified.

You'll find the basic description on the website of the Markdown author, as well as a deeper description of the syntax.

If you encounter any incompatibilities in this version, feel free to add them here or report them.

Known incompatibilities

Due to the inner working of Markdown and DokuWiki, there are things which currently cannot be done with this plugin. I am working on getting this fixed. If you want to help, feel free to contact me (gnrp) in IRC.

All in all, this plugin is complete. Just when it comes to nesting things, i.e. putting things into each other, this plugin doesn't handle lists and blockquotes well.

This should be a complete list of current general incompatibilities. Everything else is a bug:

  • nested in blockquotes:
    • codeblocks
    • paragraph handling
    • lists
    • multiline reflinks/refimages
  • nested in lists:
    • codeblocks
    • quotes
    • multiline reflinks/refimages
    • ATX headers
    • Setext headers
    • horizontal rulers
  • codespans with more than five backticks (most probably never used)
  • using underscores to make text bold. Double underline is already used by DokuWiki for underlining text (Markdown can't do that), and I think it's better to have the option for underlining. In general notation, you also rather use underscores for underlining than making text bold.

Development

Change Log

You can find the whole release history on the plugin website.

Last update: 2014-04-21: Relese a new version. Making shortcut reference links and images work.

Bugs/Issues

There is a bug tracker online. Please note you have to log in anonymous (go to Login page, click “Fill out captcha”) before you can commit bugs. Also, you can write me an e-mail and I will enter the bug to the bug tracker.

ToDo/Wish List

This plugin is not complete yet. Incompatibilities are listed above at Known incompatibilities.

In the end, I want to extend this plugin to be able to handle different markdown flavours (esp. Github), with a switch in the configuration to choose between those all.

A switch like <no_markdown> will allow to avoid problems with existing native markup pages. (jseto) – I'll see what is possible, but I think it will be difficult to implement that. (gnrp 13-09-23)

The plugin editor does not work together with markdown. Either have the possibility to disable it, or even better, make it work with Markdown (Celano 13-08-08, reformatted by gnrp 13-09-23)

The plugin seem useful as we write in markdown but eventually need to use some DokuWiki syntax. I have to say that the wiki display markdown files created elsewhere by peoples using markdown editor and they doesn’t want to change to a new syntax. The idea is they work as they used to in markdown tools, and eventually had some DokuWiki synthax for some site related features and needs. I have three problems that prevent us to use the plugin which I hope could be improved.

  • Html doesn’t work but html is correct markdown and really useful for things markdown can’t do. Even the <html></html> tags of DokuWiki doesn’t work either. I have allowed html in config options but the plugin just seems to ruin the page when it enconter any <tag>. FIXME
  • Second problem is that we use a lot the footnote syntax of markdown extra (a footnote syntax [^1] which become near a standard in markdown tools) https://michelf.ca/projects/php-markdown/extra/#footnotes. This addition would be very nice.
  • Reference-style links from classic markdown doesn’t works. http://daringfireball.net/projects/markdown/syntax#link

(dinobib 25-05-15)

FAQ

There are already two Markdown plugins, why do you write a third one?

The prior two plugins (markdown, markdownextra) work completely different. The other two just create a large container (either defined by <markdown> tags or a .md file ending) and parse everything inside them as Markdown.

This plugin adds Markdown to the DokuWiki syntax, i.e. it still uses DokuWiki definitions for lists, headers, etc. Thus, markdowku enables you to use internal links, mix Markdown with other plugins and other syntaxes and have clean section headers and media embedding.

Discussion

Be great to use .md extension instead of .txt

If it used .md, I might be able to keep it synced with my .md files in dropbox.

Download fails due to untrusted certificate

Download of this plugin from https://komkon2.de/markdowku/markdowku.tgz failed for me with complaints about the certificate for komkon2.de:

$ wget https://komkon2.de/markdowku/markdowku.tgz
--2014-07-08 22:13:41--  https://komkon2.de/markdowku/markdowku.tgz
Resolving komkon2.de (komkon2.de)... 217.197.80.221, 2001:bf0:c000:a::2:221
Connecting to komkon2.de (komkon2.de)|217.197.80.221|:443... connected.
ERROR: The certificate of ‘komkon2.de’ is not trusted.
ERROR: The certificate of ‘komkon2.de’ hasn't got a known issuer.

I was able to download and install the file via the http protocol, though (http://komkon2.de/markdowku/markdowku.tgz). — KaiMartin 2014-07-08 22:22

gnrp: I cannot reproduce that. The certificate chain should be valid. Using

openssl s_client -connect komkon2.de:443

to connect to the webserver, I get

Certificate chain
 0 s:/description=6FtUsThnEF5bvNo0/C=DE/CN=www.komkon2.de/emailAddress=postmaster@komkon2.de
   i:/C=IL/O=StartCom Ltd./OU=Secure Digital Certificate Signing/CN=StartCom Class 1 Primary Intermediate Server CA
 1 s:/C=IL/O=StartCom Ltd./OU=Secure Digital Certificate Signing/CN=StartCom Class 1 Primary Intermediate Server CA
   i:/C=IL/O=StartCom Ltd./OU=Secure Digital Certificate Signing/CN=StartCom Certification Authority
 2 s:/C=IL/O=StartCom Ltd./OU=Secure Digital Certificate Signing/CN=StartCom Certification Authority
   i:/C=IL/O=StartCom Ltd./OU=Secure Digital Certificate Signing/CN=StartCom Certification Authority

It is just the usual free StartSSL certificate. Don't you have them anymore? — gnrp 2014-09-04 15:56

plugin/markdowku.1441904712.txt.gz · Last modified: 2015-09-10 19:05 by Aleksandr

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki