This is a LaTeX Codespace Configuation Template, which is to create a working LaTeX environment as efficient as possible.
- Create your own repo using this repo as a template.
- Setup codespace prebuilds in Settings/Codespace.
- Wait for your codespace prebuilding task complete.
- Create a codespace from the repo.
- Full TeX Live installation (see here)
bibtex
support - automatically compile.bib
fileslatexindent
support - automatically formatting on savetexcount
support - automatically count words on save
Submit an issue if you believe an extension is essential to this environment.
- libfont - required by XeLaTeX
- Python 3
Configuration in .devcontainer/Dockerfile
and .devcontainer/devcontainer.json
are my usual usage. However, you can customize packages, extensions and setting in the following steps if needed.
The image is based on Ubunut 20.04 LTS which uses apt
and apt-get
to manage packages. Just add the following code to .devcontainer/Dockerfile
if you want to customize packages included in the prebuilt image.
RUN apt-get update
RUN apt-get install your-package -y
Extensions and settings configuration are stored under .devcontainer/devcontainer.json
. If you want to add your own extension, follow the following steps:
-
Find the extension in Visual Studio Code or in Visual Studio Code Marketplace
-
Get the extension ID: In Visual Studio Code, right click on the extension and click "Copy Extension ID". In Visual Studio Code Marketplace, you have to go to the URL section of your browser, the extension ID is displayed in the following manner.
https://marketplace.visualstudio.com/items?itemName=<extension-id>
-
Add the extension ID to the
extensions
field in.devcontainer/devcontainer.json
."extensions": [ ... "<extension-id>", ],
After these steps, you've successfully added an extension to the codespace. You may want to import your preferences from you local Visual Studio Code workspace.
This step is relatively simple - just open your settings.json
and copy the related settings entry to settings
field in .devcontainer/devcontainer.json
.
First make sure you have added the theme in extensions
entry. Update the workbench.colorTheme
and workbench.iconTheme
entry in .devcontainer/devcontainer.json
.
The template is based on qdm12/latexdevcontainer.