sirthias / pegdown

A pure-Java Markdown processor based on a parboiled PEG parser supporting a number of extensions
http://pegdown.org
Apache License 2.0
1.29k stars 217 forks source link

Support Confluence wiki style links: [text|url] #112

Closed kminder closed 11 years ago

kminder commented 11 years ago

For example [Groovy|http://groovy.codehaus.org] Optionally of course based on Extensions flags.

jirutka commented 11 years ago

Markdown has [Groovy](http://groovy.codehaus.org) syntax for links. It’s clear and quite intuitive. Why do you want to mess Markdown syntax with redundant elements from some other syntaxes, that doesn’t bring any new semantic? It you don’t like Markdown syntax for links and prefer some other, why not to use the other syntax?

However, if you want this syntax, then you can write a Pegdown plugin for it. It’s actually quite simple.

sirthias commented 11 years ago

I'd agree with @jirutka in that I see little value in adding a second non-markdown style link syntax.

kminder commented 11 years ago

Let me provide context that I should have included initially. I'm copying a large number of documents out of cwiki and into Markdown. My intention was that this would be a convenience to limit the amount of changes I'd need to make. I understand that this is a bit of a corner case but I thought it might be useful in this context. I've made a bunch of suggestions based on this work and I hope to contribute some plugins for them when time allows. Thanks for the great tool!