ctargett / refguide-asciidoc-poc

Proof of concept of Solr Ref Guide converted to asciidoc format & using Asciidoctor for publishing
2 stars 4 forks source link

post process "`foo`" to improve conversion #17

Closed hossman closed 7 years ago

hossman commented 7 years ago

In asciidoctor, this syntax means "put smart quotes around this string"...

"`put smart quotes around this string`"

But in the refguide, there are lots of places where we people put quotes around inline code snippets so it looks like this in the HTML export..

"<code>keyword</code>" ...

...which is getting converted into this by pandoc...

"`keyword`"

A quick grep shows 201 instances of "Double quote followed by backtick" in our current adoc converted files, and a quick glance it seems like the majority of them are ment to be quoted inline code (in a few places we have the reverse situation: inline code that ends with a quote)

So i'm going to add a bit of post processing to try and clean up the majority of these ... i'm going to err on the side of caution though and not try to fix anything which whitespace between the double quotes, because:

... means that users should set `useDocValuesAsStored="false"` to prevent future optimizations from using the column-stored values over the row-stored values when fields have both `stored="true"` and `docValues="true"`.