我有一个铸造的区块,如下所示:
\documentclass{article}
\usepackage{minted}
\usepackage{listings}
\begin{document}
\begin{listing}[ht]
\begin{minted}{xml}
<plugin>
<groupId>maven.plugin</groupId>
<artifactId>maven-plugin</artifactId>
<version>1.1.1</version>
<configuration>
<tipo>\${env.TEST}</tipo>
</configuration>
<executions>
<execution>
<phase>xxxx</phase>
<goals>
<goal>xxx</goal>
</goals>
</execution>
</executions>
</plugin>
\end{minted}
\caption{Maven plugin XML code}
\label{pomsinau}
\end{listing}
\end{document}
我正在使用转义栏\
来表示美元符号$
,但乳胶$
在输出中将该符号与转义字符一起显示:
如何删除输出处的转义栏并仅留下符号$
?
答案1
只需使用$
:
\documentclass{article}
\usepackage{minted}
\usepackage{listings}
\begin{document}
\begin{listing}[ht]
\begin{minted}{xml}
<plugin>
<groupId>maven.plugin</groupId>
<artifactId>maven-plugin</artifactId>
<version>1.1.1</version>
<configuration>
<tipo>${env.TEST}</tipo>
</configuration>
<executions>
<execution>
<phase>xxxx</phase>
<goals>
<goal>xxx</goal>
</goals>
</execution>
</executions>
</plugin>
\end{minted}
\caption{Maven plugin XML code}
\label{pomsinau}
\end{listing}
\end{document}