redhat-documentation / asciidoc-markup-conventions

How to use AsciiDoc mark-up to properly style elements in Red Hat documentation
https://access.redhat.com/documentation/
17 stars 16 forks source link

Add supported syntax highlighting formats #12

Open rkratky opened 6 years ago

rkratky commented 6 years ago

The 'code block' element should link to a list of supported languages.

bergerhoffer commented 6 years ago

We need to make sure that the languages we list are supported by ccutil/the portal. Early on, we attempted to use some languages that weren't supported on the portal (at least back then).

The languages we successfully use on EAP are java, xml, sql, javascript, bash, and html. I'm sure there are plenty of others supported - we may want to check w/ the tooling team.

Also note that we had decided on EAP to not use "bash" (or any language) when showing terminal commands. This is because we prefix the command with "$", but if it is a root command, we use "#". With "#" and bash highlighting, it will get incorrectly highlighted as a comment. Maybe there is a better option that we were just unaware of though.

LightGuard commented 6 years ago

Asciidoctor supports highlight.js. I'm not sure what the portal supports, but would honestly be surprised if they couldn't support highlight.js.