TextLive2019 和 vscode

1. 下载TextLive2019

https://mirrors.tuna.tsinghua.edu.cn/CTAN/systems/texlive/Images/texlive2019.iso

点击install-tl-advanced.bat安装

注意:如果你的电脑安装有mingw,并且设置了path环境变量,否则会出现 _install_package: untar failed的错误!!!

修改安装地址,全部默认安装即可

2. vscode 官网下载vscode 

3. vscode 扩展中下载LaTex Workshop

4. Files -> preferences -> settings 搜索latex-workshop.latex.recipes

 点击Edit in setting.json

5. 将下面代码放进去

{
  "latex-workshop.view.pdf.viewer": "tab",
  "latex-workshop.latex.autoClean.run": "onBuilt",
  "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",
    "*.gz"
    ],
    "latex-workshop.latex.recipes": [
      {
        "name": "xelatex",
        "tools": [
          "xelatex"
        ]
      },
      {
        "name": "xelatex -> bibtex -> xelatex*2",
        "tools": [
          "xelatex",
          "bibtex",
          "xelatex",
          "xelatex"
        ]
      }
    ],
    "latex-workshop.latex.tools": [
      {
        "name": "latexmk",
        "command": "latexmk",
        "args": [
          "-synctex=1",
          "-interaction=nonstopmode",
          "-file-line-error",
          "-pdf",
          "%DOC%"
        ]
      },
      {
        "name": "xelatex",
        "command": "xelatex",
        "args": [
          "-synctex=1",
          "-interaction=nonstopmode",
          "-file-line-error",
          "%DOC%"
        ]
      },
      {
        "name": "bibtex",
        "command": "bibtex",
        "args": [
          "%DOCFILE%"
        ]
      }
    ],
    "latex-preview.command": "xelatex"
}

创建文件保存后编译生成Pdfd

 

posted @ 2019-09-11 20:34  风影旋新月  阅读(1535)  评论(0编辑  收藏  举报