Added config for typst to kakoune.

This commit is contained in:
vorboyvo 2024-11-12 11:49:21 -05:00
parent 71d6a60108
commit 7a987c6ddd
2 changed files with 22 additions and 0 deletions

View file

@ -18,12 +18,22 @@
commands = "kakboard-enable";
option = ".*";
}
{
name = "BufCreate";
commands = "set buffer filetype typst";
option = ".*\.typ";
}
{
# When the filetype=latex option is set in a buffer context (automatically), add a new hook to build the latex file on write
name = "BufSetOption";
option = "filetype=latex";
commands = "hook buffer BufWritePost .* %{ texlab-build }";
}
{
name = "BufSetOption";
option = "filetype=typst";
commands = "hook buffer BufWritePost .* %{ nop %sh{ typst compile $kak_buffile } }";
}
{
# When the filetype=markdown option is set (automatically), set word wrap on
name = "WinSetOption";

View file

@ -411,6 +411,18 @@ forwardSearch.args = [
""",
]
[language_server.tinymist]
filetypes = ["typst"]
command = "tinymist"
roots = [".git", ".hg"]
args = ["lsp"]
settings_section = "_"
[language_server.tinymist.settings._]
# See https://myriad-dreamin.github.io/tinymist/configurations.html
exportPdf = "onDocumentHasTitle"
formatterMode = "typstyle"
previewFeature = "disable"
[language_server.typescript-language-server]
filetypes = ["javascript", "typescript"]
roots = ["package.json", "tsconfig.json", "jsconfig.json", ".git", ".hg"]