markdown-preview-mode/README.md

45 lines
1.5 KiB
Markdown
Raw Normal View History

2014-09-14 11:18:24 +02:00
Markdown preview mode
2014-09-13 14:19:34 +02:00
===========================
2014-09-14 16:41:52 +02:00
## Description
Opens a preview in a browser, updated upon buffer save.
Same preview window is valid accross multiple mardown buffers.
2014-09-14 11:18:24 +02:00
2014-09-14 16:41:52 +02:00
## Dependencies
2014-09-14 11:18:24 +02:00
2014-09-14 16:41:52 +02:00
* markdown-mode.el
2014-09-14 11:18:24 +02:00
* websocket.el
2014-09-14 16:41:52 +02:00
Makes use of `markdown-mode`, which already can transform markdown into html
and `websocket.el` to deliver html to browser.
2014-09-15 07:30:13 +02:00
## Usage
2014-09-14 16:41:52 +02:00
`M-x markdown-preview-mode` will open preview in a browser and will start `markdown-mode` if it's not yet running for current buffer. If you'v closed the preview window, you can start it over with `M-x markdown-preview-open-browser`. All websockets will be cleaned up on emacs termination. If you'd like to perform cleanup manually run `M-x markdown-preview-cleanup`.
2014-09-14 16:41:52 +02:00
## Multimarkdown
In order to enable multimarkdown support, customize
`M-x customize-option` -> `markdown-command` variable.
Look for `Markdown Command` which is set to `markdown` by default,
set to `multimarkdown` and make sure it's in your PATH.
## Browser
In order to select prefered browser, customize
`M-x customize-option` -> `browse-url-browser-function` option.
Select your browser from `Value menu`. If it's not there, follow [EmacsWiki: Browse Url](http://www.emacswiki.org/emacs/BrowseUrl).
## Theme
2014-09-15 07:30:13 +02:00
[Solarized-dark](http://thomasf.github.io/solarized-css/)
2014-09-15 21:39:14 +02:00
In order to change preview styling, run `M-x customize-option` -> `markdown-preview-style`
and specify your favourite markdonw css URI.
## Websocket port
Adjustable by `M-x customize-option` -> `markdown-preview-port`.
## El-get recipe included