04
Aug
2017
7:50 AM

Emacs and Markdown

If you are into markdown and prefer just a simple editor like emacs to write .md files, then you might find the emacs markdown mode to be useful. There is a nice write up about how to install it and use the quick keys at Jason Blevin's site.

After installation, you can of course some of the wonderful built in features in emacs to do certain short cuts. For example, inserting a link would just require you to C-c C-a l , which will create the shortcuts to create a html link. If you would like to have a referenced link, well use C-c C-a L. But one that I really use often is C-c C-a f which is a reference footnotes1. Not as good as having citation using bibtex, but its better than nothing.

Adding an image is also as easy as C-c C-i i. you can use capital I for reference images.

The styling can also be easy here by using the commands

C-c C-s e #emphasize
C-c C-s b #block-quote
C-c C-s s #strong bold
C-c C-s c #inline code
C-c C-t h #current heading continue
C-c C-t H #current heading continue but underlined
C-c C-t 1 #first heading

And finally, to get a preview, just run C-c C-c p. This will open your browser. Of course for this to work, you need to install markdown first. apt-get install markdown on debian.

So hope this helps your documentation work somehow. Have fun markdowning.


  1. Reference to some article