Skip to content
This repository has been archived by the owner on May 10, 2024. It is now read-only.

Commit

Permalink
docs: clone DS report for ASW
Browse files Browse the repository at this point in the history
  • Loading branch information
tassiluca committed Jan 29, 2024
1 parent d11a72c commit 50badd0
Show file tree
Hide file tree
Showing 83 changed files with 123,308 additions and 0 deletions.
96 changes: 96 additions & 0 deletions docs/report-asw/code-listings.sty
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
\usepackage{listings}
\usepackage{xcolor}

%-----------------------------------------------------
% LISTING CONFIGURATIONS
%-----------------------------------------------------

\lstset{
showstringspaces=false,
basicstyle=\ttfamily\footnotesize,
commentstyle={\color{olive}},
identifierstyle=\color{black},
ndkeywordstyle={\color{blue}},
stringstyle={\color{magenta}},
emphstyle={},
keywordstyle={\color{blue}},
breaklines=true,
numbers=left,
numberstyle=\tiny\color{gray},
numbersep=10pt,
tabsize=2,
extendedchars=true,
frame=trBL,
frameround=fttt,
escapeinside={(*@}{@*)},
}

\lstdefinelanguage{Kotlin}{
comment=[l]{//},
emph={delegate, filter, filterIsInstance, flatMap, toSet, firstOrNull, forEach, lazy, map, mapNotNull, println, return@, sequence, yield, Array, Byte, Double, Float, Int, Iterable, Long, Runnable, Short, String},
keywords={operator, infix, init, abstract, actual, as, as?, break, by, class, companion, continue, data, do, dynamic, else, enum, expect, false, final, for, fun, get, if, import, in, interface, internal, is, null, object, override, package, private, public, return, set, super, suspend, this, throw, true, try, typealias, val, var, vararg, when, where, while, it},
morecomment=[s]{/*}{*/},
morestring=[b]",
morestring=[s]{"""*}{*"""},
ndkeywords={@Deprecated, @JvmField, @JvmName, @JvmOverloads, @JvmStatic, @JvmSynthetic},
sensitive=true,
}

\lstdefinelanguage{JavaScript}{
keywords={typeof, new, true, false, catch, function, return, null, catch, switch, var, if, in, while, do, else, case, break, let, const},
ndkeywords={class, export, boolean, throw, implements, import, this},
sensitive=false,
comment=[l]{//},
morecomment=[s]{/*}{*/},
morestring=[b]',
morestring=[b]",
emph={Companion},
}

\lstdefinelanguage{json}{
numbers=left,
numberstyle=\small,
frame=single,
rulecolor=\color{black},
showspaces=false,
showtabs=false,
breaklines=true,
postbreak=\raisebox{0ex}[0ex][0ex]{\ensuremath{\color{gray}\hookrightarrow\space}},
breakatwhitespace=true,
upquote=true,
morestring=[b]",
stringstyle=\color{blue},
}

\lstdefinelanguage{yaml} {
keywords={true,false,null,y,n},
sensitive=false,
comment=[l]{\#},
morecomment=[s]{/*}{*/},
stringstyle=\color{blue}\mdseries\ttfamily,
moredelim=[l][\color{orange}]{\&},
moredelim=[l][\color{magenta}]{*},
morestring=[b]',
morestring=[b]",
moredelim=**[il][\color{magenta}\mdseries{:}\color{blue}\mdseries]{:},
literate={>}{{\textcolor{magenta}\textgreater}}1
{|}{{\textcolor{magenta}\textbar}}1
{\ -\ }{{\mdseries\ -\ }}3,
}

\newcommand{\prolog}[1]{\lstinline[style=Prolog-cool,basicstyle=\ttfamily\normalsize]{#1}}
\newcommand{\kotlin}[1]{\lstinline[language=Kotlin,basicstyle=\ttfamily\normalsize]{#1}}
\newcommand{\python}[1]{\lstinline[language=Python,basicstyle=\ttfamily\normalsize]{#1}}

\newcommand{\py}[1]{\texttt{#1}}
\newcommand{\pl}[1]{\texttt{#1}}
\newcommand{\kt}[1]{\texttt{#1}}
\newcommand{\pli}[1]{\pl{\textit{#1}}}

\newcommand{\prologimport}[2][{}]{\lstinputlisting[#1,style=Prolog-cool]{#2}}
\newcommand{\javaimport}[2][{}]{\lstinputlisting[#1,language=Java]{#2}}
\newcommand{\jsimport}[2][{}]{\lstinputlisting[#1,language=JavaScript]{#2}}
\newcommand{\kotlinimport}[2][{}]{\lstinputlisting[#1,language=Kotlin]{#2}}
\newcommand{\pythonimport}[2][{}]{\lstinputlisting[#1,language=Python]{#2}}
\newcommand{\jsonimport}[2][{}]{\lstinputlisting[#1,language=json]{#2}}
\newcommand{\yamlimport}[2][{}]{\lstinputlisting[#1,language=yaml]{#2}}
Loading

0 comments on commit 50badd0

Please sign in to comment.