include minted in preamble only when minted is defined as listingsmode
This commit is contained in:
parent
6ebf564ee2
commit
c9f0bee905
12
commands.tex
12
commands.tex
@ -40,11 +40,11 @@
|
|||||||
% \newcommand\listingsmode{default} % to use lstlistings
|
% \newcommand\listingsmode{default} % to use lstlistings
|
||||||
% \newcommand\listingsmode{minted} % for a script with exercises only
|
% \newcommand\listingsmode{minted} % for a script with exercises only
|
||||||
% The following lines include that file or make \listingsmode default to 'default' so that any derivatives of this project will work even without the file.
|
% The following lines include that file or make \listingsmode default to 'default' so that any derivatives of this project will work even without the file.
|
||||||
\IfFileExists{listings-mode.tex}{
|
%\IfFileExists{listings-mode.tex}{
|
||||||
\input{listings-mode.tex}
|
% \input{listings-mode.tex}
|
||||||
}{
|
%}{
|
||||||
\newcommand\listingsmode{default}
|
% \newcommand\listingsmode{default}
|
||||||
}
|
%}
|
||||||
|
|
||||||
% Shell command
|
% Shell command
|
||||||
% ==============
|
% ==============
|
||||||
@ -148,7 +148,7 @@
|
|||||||
midrule, bottomrule, cref, setlength, maketitle,
|
midrule, bottomrule, cref, setlength, maketitle,
|
||||||
tableofcontents, foreignlanguage, paragraph, subparagraph,
|
tableofcontents, foreignlanguage, paragraph, subparagraph,
|
||||||
mint, mintinline, inputminted, usemintedstyle, definecolor,
|
mint, mintinline, inputminted, usemintedstyle, definecolor,
|
||||||
citep, enquote%
|
citep, enquote, lstinputlisting%
|
||||||
},
|
},
|
||||||
postbreak=\mbox{{$\hookrightarrow$}\space},
|
postbreak=\mbox{{$\hookrightarrow$}\space},
|
||||||
emphstyle={\color{ForestGreen}\bfseries},
|
emphstyle={\color{ForestGreen}\bfseries},
|
||||||
|
|||||||
14
setup.tex
Normal file
14
setup.tex
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
% Listings mode
|
||||||
|
% =============
|
||||||
|
% The listings mode can be chosen by writing one of the following to the
|
||||||
|
%listings-mode.tex file before compilation:
|
||||||
|
% \newcommand\listingsmode{default} % to use lstlistings
|
||||||
|
% \newcommand\listingsmode{minted} % for a script with exercises only
|
||||||
|
% The following lines include that file or make \listingsmode default to
|
||||||
|
%'default' so that any derivatives of this project will work even without the
|
||||||
|
%file.
|
||||||
|
\IfFileExists{listings-mode.tex}{
|
||||||
|
\input{listings-mode.tex}
|
||||||
|
}{
|
||||||
|
\newcommand\listingsmode{default}
|
||||||
|
}
|
||||||
Loading…
x
Reference in New Issue
Block a user