From 91008c6b4929399cb27dfa91defa1a81305ceffe Mon Sep 17 00:00:00 2001 From: Jan Wille <jan.wille@stud.hs-hannover.de> Date: Fri, 24 May 2024 13:05:22 +0200 Subject: [PATCH] add vscode settings --- .gitignore | 4 ++ .vscode/extensions.json | 7 +++ .vscode/settings.json | 123 ++++++++++++++++++++++++++++++++++++++++ example.pdf | 4 +- 4 files changed, 136 insertions(+), 2 deletions(-) create mode 100644 .vscode/extensions.json create mode 100644 .vscode/settings.json diff --git a/.gitignore b/.gitignore index ef66944..4e6b913 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,7 @@ *.log /*.pdf + +# files that are usually excluded but here we want them: +!example.pdf +!.vscode/*.json diff --git a/.vscode/extensions.json b/.vscode/extensions.json new file mode 100644 index 0000000..c1b31c6 --- /dev/null +++ b/.vscode/extensions.json @@ -0,0 +1,7 @@ +{ + "recommendations": [ + "james-yu.latex-workshop", + "valentjn.vscode-ltex", + "stkb.rewrap" + ] +} diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..64b3899 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,123 @@ +{ + "ltex.enabled": true, + "ltex.language": "en-GB", + "ltex.additionalRules.motherTongue": "de-DE", + "[latex]": { + "rewrap.autoWrap.enabled": true, + "editor.rulers": [ + 100 + ], + "rewrap.wrappingColumn": 100, + }, + "latex-workshop.linting.run": "onType", + "latex-workshop.latex.autoBuild.run": "onSave", + "latex-workshop.showContextMenu": true, + "latex-workshop.latex.outDir": "%DIR%", + "latex-workshop.latex.recipes": [ + { + "name": "latexmk", + "tools": [ + "latexmk" + ] + }, + { + "name": "pdflatex", + "tools": [ + "pdflatex" + ] + }, + { + "name": "biber", + "tools": [ + "biber" + ] + }, + { + "name": "pdflatex ➞ biber ➞ 2× pdflatex", + "tools": [ + "pdflatex", + "biber", + "pdflatex", + "pdflatex" + ] + }, + { + "name": "Optimize PDF", + "tools": [ + "gs opt printer" + ] + } + ], + "latex-workshop.latex.tools": [ + { + "name": "latexmk", + "command": "latexmk", + "args": [ + "-pdf", + "-interaction=nonstopmode", + "-synctex=1", + "-auxdir=%OUTDIR%/.aux", + "-outdir=%OUTDIR%", + "%DOC_EXT%" + ], + "env": { + "TEXINPUTS": "%WORKSPACE_FOLDER%/src/" + } + }, + { + "name": "pdflatex", + "command": "pdflatex", + "args": [ + "-synctex=1", + "-interaction=nonstopmode", + "-file-line-error", + "-aux-directory=%OUTDIR%/.aux", + "-output-directory=%OUTDIR%", + "%DOC_EXT%" + ], + "env": { + "TEXINPUTS": "%WORKSPACE_FOLDER%/src/" + } + }, + { + "name": "biber", + "command": "biber", + "args": [ + "-output-directory=%OUTDIR%/.aux", + "%DOCFILE%" + ] + }, + { + "name": "bibtex", + "command": "bibtex", + "args": [ + "-include-directory=.aux", + "%OUTDIR%/.aux/%DOCFILE%" + ] + }, + { + "name": "gs opt printer", + "command": "mgs", + "args": [ + "-sDEVICE=pdfwrite", + "-dPrinted=false", + "-dPDFSETTINGS=/printer", + "-o", + "%OUTDIR%/%DOCFILE%_optimized.pdf", + "%OUTDIR%/%DOCFILE%.pdf" + ] + }, + { + "name": "gs opt extrem", + "command": "mgs", + "args": [ + "-sDEVICE=pdfwrite", + "-dPrinted=false", + "-dPDFSETTINGS=/ebook", + "-o", + "%OUTDIR%/%DOCFILE%_optimized.pdf", + "%OUTDIR%/%DOCFILE%.pdf" + ] + } + ], +} diff --git a/example.pdf b/example.pdf index 51f2aee..877e10f 100644 --- a/example.pdf +++ b/example.pdf @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9ae99708e9128d305fb6d9af123778381dbb1726d8ca998da3c818c18abc9188 -size 257485 +oid sha256:3129c59bf8c34cd5cd6c75f66909d541da45d87b49f355f24102f1a8c98cf980 +size 257486 -- GitLab