From a3cd74c29be02dde0d65e0dcf79bccc8d41952ed Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Thu, 10 Oct 2019 10:00:45 -0700 Subject: `--metadata-file`: when multiple files specified, second takes precedence... on conflicting fields. This changes earlier behavior (but not in a release), where first took precedence. Note that this may seem inconsistent with the behavior of multiple YAML blocks within a document, where the first takes precedence. Still, it is convenient to be able to override defaults with options later on the command line. --- src/Text/Pandoc/App/CommandLineOptions.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Text/Pandoc/App') diff --git a/src/Text/Pandoc/App/CommandLineOptions.hs b/src/Text/Pandoc/App/CommandLineOptions.hs index f9f825a44..a7b20a6e3 100644 --- a/src/Text/Pandoc/App/CommandLineOptions.hs +++ b/src/Text/Pandoc/App/CommandLineOptions.hs @@ -209,7 +209,7 @@ options = , Option "" ["metadata-file"] (ReqArg (\arg opt -> return opt{ optMetadataFile = - (optMetadataFile opt) <> [normalizePath arg] }) + normalizePath arg : optMetadataFile opt }) "FILE") "" -- cgit v1.2.3