Hugo supports several different Content Formats. Supported content formats include Goldmark, AsciiDoc and HTML. Each format contains a set of pre-defined markup identifiers as noted in the docs. Markup identifiers establish which formatter will be used given the file extension of a piece of content. For example, given a content file with the ad
extension, Hugo will attempt to shell out to asciidoctor
.
In my current use case I am attempting to process historical file archives predating AsciiDoc and containing filenames such as toxicnet.ad
. Given the file extension of ad
Hugo attempts to process the textfile using asciidoctor
which is undesirable and, in my case, causes the Hugo build to abend. Given these are historical files being processed modifying them to work around the Hugo behavior is out of the question.
Attempts to create a media type with ad
extension in order to override the AsciiDoc markup identifier were unfruitful. Given these observations the current design of content formats also seems to prohibit which suffixes may be used on new custom media types, leading Hugo to be less flexible.
Is there a way to override predefined content format markup identifiers or disable content formats so the historic files mentioned may be processed as plain text or processed in a custom way as suggested for .txt
files last month?