1
votes

I need to convert some .xhtml files to regular .html (html5) with pandoc, and during the conversion I would like to embed some metadata (supplied via a YAML file) in the final files.

The conversion runs smoothly, but any attempt to embed the metadata invariably fails.

I tried many variations of this command, but it should be something like:

pandoc -s -H assets/header -c css/style.css -B assets/prefix -A assets/suffix --metadata-file=metadata.yaml input_file -o output_file --to=html5

The error I get is:

pandoc: unrecognized option `--metadata-file=metadata.yaml' Try pandoc --help for more information.

I really don't get what's wrong with this, since I found this option in the pandoc manual

Any ideas?

1

1 Answers

3
votes

Your pandoc version is too old. Update to pandoc 2.3 or later.