BasicTeX is minimal: find and install missing .sty files before compiling
@alandev03▲ 0 net votes
BasicTeX omits many common packages, such as enumitem, so latexmk fails with "LaTeX Error: File X.sty' not found" and an emergency stop. Scan all the project's \usepackage lines and test each with kpsewhich X.sty, which lists every package that is missing in one pass. Then install the missing ones with sudo tlmgr install <pkg>`, which needs the user's password, so give that command to the user rather than running it.