美文网首页
使用vscode和mactex

使用vscode和mactex

作者: 九乡河的小香瓜 | 来源:发表于2019-08-20 14:26 被阅读0次

配置

首先安装好vscode ,mactex和插件latex workshop 。之后修改settings.json 。

image image

"latex-workshop.view.pdf.viewer": "tab",

    "latex-workshop.latex.tools": [

        {

            "name": "xelatex",

            "command": "xelatex",

            "args": [

                "-synctex=1",

                "-interaction=nonstopmode",

                "-file-line-error",

                "-pdf",

                "%DOC%"

            ]

        },

        {

            "name": "latexmk",

            "command": "latexmk",

            "args": [

                "-synctex=1",

                "-interaction=nonstopmode",

                "-file-line-error",

                "-pdf",

                "%DOC%"

            ]

        },

        {

            "name": "pdflatex",

            "command": "pdflatex",

            "args": [

                "-synctex=1",

                "-interaction=nonstopmode",

                "-file-line-error",

                "%DOC%"

            ]

        },

        {

            "name": "bibtex",

            "command": "bibtex",

            "args": [

                "%DOCFILE%"

            ]

        }

    ],

    "latex-workshop.latex.recipes": [

        {

            "name": "xelatex",

            "tools": [

                "xelatex"

            ]

        },

        {

            "name": "pdflatex -> bibtex -> pdflatex*2",

            "tools": [

                "pdflatex",

                "bibtex",

                "pdflatex",

                "pdflatex"

            ]

        }

    ]

使用

在vscode中导入.tex文件。点击1,出现commands,点击build编译,点击view latex pdf出现右边的pdf,点击view log messages出现log。之后修改.tex,只要保存就会自动build,pdf会自动显示变化。

image

相关文章

网友评论

      本文标题:使用vscode和mactex

      本文链接:https://www.haomeiwen.com/subject/dhlpsctx.html