MacTeX is a fully featured TeX distribution for Mac, incorporating various GUI applications, Ghostscript and the current version of TeX Live. Versions are released on an annual basis.

The GUI applications use the Sparkle update mechanism, and in some cases, this can be managed via Configuration Profile. However, the core TeX distribution included in the package is provided by TeX Live, which uses its own update utility. Fortunately, this incorporates a CLI that can be leveraged to script and automate this process.

tlmgr can be used to manage an existing TeX Live installation. It supports many (many) options, and I recommend reviewing the documentation if you're interested in this. However, in order to simply keep the bundled packages and configuration files up to date, this command is sufficient:

/Library/TeX/texbin/tlmgr update --self --all --no-require-verification

Options for running this include:

  • As a Munki postinstall_script
  • As a boot or login job via Outset
  • As a boot, login or scheduled job via launchd

An example of running this via launchd is:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "">
<plist version="1.0">

This will effectively run the job on boot. You could alternatively use StartInterval or StartCalendarInterval to more closely control the schedule of this job. This .plist, and a script to build a package from it, is available on GitHub here.