Configure LaTeX Editing and Support for Multiple Languages in VSCode [for MaxOS]
2025-05-12
The process is divided into two steps: one is to install MaxTex, and the other is to configure LaTex Workshop in VSCode.
Use Brew to install MacTeX in the terminal
You can use the command brew install mactex
Then open the folder: /usr/local/texlive/2025, there is a pkg file below, just install the pkg file. The file is relatively large, and the entire installation process takes about 10-30 minutes.
Here is the detailed tutorial: https://www.tug.org/mactex/mactex-download.html
After installation is complete, usexelatex --version
and pdflatex --version
to test if the environment variable is configured correctly. If an error is displayed, simply add the following content to .zshrc:
#Latex
export PATH="/Library/TeX/texbin:$PATH"
Configuring LaTeX in VS Code
Install the LaTeX Workshop extension in VScode
Test the LaTex environment
If you want to support Chinese or other languages, just add the corresponding encoding, for example:
\documentclass{article}
\usepackage[UTF8]{ctex}
\usepackage{amsmath}
\begin{document}