From f4f96a84fc7d3234f14e0eb02e12e40ce621421c Mon Sep 17 00:00:00 2001 From: Thomas Schmucker Date: Tue, 8 Sep 2026 15:21:48 +0200 Subject: Verbessere die Treesitter-Erkennung für Windows und Bash-Skripte MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- nvim/lua/config/treesitter.lua | 7 ++++++- nvim/lua/plugins/format.lua | 1 - 2 files changed, 6 insertions(+), 2 deletions(-) (limited to 'nvim/lua') diff --git a/nvim/lua/config/treesitter.lua b/nvim/lua/config/treesitter.lua index df03ef2..5451c6d 100644 --- a/nvim/lua/config/treesitter.lua +++ b/nvim/lua/config/treesitter.lua @@ -14,7 +14,7 @@ M.languages = { "lua", "make", "markdown", - "markdown_inline", + "markdown_inline", -- kein eigener Dateityp, nur fuer Injections in Markdown "po", "powershell", "prisma", @@ -32,6 +32,11 @@ local extra_filetypes = { -- nvim-treesitter stellt keinen jsonc-Parser bereit; der json-Parser -- versteht // und /* */ Kommentare. jsonc = "json", + + -- Dateityp und Parser heissen unterschiedlich; ohne diese Zuordnung findet + -- vim.treesitter.start() keinen Parser und die FileType-Autocmd feuert nicht. + sh = "bash", + ps1 = "powershell", } -- Macht die Parser der Filetypes ohne gleichnamigen Parser bekannt. diff --git a/nvim/lua/plugins/format.lua b/nvim/lua/plugins/format.lua index 77abc76..d8f96e2 100644 --- a/nvim/lua/plugins/format.lua +++ b/nvim/lua/plugins/format.lua @@ -27,7 +27,6 @@ return { opts = { formatters_by_ft = { awk = gawk, - bash = shfmt, c = clang, cpp = clang, html = prettier, -- cgit v1.3