From 9f76497d4db00169445ed5c35720b655bdc6f2c7 Mon Sep 17 00:00:00 2001 From: Guillaume Astier Ruiz Date: Tue, 16 Apr 2024 22:58:44 +0200 Subject: [PATCH] udpate Prez --- .env | 2 ++ DOCKER/Dockerfile | 1 - DOCKER/run_conversion.sh | 6 ++++++ run.sh | 1 + 4 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 .env diff --git a/.env b/.env new file mode 100644 index 0000000..3247105 --- /dev/null +++ b/.env @@ -0,0 +1,2 @@ +UID=1000 +GID=1000 diff --git a/DOCKER/Dockerfile b/DOCKER/Dockerfile index 51a2a74..6fe009a 100644 --- a/DOCKER/Dockerfile +++ b/DOCKER/Dockerfile @@ -12,7 +12,6 @@ RUN wget https://github.com/jgm/pandoc/releases/download/3.1.13/pandoc-3.1.13-1- RUN dpkg -i /tmp/pandoc.deb RUN apt install texlive-lang-french -y -RUN echo coucou. COPY pandoc-fonts.tar /tmp/ RUN tar xf /tmp/pandoc-fonts.tar -C /usr/share/fonts/ RUN fc-cache -v -f diff --git a/DOCKER/run_conversion.sh b/DOCKER/run_conversion.sh index 8c2dd8f..0c8ea72 100755 --- a/DOCKER/run_conversion.sh +++ b/DOCKER/run_conversion.sh @@ -21,6 +21,12 @@ for File in $(find . -name "*.md") cat ./${InFile} >> ./${InFile}.better pandoc --from markdown --pdf-engine=xelatex --template "${ThemePDFNameCours}" --toc-depth 2 --listings --toc -o ../OUT/${OutFile} ./${InFile}.better &> /dev/null [[ $? -eq 0 ]] && echo OK || echo FAILED + echo -n "$Title Prez : " + sed -i 's/^titlepage:.*//g' ./${InFile}.better + pandoc -s -i -t beamer --pdf-engine=xelatex --toc --template "${ThemePDFNameCours}" -o ../OUT/prez_${OutFile} --slide-level 2 -V classoption:aspectratio=1610 --toc ./${InFile}.better &> /dev/null + + [[ $? -eq 0 ]] && echo OK || echo FAILED + done echo -n "Clean environement : " diff --git a/run.sh b/run.sh index 161b96f..153cbf1 100755 --- a/run.sh +++ b/run.sh @@ -4,6 +4,7 @@ if [[ $1 == "gen" ]] then echo "it's Gonna Take a Little Bit Longer .... " echo -e "UID=$(id -u)\nGID=$(id -g)" > .env + cd $(dirname $0)/DOCKER/ #docker build . --no-cache -t pandoc-gen-file-isen &> /dev/null docker build . -t pandoc-gen-file-isen [[ "$?" -ne 0 ]] && echo FAILED || echo OK