mixedmath

Explorations in math and programming
David Lowry-Duda



Every year, TeX Live updates in a breaking way. This year it was on 13 March 2024.

I don't notice until I need to do something somewhat uncommon with my TeX distribution, such as compiling a new template or style file. Today, I'm writing a funding proposal and was (re)compiling a similar proposal I wrote a couple of years ago. It happens to use the extdash package, which I don't have installed. But trying to install it now (via tlmgr) throws an error saying that my distribution is 2023, and now it's 2024, so it's time to upgrade.

LaTeX distributions come in two forms: the main binaries and packages. Packages are updated continually and can be updated throughout the year. The main binaries are updated once each year. But once a binary is updated, the package manager (associated to a previous binary) will no longer allow package updates.

The effect is that a new texlive installation is required each year. There are some update scripts, but these are unsupported and still essentially require downloading as much material as a full install.

I haven't heard a compelling reason why this behavior is tolerated (let alone desirable). Further, following instructions typically leads with several side-by-side installations of tex (although each installation is HUGE and this is also unacceptable).

The only benefit of this is that keeping older versions allows snapshot recompilation of older documents, or snapshot recompilation using packages with backwards incompatible updates (such as moderncv, which breaks all the time). But I don't like having that bloat, so I end up completely removing old versions and installing a fresh texlive each year.

I sometimes want bleeding-edge latex things and don't use my linux distribution's package manager for this. Instead, I do it myself through the texlive package manager tlmgr. These are my notes on updating texlive from year to year.

(In particular, these are the steps that I went through just now so that I can compile what I really wanted to compile).

Remove the previous installation

I keep the texlive source in $HOME/src/texlive.1 1You can probably guess where I keep source files for other things that I build and manage myself). Looking now, I see that I have 598832 bytes of stuff there, meaning that the complete size of my texlive distribution for all latex that I've compiled in the last year is approximately 585MB. This is about 1/10th the size of the standard TeXLive Full installation on Ubuntu, which is one of the reasons why I prefer to manage the installation myself.2 2I began to use tlmgr to manage texlive when I was using a chromebook as my main driver, and I needed to be able to fit texlive on my tiny harddrive. I learned a lot about resource constraints then.

I note for interest that 261MB of my texlive is dedicated to documentation for installed packages. Another 96MB is for fonts.

Regardless, I remove the entirety of my $HOME/src/texlive at once.

Acquire and run the new installer

Go to tug.org and download the texlive internet installer. This year, this is a 5.5MB file install-tl-unx.tar.gz .

Move it to a freshly created $HOME/src/texlive and unpack it.

cd into the new directory and run the installer (which is a little perl script).

I now customize many of the options. For people who read this that aren't me, I emphasize that my usecase might not be the same as your usecase. Now is an obvious time to deviate from my procedure.

  1. Verify that it detects the correct platform, GNU/Linux on x86_64 for me.
  2. Change the installation scheme from scheme-full (which takes 8.253GB this year) to custom .
  3. Go into the Collections submenu. I default to having too little and then install things later with tlmgr as necessary later. Thus I first deselect all, and then I install exactly three collections: Essential programs and files, LaTeX fundamental packages, and XeTeX and packages.
  4. Set the installation directories. I use $HOME/src/texlive and I do not separate by year. I also set TEXMFHOME to ~/.texmf (i.e. I change it to be a hidden file instead of polluting my home directory visibly).
  5. I set tex to use letter size instead of A4 by default, because I live in the US. I note that I keep the "install font/macro doc tree" option, which downloads documentation and which ultimately doubles the size of my installation. I actually read the documentation sometimes. I think this is unusual.
  6. Set the installation to proceed.

This year, this apparently uses 557MB of disk space.

This led to texlive installing 181 packages (and their commented source and documentation) and took less than 10 minutes.

Afterwards, the installer will display a very important message about setting MANPATH, INFOPATH, and PATH. In principle I would alter these in my .bashrc, but in practice my previous .bashrc points to these new spots since I'm overwriting where my texlive installation directory.

Remove texlive installer

TeXLive is now installed, so I can remove $HOME/src/texlive/. The exact name is different, depending on the date.

Install utility packages

I use various utilities frequently. I install these with

which tlmgr  # to make sure that new tlmgr is detected
tlmgr install latexmk lacheck chktex latexdiff pdfcrop \
              pdfjam texdiff texdoc

These are utility packages that are less common. I use lacheck and chktex for latex linting. I use texdoc to see documentation for packages. I use latexmk to handle recompilation. I use the others for various scripts I've written. All of these are tiny.

Installation took 31 seconds.

Install specific packages I use

I have four fundamental types of papers that I often compile.

I have different templates and packages that I use for each of these. I know that I'll make all four again this year and I know exactly which packages they need. I install those now.

tlmgr install setspace mathtools booktabs wrapfig changebar \
              xcolor lipsum tocloft fancyvrb enumitem threeparttable \
              beamer beamertheme-metropolis adjustbox pgfopts \
              xkeyval collectbox times minted ragged2e multirow

I made this list a couple of years ago by checking what was necessary to compile a couple specific documents.

I install any other package as necessary throughout the year. Right now, my installation uses 706MB.3 3Wow, that's 150 MB more than my entire distribution last year, including various packages installed throughout the year for ad hoc reasons! I wonder what changed so much. I see that 334MB, which is 73MB more than before.


Leave a comment

Info on how to comment

To make a comment, please send an email using the button below. Your email address won't be shared (unless you include it in the body of your comment). If you don't want your real name to be used next to your comment, please specify the name you would like to use. If you want your name to link to a particular url, include that as well.

bold, italics, and plain text are allowed in comments. A reasonable subset of markdown is supported, including lists, links, and fenced code blocks. In addition, math can be formatted using $(inline math)$ or $$(your display equation)$$.

Please use plaintext email when commenting. See Plaintext Email and Comments on this site for more. Note also that comments are expected to be open, considerate, and respectful.

Comment via email

Comments (1)
  1. 2024-04-15 DLD

    I experiment with mirroring some commentary from Mastodon and here. This is from @davidlowryduda@mathstodon.

    Once a year, sometime shortly after March, I try to update something with tlmgr (the texlive manager) and it flails about. It tells me that I'm silly for not noticing that TeXLive has advanced another year, and that I should get with the times and update too.

    Then I spend 30 minutes updating my texlive.

    And then afterwards I can install the random latex package I needed.

    Today is that day for me. And the package was extdash.

    I do essentially the same steps every year. This year I put these steps in a public place.