git.iko.soy/typeable/pandoc
on master help sign in
Org writer: Fix output for linebreaks
3606669Albert Krewinkel
src/Text/Pandoc/Writers/Org.hs+1−1
@@ -271,7 +271,7 @@ inlineToOrg (Math t str) = do
271 else "$$" <> text str <> "$$"
271 else "$$" <> text str <> "$$"
272inlineToOrg (RawInline f str) | f == "tex" || f == "latex" = return $ text str
272inlineToOrg (RawInline f str) | f == "tex" || f == "latex" = return $ text str
273inlineToOrg (RawInline _ _) = return empty
273inlineToOrg (RawInline _ _) = return empty
274−inlineToOrg (LineBreak) = return cr -- there's no line break in Org
274+inlineToOrg (LineBreak) = return (text "\\\\" <> cr)
275inlineToOrg Space = return space
275inlineToOrg Space = return space
276inlineToOrg (Link txt (src, _)) = do
276inlineToOrg (Link txt (src, _)) = do
277 case txt of
277 case txt of
tests/writer.org+1−1
@@ -42,7 +42,7 @@ item.
42
42
43Here's one with a bullet. * criminey.
43Here's one with a bullet. * criminey.
44
44
45−There should be a hard line break
45+There should be a hard line break\\
46here.
46here.
47
47
48--------------
48--------------