On 2013-09-27, Dave Cottlehuber wrote:
> [-- Type: text/plain, Encoding: --]
> Hi,
> I've got a bunch of code-blocks like so:
> .. code-block:: javascript
> {
> "couchdb": "Welcome",
> "uuid": "85fb71bf700c17267fef77535820e371",
> "vendor": {
> "name": "The Apache Software Foundation",
> "version": "1.5.0"
> },
> "version": "1.5.0"
> }
> and I would like to use |version| and other global substitutions within
> here, which obviously doesn't work directly.
> Is there any way around this behaviour, such as some escaping?
You may try the "parsed-literal" directive that typesets the content
in a fixed width font preserving whitespace but parses for inline markup.
http://docutils.sourceforge.net/docs/ref/rst/directives.html#parsed-literal-block
AFAIK, Sphinx can also apply syntax highlight to "parsed-literal" blocks
just like it does for "literal" (i.e. blocks following ``::``).
Günter
--
You received this message because you are subscribed to the Google Groups
"sphinx-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sphinx-users.
For more options, visit https://groups.google.com/groups/opt_out.