0

This code doesn't compile:

\documentclass{article}
\usepackage{minted}
\begin{document}
\newminted[mycode]{text}{framesep=6pt,framerule=1pt}
\begin{mycode}[highlightlines={1}]
Hello,
world!
\end{mycode}
\end{document}

What's wrong with it? I want to have an ability to specific additional configuration for my own minted environment.

1

After \newminted you need to use the * form and a mandatory keyval argument, not an optional one:

enter image description here

\documentclass{article}
\usepackage{minted}
\begin{document}
\newminted[mycode]{text}{framesep=6pt,framerule=1pt}
\begin{mycode*}{highlightlines={1}}
Hello,
world!
\end{mycode*}
\end{document}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.