Closed Matthew0x closed 1 year ago
Have you tried the development version on GitHub? (That is, download the latest minted.sty
and put that in the same location as your document.) The upcoming release reimplements escapeinside
handling and will likely fix whatever issues you are having.
Also, if you get things working for some languages but not others (maybe Python works but not bash): escapeinside
can be fragile in a language-dependent way based on how it is implemented in Pygments, so in some cases some things can only be accomplished by customizing the Python implementation of the Pygments lexer. Here's the bash implementation: https://github.com/pygments/pygments/blob/master/pygments/lexers/shell.py.
Have you tried the development version on GitHub? (That is, download the latest
minted.sty
and put that in the same location as your document.) The upcoming release reimplementsescapeinside
handling and will likely fix whatever issues you are having.
That's nice to hear!
I like the library very much and will be happy to try out the newer version. Your second answer actually seems correct! I tried out Bash and Dockerfile prior to posting, but now I have tried the Terraform parser and it seems to bring different results.
Although, pretty ugly, but at least working.
\begin{terraform}
var.<variable-name>.<key-name>
1 |\textbf{or}| 2
var.<variable-name>["key-name"]
\end{terraform}
PS: There is a lexer called literally "text", which fits my need and works properly with the escape flag.
I have looked into other issue reports on this minted option and I fail to understand why the following happens:
So this is a minted environment inside a tcbox. There is a macro that puts the environment inside my tcbox, right?
This is a sample environment, which is based off bash, because I couldn't find a "no-code" type of template to base it on.
Am I missing something or is this a bug?... Adding the escapeinside option to the pre-defined environment doesn't compile to me. I guess it's designed to accept that option directly from the template only. I tried it out with texcomments=false to no difference.
Now, look at this. I turned off my macro, so we can talk about the newminted template only, right?