I'm rebuilding my blog at http://www.elmalabarista.com/blog/. I have use in my previous version markdown and now I remember why I have almost zero code samples. Doing code samples in markdown is very fragile.
I try to put some python there I can't make markdown mark it as code!. The main culprit? The syntax is markdown for code is out spaces. Despite the fact I use wmd as the editor (how that work here in SO is a mistery for me), it never be able to move rigth the text so never get as code. this is the problem:
I put something simple:
:::python
def hello():
pass
But the problem is that something I have:
:::python def hello(): pass
or
:::python def hello(): pass
(yes bot was formatted but you see? not work). Any mistake -using tabs, too much, too litle spaces) is punished heavily. And if the code is long, the chance of a problem increase too.
So, exist any way to simply do:
### My article
- My list entry one
- My list entry two
:::python def x (a, b): return a * b
and get converted rigth and never bother about this small thing again???
By the way, I'm using pygments & python markdown.