From a78dbd4756561bec958241d80e48273332e09ba3 Mon Sep 17 00:00:00 2001 From: ndsboy Date: Sun, 22 Sep 2024 17:39:56 +0000 Subject: [PATCH] feat: add devcontainer --- .devcontainer/Containerfile | 5 +++++ .devcontainer/devcontainer.json | 20 ++++++++++++++++++++ .vscode/extensions.json | 8 ++++++-- .vscode/settings.json | 10 +++++----- rechnung.yml.template | 3 +-- 5 files changed, 37 insertions(+), 9 deletions(-) create mode 100644 .devcontainer/Containerfile create mode 100644 .devcontainer/devcontainer.json diff --git a/.devcontainer/Containerfile b/.devcontainer/Containerfile new file mode 100644 index 0000000..3718127 --- /dev/null +++ b/.devcontainer/Containerfile @@ -0,0 +1,5 @@ +FROM mcr.microsoft.com/devcontainers/base:alpine +RUN apk add typst +RUN mkdir -p /home/vscode/.local/share/fonts +RUN wget -O /home/vscode/.local/share/fonts/ubuntu.ttf https://cdn.jsdelivr.net/fontsource/fonts/ubuntu@latest/latin-400-normal.ttf +RUN wget -O /home/vscode/.local/share/fonts/noto.ttf https://cdn.jsdelivr.net/fontsource/fonts/noto-sans@latest/latin-400-normal.ttf \ No newline at end of file diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json new file mode 100644 index 0000000..2f504f2 --- /dev/null +++ b/.devcontainer/devcontainer.json @@ -0,0 +1,20 @@ +{ + "name": "documents", + "build": { + "dockerfile": "Containerfile" + }, + "containerUser": "vscode", + "runArgs": [ + "--userns=keep-id", + "--security-opt=label=disable" + ], + "customizations": { + "vscode": { + "extensions": [ + "myriad-dreamin.tinymist", + "redhat.vscode-yaml", + "mathematic.vscode-pdf" + ] + } + } +} \ No newline at end of file diff --git a/.vscode/extensions.json b/.vscode/extensions.json index 81b72bc..808e456 100644 --- a/.vscode/extensions.json +++ b/.vscode/extensions.json @@ -1,3 +1,7 @@ { - "recommendations": ["mathematic.vscode-pdf", "nvarner.typst-lsp"] -} + "recommendations": [ + "myriad-dreamin.tinymist", + "redhat.vscode-yaml", + "mathematic.vscode-pdf" + ] +} \ No newline at end of file diff --git a/.vscode/settings.json b/.vscode/settings.json index 496a94e..71447bd 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,14 +1,14 @@ { "editor.tabSize": 2, "editor.formatOnSave": true, - "prettier.tabWidth": 2, "[typst]": { "editor.wordWrap": "on" }, "[yaml]": { "editor.insertSpaces": true, - "editor.tabSize": 2, - "editor.autoIndent": "advanced", - "editor.defaultFormatter": "esbenp.prettier-vscode" + "editor.autoIndent": "advanced" + }, + "files.associations": { + "*.yml.template": "yaml" } -} +} \ No newline at end of file diff --git a/rechnung.yml.template b/rechnung.yml.template index de15f4a..547c4e2 100644 --- a/rechnung.yml.template +++ b/rechnung.yml.template @@ -1,9 +1,8 @@ - # invoice (Rechnung) # offer (Angebot) # estimate (Kostenvoranschlag) # internal (Eigenbeleg) -type: invoice +type: invoice date: 01.01.2024 customer_no: 0 # für Rechnung, Angebot und Kostenvoranschlag invoice_no: 0 # für Rechnung und Angebot