Vscode搭配latex简易教程

1. 找镜像网站下载texlive的iso文件

清华源镜像

下载之后直接打开iso文件,打开install-tl-windows.bat文件,进行安装即可,安装大概30分钟左右

2. VScode端配置

2.1 下载这三个插件

2.2 打开设置

2.3 追加内容到配置json文件当中

json 复制代码
  // Latex configuration
  "latex-workshop.latex.recipes": [
    {
      "name": "xe->bib->xe->xe",
      "tools": [
        "xelatex",
        "bibtex",
        "xelatex",
        "xelatex"
      ]
    }
  ],
  "latex-workshop.latex.tools": [
    {
      // 编译工具和命令
      "name": "xelatex",
      "command": "xelatex",
      "args": [
        "-synctex=1",
        "-interaction=nonstopmode",
        "-file-line-error",
        // "-pdf",
        "%DOCFILE%"
      ]
    },
    {
      "name": "pdflatex",
      "command": "pdflatex",
      "args": [
        "-synctex=1",
        "-interaction=nonstopmode",
        "-file-line-error",
        "%DOCFILE%"
      ]
    },
    {
      "name": "bibtex",
      "command": "bibtex",
      "args": [
        "%DOCFILE%"
      ]
    }
  ],
  "latex-workshop.view.pdf.viewer": "tab",
  "latex-workshop.latex.clean.fileTypes": [
    "*.aux",
    "*.bbl",
    "*.blg",
    "*.idx",
    "*.ind",
    "*.lof",
    "*.lot",
    "*.out",
    "*.toc",
    "*.acn",
    "*.acr",
    "*.alg",
    "*.glg",
    "*.glo",
    "*.gls",
    "*.ist",
    "*.fls",
    "*.log",
    "*.fdb_latexmk"
  ]

2.4 重启VScode即可

右上角书本加一个放大镜的标识就是查看编译好的pdf文件

相关推荐
bulucc2 分钟前
vim 快捷操作
linux·编辑器·vim
Aspect of twilight2 小时前
vscode python debug方式
ide·vscode·python·debug
Aevget2 小时前
.NET跨平台开发工具Rider v2025.3发布——支持.NET 10
ide·.net·开发工具·rider·rider v2025.3
啃火龙果的兔子4 小时前
vscode中可以使用的免费的AI编程工具有哪些
ide·vscode·ai编程
littlezls4 小时前
在VSCode中运行Python脚本文件时如何传参
vscode·python
宋明炜5 小时前
VSCode + MSYS2 配置 C 语言开发环境(详细步骤)
c语言·ide·vscode
yscript5 小时前
GPU分配BUG: Duplicate GPU detected : rank 1 and rank 0 both on CUDA device d5000
linux·运维·服务器·vscode·bug
超超~~6 小时前
Notepad(文本编辑器)v3.6.30绿色官方版
编辑器·notepad++
shhpeng6 小时前
Visual Studio Code 下 go 开发环境搭建
ide·vscode·编辑器
MounRiver_Studio6 小时前
RISC-V IDE MRS2使用笔记(七):书签与笔记功能
ide·嵌入式·risc-v