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文件

相关推荐
嵌入小生0071 分钟前
线程 --- 嵌入式(Linux)
linux·vscode·vim·嵌入式·线程·进程
coderYYY12 小时前
VSCode终端启动报错
前端·ide·vscode·npm·编辑器
qinaoaini16 小时前
[golang][MAC]Go环境搭建+VsCode配置
vscode·macos·golang
FunW1n20 小时前
Android Studio与Hook模块开发相关问题及实现方案梳理
android·ide·android studio
㱘郳21 小时前
通过注册表编辑器删除百度网盘的右键菜单、驱动器快捷方式和“我的电脑”图标
windows·编辑器·百度云
catchadmin1 天前
“Fatal error: require(): Failed opening required...” 以及如何彻底避免它再次出现
android·ide·android studio
道法自然,人法天1 天前
idea编辑器快捷键应用大全
java·编辑器·intellij-idea
承渊政道1 天前
C++学习之旅【实战全面解析C++二叉搜索树】
开发语言·数据结构·c++·笔记·学习·编辑器·迭代加深
来两个炸鸡腿2 天前
【Datawhale组队学习202602】Easy-Vibe task02 认识AI IDE工具
ide·人工智能·学习·大模型