diff options
author | Albert Krewinkel <tarleb@moltkeplatz.de> | 2014-04-05 09:09:44 +0200 |
---|---|---|
committer | Albert Krewinkel <tarleb@moltkeplatz.de> | 2014-04-05 16:15:50 +0200 |
commit | d76d2b707b2b5cebb38122e117527a70996c2c4f (patch) | |
tree | 2bccfd6a7e4d62f37c6d0a8c9ba28d01b12a608e /src/Text/Pandoc/Readers | |
parent | fd98532784e43ad73072f37a31af5ff40fdc1c56 (diff) | |
download | pandoc-d76d2b707b2b5cebb38122e117527a70996c2c4f.tar.gz |
Org reader: Provide more language identifier translations
Org-mode and Pandoc use different language identifiers, marking source
code as being written in a certain programming language. This adds more
translations from identifiers as used in Org to identifiers used in
Pandoc.
The full list of identifiers used in Org and Pandoc is available through
http://orgmode.org/manual/Languages.html and `pandoc -v`, respectively.
Diffstat (limited to 'src/Text/Pandoc/Readers')
-rw-r--r-- | src/Text/Pandoc/Readers/Org.hs | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Readers/Org.hs b/src/Text/Pandoc/Readers/Org.hs index ad66caab9..62088a04d 100644 --- a/src/Text/Pandoc/Readers/Org.hs +++ b/src/Text/Pandoc/Readers/Org.hs @@ -153,7 +153,14 @@ indentWith num = do , try (char '\t' >> count (num - tabStop) (char ' ')) ] translateLang :: String -> String -translateLang "sh" = "bash" +translateLang "C" = "c" +translateLang "C++" = "cpp" +translateLang "emacs-lisp" = "commonlisp" -- emacs lisp is not supported +translateLang "js" = "javascript" +translateLang "lisp" = "commonlisp" +translateLang "R" = "r" +translateLang "sh" = "bash" +translateLang "sqlite" = "sql" translateLang cs = cs commaEscaped :: String -> String |