From 544494d0e234e899a45f02b185cf5a448787f786 Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Sat, 9 Dec 2017 14:09:00 -0800 Subject: Man writer: omit internal links. That is, just print the link text without the url. Closes #4136. --- src/Text/Pandoc/Writers/Man.hs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Text/Pandoc/Writers/Man.hs b/src/Text/Pandoc/Writers/Man.hs index ad3de41eb..34b5c0ece 100644 --- a/src/Text/Pandoc/Writers/Man.hs +++ b/src/Text/Pandoc/Writers/Man.hs @@ -373,6 +373,8 @@ inlineToMan _ LineBreak = return $ cr <> text ".PD 0" $$ text ".P" $$ text ".PD" <> cr inlineToMan _ SoftBreak = return space inlineToMan _ Space = return space +inlineToMan opts (Link _ txt ('#':_, _)) = + inlineListToMan opts txt -- skip internal links inlineToMan opts (Link _ txt (src, _)) = do linktext <- inlineListToMan opts txt let srcSuffix = fromMaybe src (stripPrefix "mailto:" src) -- cgit v1.2.3