How can I write letters like ř, í, á to listings?
Why is zero in the name of the section?
\documentclass[12pt,a4paper]{report}
\usepackage[total={7in, 9in}]{geometry}
\usepackage{enumitem}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[czech]{babel}
\usepackage{tikz}
\usetikzlibrary{calc}
\usepackage{framed}
\usepackage{xcolor}
\usepackage{listings}
\usepackage{xcolor,colortbl}
\usepackage[most]{tcolorbox}
\newtcbinputlisting[auto counter,list inside=lol,list type={lstlisting}]{\mylisting}[3][]{%
listing file={#3},
title=Listing,
colback=white,
colframe=gray!75!black,
fonttitle=\bfseries,
listing only,
breakable,
listing options={basicstyle=\scriptsize\ttfamily,
commentstyle=\color{purple},
},
title={Script \thetcbcounter: #2},
#1
}
\newcommand{\listingsfont}{basicstyle=\ttfamily}
\begin{document}
\section{Why is here 0}
\lstset{morecomment=[l]{#}}
\mylisting{Code}{script.txt}
\end{document}
The file with the script:
script.txt
#hello
í ů ř á
hello
