[Tex/LaTex] Listings: Correct syntax highlighting for bash // Use minted package with a box

bashlinuxlistingsmintedsyntax highlighting

Since I can't use the listings packet to display my bash script (because of the wrong syntax highlighting by using i.e. language=bash) I have to use the minted package. So I have two questions:

Does anyone know, if it's possible to correctly syntax highlight a bash script with listings (with \lstdefinelanguage{bash}{...} or something like this)?

This is how it looks like with

\begin{minipage}{\textwidth}
\lstset{language=bash,caption={some text above},label=remote_command_execution}
\lstinputlisting[language=bash]{myscript.sh}
\end{minipage}

enter image description here

=> wrong syntax highlighting

I know, that its possible with the minted package. But first: I don't like the font (it's some curlicue font which doesn't look that good for showing some program code) and second: I don't now how to put my code into a "box". With "a box" I mean this here:
enter image description here

So the best solution for me would be a correct syntax highlighting for my bash script with listings. Otherwise minted with a better font and "a box".

Best Answer

This is my solution, for anyone else:

\usemintedstyle{name}

is the answer. You can change the style of your minted code with this. Examples can be found here: https://help.farbox.com/pygments.html

Related Question