Thursday, April 16, 2026

How to Fix "soul.sty not found" and tlmgr Update Errors in ShareLaTeX/Overleaf

How to Fix "soul.sty not found" and tlmgr Update Errors in ShareLaTeX Docker

If you are encountering the error LaTeX Error: File 'soul.sty' not found while using a ShareLaTeX Docker container, the standard fix is to install the full TeX Live scheme. However, an outdated manager often prevents this.

Follow these steps to upgrade tlmgr and fix your compilation errors.

1. Access the Docker Container

Open your terminal and enter the ShareLaTeX container bash shell:

docker exec -it sharelatex bash

2. Navigate to the TeX Live Directory

Switch to the local TeX Live installation directory:

cd /usr/local/texlive

3. Force an Upgrade of the Manager

To bypass version mismatch errors, download the latest update script and run it with the upgrade flag (as recommended by TUG):

sh update-tlmgr-latest.sh -- --upgrade

4. Install scheme-full

Now that the manager is updated, you can install the full scheme to ensure all .sty files are present:

tlmgr install scheme-full

Why this works: Running the --upgrade flag manually updates the TeX Live manager's core files, allowing it to connect to modern repositories that contain the soul package and other dependencies.

No comments: