diff --git a/.github/texlive/texlive.profile b/.github/texlive/texlive.profile deleted file mode 100644 index ef71dd96..00000000 --- a/.github/texlive/texlive.profile +++ /dev/null @@ -1,10 +0,0 @@ -selected_scheme scheme-basic -TEXDIR /tmp/texlive -TEXMFCONFIG ~/.texlive/texmf-config -TEXMFHOME ~/texmf -TEXMFLOCAL /tmp/texlive/texmf-local -TEXMFSYSCONFIG /tmp/texlive/texmf-config -TEXMFSYSVAR /tmp/texlive/texmf-var -TEXMFVAR ~/.texlive/texmf-var -option_doc 0 -option_src 0 diff --git a/.github/texlive/texlive_install.sh b/.github/texlive/texlive_install.sh deleted file mode 100755 index 2a2d6df1..00000000 --- a/.github/texlive/texlive_install.sh +++ /dev/null @@ -1,34 +0,0 @@ -#!/usr/bin/env sh - -# Originally from https://github.com/latex3/latex3/blob/master/support/texlive.sh -texlive_root=./.github/texlive -texlive_profile="${texlive_root}/texlive.profile" - -export PATH=/tmp/texlive/bin/x86_64-linux:$PATH -if ! command -v pdflatex > /dev/null; then - echo "Texlive not installed" - echo "Downloading texlive and installing" - wget http://mirror.ctan.org/systems/texlive/tlnet/install-tl-unx.tar.gz - tar -xzf install-tl-unx.tar.gz - # Install a minimal system - if [ ! -r "$texlive_profile" ]; then - echo "error: $texlive_profile" - exit 1 - fi - ./install-tl-*/install-tl --profile="$texlive_profile" - echo "Finished installing TexLive" - fi - -echo "Updating TexLive" -# Keep no backups (not required, simply makes cache bigger) -tlmgr option -- autobackup 0 -echo "Updating tlmgr itself" -tlmgr update --self - -echo "Install ${texlive_root}/texlive_packages" -tlmgr install $(sed 's/\s*#.*//;/^\s*$/d' ${texlive_root}/texlive_packages) - -echo "Update the TL install but add nothing new" -tlmgr update --self --all --no-auto-install - -echo "Finished texlive_install.sh" diff --git a/.github/texlive/texlive_packages b/.github/texlive_packages similarity index 62% rename from .github/texlive/texlive_packages rename to .github/texlive_packages index 5a860f67..772df5df 100644 --- a/.github/texlive/texlive_packages +++ b/.github/texlive_packages @@ -4,7 +4,7 @@ # Base tools to compile # texliveonfly -latexmk +# latexmk # Collections # collection-langeuropean @@ -12,51 +12,53 @@ collection-fontsrecommended # Assuming a 'basic' font set up, metafont is required to avoid # warnings with some packages and errors with others -metafont mfware +# metafont mfware # texliveonfly does not detect the following packages automatically -amsfonts -amsmath +# amsfonts +# amsmath +babel-english biber biblatex -bigintcalc -bitset +# bigintcalc +# bitset bookmark caption csquotes enumitem -epstopdf-pkg -etexcmds -fancyvrb +# epstopdf-pkg +# etexcmds +fancyhdr +# fancyvrb fandol -framed +# framed fvextra -gettitlestring -graphics -hycolor +# gettitlestring +# graphics +# hycolor hypdoc -hyperref +# hyperref hyphenat -infwarerr -intcalc -kvdefinekeys -kvoptions -kvsetkeys -letltxmacro +# infwarerr +# intcalc +# kvdefinekeys +# kvoptions +# kvsetkeys +# letltxmacro lineno listings -ltxcmds +# ltxcmds minted oberdiek -pdfescape -pdftexcmds -psnfss +# pdfescape +# pdftexcmds +# pnfss ragged2e -refcount -rerunfilecheck -tools -uniquecounter +# refcount +# rerunfilecheck +# tools +# uniquecounter upquote -xcolor -xkeyval +# xcolor +# xkeyval xstring diff --git a/.github/workflows/test-and-deploy.yml b/.github/workflows/test-and-deploy.yml index e4ecdeef..d6193317 100644 --- a/.github/workflows/test-and-deploy.yml +++ b/.github/workflows/test-and-deploy.yml @@ -2,15 +2,9 @@ name: CI on: push: - branches: - - "main" - - "master" paths-ignore: ['README.md','bibpool/**','**precommit','setup_worktree.sh','mklog','**.latexmkrc','.gitignore'] pull_request: - branches: - - "main" - - "master" paths-ignore: ['README.md','bibpool/**','**precommit','setup_worktree.sh','mklog','**.latexmkrc','.gitignore'] env: @@ -58,14 +52,14 @@ jobs: fi echo "FILES_CHANGED=${#FILES_CHANGED}" >> $GITHUB_ENV # get the char len of diff output (used later) - - name: Cache TeX Live + - name: Cache TinyTeX if: ${{ env.FILES_CHANGED != 0 }} - id: cache-texlive + id: cache-tinytex uses: actions/cache@v3 with: - path: /tmp/texlive - key: ${{ env.cache-version }}-${{ runner.os }}-texlive-essential - restore-keys: ${{ env.cache-version }}-${{ runner.os }}-texlive-essential + path: ~/.TinyTeX + key: ${{ env.cache-version }}-${{ runner.os }}-tinytex + restore-keys: ${{ env.cache-version }}-${{ runner.os }}-tinytex - name: Install packages if: ${{ env.FILES_CHANGED != 0 }} @@ -73,10 +67,25 @@ jobs: sudo apt -y update sudo apt -y install bibtex2html tidy ghostscript qpdf - - name: Install Tex Live - if: ${{ env.FILES_CHANGED != 0 && steps.cache-texlive.outputs.cache-hit != 'true'}} - run: .github/texlive/texlive_install.sh - + - uses: r-lib/actions/setup-tinytex@v2-branch + if: ${{ env.FILES_CHANGED != 0 && steps.cache-tinytex.outputs.cache-hit != 'true'}} + env: + TINYTEX_INSTALLER: TinyTeX-1 + TINYTEX_VERSION: 2023.09 + + - name: Install additional LaTeX packages + if: ${{ env.FILES_CHANGED != 0 && steps.cache-tinytex.outputs.cache-hit != 'true'}} + run: | + texlive_packages=./.github/texlive_packages + echo "Updating TexLive" + # Keep no backups (not required, simply makes cache bigger) + tlmgr option -- autobackup 0 + echo "Updating tlmgr itself" + tlmgr update --self + echo "Install ${texlive_packages}" + tlmgr install $(sed 's/\s*#.*//;/^\s*$/d' "${texlive_packages}") + tlmgr path add + - name: Run test if: ${{ success() && env.FILES_CHANGED != 0 }} run: cd test && ./test.sh