Skip to content

Will try using apt to install latexmk again #14

Will try using apt to install latexmk again

Will try using apt to install latexmk again #14

name: Compile and Upload LaTeX Files
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Check out the code
uses: actions/checkout@v2
- name: Install LaTeX packages
run: |

Check failure on line 20 in .github/workflows/compile_tex_files.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/compile_tex_files.yml

Invalid workflow file

You have an error in your yaml syntax on line 20
sudo apt-get update
sudo apt-get install liblz4-dev
sudo apt-get install liblz4-tool
wget http://mirrors.ctan.org/systems/texlive/tlnet/install-tl-unx.tar.gz -O - | tar -x --gzip
mv $(ls | grep install) install-tl
./install-tl/install-tl -profile texlive.profile
export PATH=$(pwd)/texlive/bin/x86_64-linux:$PATH
sudo apt-get install texlive texlive-extra-utils texlive-latex-base texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended texlive-luatex texlive-xetex texlive-pstricks
sudo apt-get install latexmk
tlmgr update --self
tlmgr update --all
tlmgr install $(cat .tlmgr-dep)
- name: Compile LaTeX files
run: |
chmod a+x scripts/build-pdfs.sh
scripts/build-pdfs.sh
- name: Move PDFs to correct location
run: |
for DIR in $(ls -d */ | grep ''); do
mkdir "docs/$DIR"
for PATH_REL_SRC in $(ls "$DIR"*.pdf | grep ''); do
PATH_REL_DEST="docs/$PATH_REL_SRC"
echo "Moving $PATH_REL_SRC to docs/$DIR folder"
mv "$PATH_REL_SRC" "$PATH_REL_DEST"
done
done
- name: Edit webpages to include links for those pdfs
run: |
cd docs
write_section_links() {
DIR_NAME="$1"
OUTPUT_FILENAME="$2"
OUTPUT_SECTION_TITLE="$3"
OUTPUT_LINK_PREFIX="$4"
printf "## $OUTPUT_SECTION_TITLE\n" >> "$OUTPUT_FILENAME"
for FNAME in $(ls "$DIR_NAME" | grep ''); do
NAME="$OUTPUT_LINK_PREFIX""$FNAME"
FPATH="$DIR_NAME/$FNAME"
printf "[$NAME]($FPATH) \n" >> "$OUTPUT_FILENAME" # Two spaces before \n tells Markdown to generate <br />
done
printf "\n" >> "$OUTPUT_FILENAME"
}
write_section_links "class-notes" "class-notes.md" "Class Notes" ""
write_section_links "Monographs" "monographs.md" "Monographs" ""
write_section_links "presentations" "presentations.md" "Presentations" ""
cd ..
- name: Upload compiled PDF files
uses: actions/upload-artifact@v2
with:
name: compiled-pdfs
path: |
|
$(find . -type f -name '*.pdf')