vimwiki

Personal wiki for vim
git clone https://github.com/vimwiki/vimwiki.git
Log | Files | Refs | README | LICENSE

commit be79f68a9292cbe53d330cb37fd18d835e8f74d4
parent c857be2f8742ff812794498e4d371dd74d668340
Author: EinfachToll <istjanichtzufassen@googlemail.com>
Date:   Mon, 30 Jan 2017 20:43:26 +0100

Merge pull request #285 from MichaelThessel/dev

Added config option to allow for newlines in text when exporting to HTML
Diffstat:
Mautoload/vimwiki/html.vim | 6+++++-
Mdoc/vimwiki.txt | 13+++++++++++++
Mplugin/vimwiki.vim | 1+
3 files changed, 19 insertions(+), 1 deletion(-)

diff --git a/autoload/vimwiki/html.vim b/autoload/vimwiki/html.vim @@ -983,7 +983,11 @@ function! s:process_tag_para(line, para) "{{{ let para = 1 endif let processed = 1 - call add(lines, a:line) + if g:vimwiki_text_ignore_newline == 1 + call add(lines, a:line) + else + call add(lines, a:line."<br />") + endif elseif para && a:line =~# '^\s*$' call add(lines, "</p>") let para = 0 diff --git a/doc/vimwiki.txt b/doc/vimwiki.txt @@ -2303,6 +2303,19 @@ Default: 1 ------------------------------------------------------------------------------ +*g:vimwiki_text_ignore_newline* + +This is HTML related. +Convert newlines to <br />s in text. + +Value Description~ +0 Newlines in text are converted to <br />s. +1 Ignore newlines. + +Default: 1 + + +------------------------------------------------------------------------------ *g:vimwiki_use_calendar* Create new or open existing diary wiki-file for the date selected in Calendar. diff --git a/plugin/vimwiki.vim b/plugin/vimwiki.vim @@ -369,6 +369,7 @@ call s:default('ext2syntax', {}) " syntax map keyed on extension call s:default('hl_headers', 0) call s:default('hl_cb_checked', 0) call s:default('list_ignore_newline', 1) +call s:default('text_ignore_newline', 1) call s:default('listsyms', ' .oOX') call s:default('use_calendar', 1) call s:default('table_mappings', 1)