mirror of
https://github.com/velocitatem/PHANTOM.git
synced 2026-05-31 16:43:36 +00:00
proper parsing without highlights
This commit is contained in:
@@ -15,26 +15,9 @@ add_file() {
|
|||||||
local filepath="$1"
|
local filepath="$1"
|
||||||
local relpath="${filepath#$PROJECT_ROOT/}"
|
local relpath="${filepath#$PROJECT_ROOT/}"
|
||||||
|
|
||||||
# Get file extension
|
# Add section header and code listing (no language-specific highlighting)
|
||||||
local ext="${filepath##*.}"
|
|
||||||
|
|
||||||
# Map extensions to listings language
|
|
||||||
case "$ext" in
|
|
||||||
py) lang="Python" ;;
|
|
||||||
js|jsx|ts|tsx) lang="JavaScript" ;;
|
|
||||||
sh) lang="bash" ;;
|
|
||||||
yml|yaml) lang="Python" ;;
|
|
||||||
Dockerfile) lang="bash" ;;
|
|
||||||
*) lang="" ;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
# Add section header and code listing
|
|
||||||
echo "\\subsection{${relpath}}" >> "$OUTPUT_FILE"
|
echo "\\subsection{${relpath}}" >> "$OUTPUT_FILE"
|
||||||
if [ -n "$lang" ]; then
|
echo "\\begin{lstlisting}[caption={${relpath}}]" >> "$OUTPUT_FILE"
|
||||||
echo "\\begin{lstlisting}[language=${lang},caption={${relpath}}]" >> "$OUTPUT_FILE"
|
|
||||||
else
|
|
||||||
echo "\\begin{lstlisting}[caption={${relpath}}]" >> "$OUTPUT_FILE"
|
|
||||||
fi
|
|
||||||
cat "$filepath" >> "$OUTPUT_FILE"
|
cat "$filepath" >> "$OUTPUT_FILE"
|
||||||
echo "" >> "$OUTPUT_FILE"
|
echo "" >> "$OUTPUT_FILE"
|
||||||
echo "\\end{lstlisting}" >> "$OUTPUT_FILE"
|
echo "\\end{lstlisting}" >> "$OUTPUT_FILE"
|
||||||
|
|||||||
@@ -38,6 +38,8 @@ The primary objective of this thesis is to develop and validate pricing heuristi
|
|||||||
|
|
||||||
\printbibliography
|
\printbibliography
|
||||||
|
|
||||||
|
\clearpage
|
||||||
|
\onecolumn
|
||||||
\appendix
|
\appendix
|
||||||
\input{../build/concatenated_code}
|
\input{../build/concatenated_code}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user