From 01a6b071fa99358a9c4fca68612e9718ef0fca5f Mon Sep 17 00:00:00 2001 From: Albert Krewinkel <albert@zeitkraut.de> Date: Sun, 4 Oct 2020 17:03:42 +0200 Subject: [PATCH] Sort languages in `--list-highlight-languages` output (#6718) Languages appear to be sorted by their long name, which leads to unexpected results: e.g., the long name of *m4* is *GNU m4*, so it is listed between *gnuassembler* and *go*. --- src/Text/Pandoc/App/CommandLineOptions.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Text/Pandoc/App/CommandLineOptions.hs b/src/Text/Pandoc/App/CommandLineOptions.hs index 36b024ba7..cccfa764b 100644 --- a/src/Text/Pandoc/App/CommandLineOptions.hs +++ b/src/Text/Pandoc/App/CommandLineOptions.hs @@ -840,7 +840,7 @@ options = , sShortname s `notElem` [T.pack "Alert", T.pack "Alert_indent"] ] - mapM_ (UTF8.hPutStrLn stdout) langs + mapM_ (UTF8.hPutStrLn stdout) (sort langs) exitSuccess )) ""