diff options
Diffstat (limited to 'Main.hs')
-rw-r--r-- | Main.hs | 38 |
1 files changed, 20 insertions, 18 deletions
@@ -373,24 +373,26 @@ defaultWriterName :: FilePath -> String defaultWriterName "-" = "html" -- no output file defaultWriterName x = case takeExtension (map toLower x) of - "" -> "markdown" -- empty extension - "tex" -> "latex" - "latex" -> "latex" - "ltx" -> "latex" - "context" -> "context" - "ctx" -> "context" - "rtf" -> "rtf" - "rst" -> "rst" - "s5" -> "s5" - "native" -> "native" - "txt" -> "markdown" - "text" -> "markdown" - "md" -> "markdown" - "markdown" -> "markdown" - "db" -> "docbook" - "xml" -> "docbook" - "sgml" -> "docbook" - [x] | x `elem` ['1'..'9'] -> "man" + "" -> "markdown" -- empty extension + ".tex" -> "latex" + ".latex" -> "latex" + ".ltx" -> "latex" + ".context" -> "context" + ".ctx" -> "context" + ".rtf" -> "rtf" + ".rst" -> "rst" + ".s5" -> "s5" + ".native" -> "native" + ".txt" -> "markdown" + ".text" -> "markdown" + ".md" -> "markdown" + ".markdown" -> "markdown" + ".texi" -> "texinfo" + ".texinfo" -> "texinfo" + ".db" -> "docbook" + ".xml" -> "docbook" + ".sgml" -> "docbook" + ['.',x] | x `elem` ['1'..'9'] -> "man" _ -> "html" main = do |