From 189d244d36d4ebb2189b698adb21f51cf1c4176a Mon Sep 17 00:00:00 2001 From: Thomas Schmucker Date: Wed, 12 Aug 2026 09:22:12 +0200 Subject: Revert "Normalize line endings" This reverts commit 6e5882a2fd02d30206ab9ca8aa5847b8ea09196c. --- nvim/lua/plugins/completion.lua | 92 +++++++-------- nvim/lua/plugins/editing.lua | 64 +++++------ nvim/lua/plugins/format.lua | 92 +++++++-------- nvim/lua/plugins/git.lua | 32 +++--- nvim/lua/plugins/lsp.lua | 248 ++++++++++++++++++++-------------------- nvim/lua/plugins/telescope.lua | 42 +++---- nvim/lua/plugins/treesitter.lua | 44 +++---- 7 files changed, 307 insertions(+), 307 deletions(-) (limited to 'nvim/lua/plugins') diff --git a/nvim/lua/plugins/completion.lua b/nvim/lua/plugins/completion.lua index 6e20d73..4912815 100644 --- a/nvim/lua/plugins/completion.lua +++ b/nvim/lua/plugins/completion.lua @@ -1,46 +1,46 @@ -return { - { - "saghen/blink.cmp", - dependencies = { "rafamadriz/friendly-snippets" }, - version = "1.*", - - opts = { - keymap = { preset = "default" }, - - appearance = { - use_nvim_cmp_as_default = true, - nerd_font_variant = "mono", - }, - - completion = { - documentation = { - auto_show = false, - window = { - border = "rounded", - }, - }, - - menu = { - border = "rounded", - }, - }, - - signature = { - enabled = true, - window = { - border = "rounded", - }, - }, - - sources = { - default = { "lsp", "path", "snippets", "buffer" }, - }, - - fuzzy = { - implementation = "prefer_rust_with_warning", - }, - }, - - opts_extend = { "sources.default" }, - }, -} +return { + { + "saghen/blink.cmp", + dependencies = { "rafamadriz/friendly-snippets" }, + version = "1.*", + + opts = { + keymap = { preset = "default" }, + + appearance = { + use_nvim_cmp_as_default = true, + nerd_font_variant = "mono", + }, + + completion = { + documentation = { + auto_show = false, + window = { + border = "rounded", + }, + }, + + menu = { + border = "rounded", + }, + }, + + signature = { + enabled = true, + window = { + border = "rounded", + }, + }, + + sources = { + default = { "lsp", "path", "snippets", "buffer" }, + }, + + fuzzy = { + implementation = "prefer_rust_with_warning", + }, + }, + + opts_extend = { "sources.default" }, + }, +} diff --git a/nvim/lua/plugins/editing.lua b/nvim/lua/plugins/editing.lua index 38e651c..b9f9283 100644 --- a/nvim/lua/plugins/editing.lua +++ b/nvim/lua/plugins/editing.lua @@ -1,32 +1,32 @@ -return { - { - "tpope/vim-repeat", - event = "VeryLazy", - }, - - { - "tpope/vim-surround", -- alternative: "kylechui/nvim-surround" - event = "VeryLazy", - }, - - { - "romainl/vim-cool", - event = "VeryLazy", - }, - - { - "windwp/nvim-autopairs", - event = "InsertEnter", - config = true, - }, - - { - "windwp/nvim-ts-autotag", - event = "InsertEnter", - }, - - { - "preservim/vim-markdown", - ft = "markdown", - }, -} +return { + { + "tpope/vim-repeat", + event = "VeryLazy", + }, + + { + "tpope/vim-surround", -- alternative: "kylechui/nvim-surround" + event = "VeryLazy", + }, + + { + "romainl/vim-cool", + event = "VeryLazy", + }, + + { + "windwp/nvim-autopairs", + event = "InsertEnter", + config = true, + }, + + { + "windwp/nvim-ts-autotag", + event = "InsertEnter", + }, + + { + "preservim/vim-markdown", + ft = "markdown", + }, +} diff --git a/nvim/lua/plugins/format.lua b/nvim/lua/plugins/format.lua index 102326c..8ca7f1b 100644 --- a/nvim/lua/plugins/format.lua +++ b/nvim/lua/plugins/format.lua @@ -1,46 +1,46 @@ --- Verfügbare Formater: https://github.com/stevearc/conform.nvim/tree/master/lua/conform/formatters - -local clang = {} -local gawk = { "gawk" } -- brew install gawk, pkg install gawk -local jq = { "jq" } -- brew install jq, pkg install jq -local prettier = { "prettier" } -- npm install -g prettier -local ruff = { "ruff_format" } -- brew install ruff, pkg install ruff -local shfmt = { "shfmt" } -- brew install shfmt, pkg install shfmt -local stylua = { "stylua" } -- brew install stylua, pkg install stylua -local xmllint = { "xmllint" } -- xmllint ist Teil von libxml2 (standardmäßig installiert unter MacOS; pkg install libxml2) -local yamlfmt = { "yamlfmt" } -- brew install yamlfmt, pkg install yamlfmt - -return { - "stevearc/conform.nvim", - event = { "BufReadPre", "BufNewFile" }, - keys = { - { - "cf", - function() - require("conform").format({ async = true }) - end, - desc = "Format file", - }, - }, - opts = { - formatters_by_ft = { - awk = gawk, - bash = shfmt, - c = clang, - cpp = clang, - html = prettier, - javascript = prettier, - json = jq, - lua = stylua, - python = ruff, - sh = shfmt, - typescript = prettier, - xml = xmllint, - xsd = xmllint, - yaml = yamlfmt, - }, - default_format_opts = { - lsp_format = "fallback", - }, - }, -} +-- Verfügbare Formater: https://github.com/stevearc/conform.nvim/tree/master/lua/conform/formatters + +local clang = {} +local gawk = { "gawk" } -- brew install gawk, pkg install gawk +local jq = { "jq" } -- brew install jq, pkg install jq +local prettier = { "prettier" } -- npm install -g prettier +local ruff = { "ruff_format" } -- brew install ruff, pkg install ruff +local shfmt = { "shfmt" } -- brew install shfmt, pkg install shfmt +local stylua = { "stylua" } -- brew install stylua, pkg install stylua +local xmllint = { "xmllint" } -- xmllint ist Teil von libxml2 (standardmäßig installiert unter MacOS; pkg install libxml2) +local yamlfmt = { "yamlfmt" } -- brew install yamlfmt, pkg install yamlfmt + +return { + "stevearc/conform.nvim", + event = { "BufReadPre", "BufNewFile" }, + keys = { + { + "cf", + function() + require("conform").format({ async = true }) + end, + desc = "Format file", + }, + }, + opts = { + formatters_by_ft = { + awk = gawk, + bash = shfmt, + c = clang, + cpp = clang, + html = prettier, + javascript = prettier, + json = jq, + lua = stylua, + python = ruff, + sh = shfmt, + typescript = prettier, + xml = xmllint, + xsd = xmllint, + yaml = yamlfmt, + }, + default_format_opts = { + lsp_format = "fallback", + }, + }, +} diff --git a/nvim/lua/plugins/git.lua b/nvim/lua/plugins/git.lua index 37d5ee3..ed7bafe 100644 --- a/nvim/lua/plugins/git.lua +++ b/nvim/lua/plugins/git.lua @@ -1,16 +1,16 @@ -return { - { - "lewis6991/gitsigns.nvim", - event = { "BufReadPre", "BufNewFile" }, - opts = { - current_line_blame = true, - current_line_blame_opts = { - delay = 250, - }, - }, - config = function(_, opts) - require("gitsigns").setup(opts) - require("config.keymaps").gitsigns() - end, - }, -} +return { + { + "lewis6991/gitsigns.nvim", + event = { "BufReadPre", "BufNewFile" }, + opts = { + current_line_blame = true, + current_line_blame_opts = { + delay = 250, + }, + }, + config = function(_, opts) + require("gitsigns").setup(opts) + require("config.keymaps").gitsigns() + end, + }, +} diff --git a/nvim/lua/plugins/lsp.lua b/nvim/lua/plugins/lsp.lua index 812ed24..b301b68 100644 --- a/nvim/lua/plugins/lsp.lua +++ b/nvim/lua/plugins/lsp.lua @@ -1,124 +1,124 @@ -return { - { - "neovim/nvim-lspconfig", - dependencies = { "saghen/blink.cmp" }, - lazy = false, - config = function() - local capabilities = require("blink.cmp").get_lsp_capabilities(vim.lsp.protocol.make_client_capabilities()) - - vim.lsp.config.lua_ls = { - capabilities = capabilities, - settings = { - Lua = { - runtime = { - version = "LuaJIT", - }, - diagnostics = { - globals = { "vim" }, - }, - workspace = { - checkThirdParty = false, - library = { - vim.env.VIMRUNTIME .. "/lua", - vim.fn.stdpath("config") .. "/lua", - }, - }, - telemetry = { - enable = false, - }, - }, - }, - } - - vim.lsp.config.bashls = { - capabilities = capabilities, - filetypes = { "sh", "bash" }, - } - - vim.lsp.config.clangd = { - capabilities = capabilities, - cmd = { - "clangd", - "--background-index", - "--clang-tidy", - "--completion-style=detailed", - "--header-insertion=iwyu", - "--header-insertion-decorators", - "--pch-storage=memory", - "--all-scopes-completion", - "--inlay-hints", - "--function-arg-placeholders", - "--fallback-style=llvm", - }, - } - - vim.lsp.config.prismals = { - capabilities = capabilities, - } - - vim.lsp.config.jsonls = { - capabilities = capabilities, - } - - vim.lsp.config.html = { - capabilities = capabilities, - } - - vim.lsp.config.vtsls = { - capabilities = capabilities, - settings = { - typescript = { - updateImportsOnFileMove = { enabled = "always" }, - suggest = { - completeFunctionCalls = true, - }, - inlayHints = { - enumMemberValues = { enabled = true }, - functionLikeReturnTypes = { enabled = true }, - parameterNames = { enabled = "all" }, - parameterTypes = { enabled = true }, - propertyDeclarationTypes = { enabled = true }, - variableTypes = { enabled = false }, - }, - }, - javascript = { - suggest = { - completeFunctionCalls = true, - }, - inlayHints = { - parameterNames = { enabled = "all" }, - }, - }, - }, - } - - vim.lsp.config.basedpyright = { - capabilities = capabilities, - settings = { - basedpyright = { - analysis = { - diagnosticMode = "openFilesOnly", - inlayHints = { - callArgumentNames = true, - }, - typeCheckingMode = "basic", -- oder "strict" für strenger - autoSearchPaths = true, - useLibraryCodeForTypes = true, - }, - }, - }, - } - - vim.lsp.enable({ - "basedpyright", -- npm install -g basedpyright, brew install basedpyright - "bashls", -- npm install -g bash-language-server, pkg install hs-ShellCheck - "clangd", -- pkg install llvm - "html", -- npm install -g vscode-langservers-extracted - "jsonls", -- npm install -g vscode-langservers-extracted - "lua_ls", -- pkg install lua-language-server, brew install lua-language-server - "prismals", -- npm install -g @prisma/language-server - "vtsls", -- npm install -g @vtsls/language-server - }) - end, - }, -} +return { + { + "neovim/nvim-lspconfig", + dependencies = { "saghen/blink.cmp" }, + lazy = false, + config = function() + local capabilities = require("blink.cmp").get_lsp_capabilities(vim.lsp.protocol.make_client_capabilities()) + + vim.lsp.config.lua_ls = { + capabilities = capabilities, + settings = { + Lua = { + runtime = { + version = "LuaJIT", + }, + diagnostics = { + globals = { "vim" }, + }, + workspace = { + checkThirdParty = false, + library = { + vim.env.VIMRUNTIME .. "/lua", + vim.fn.stdpath("config") .. "/lua", + }, + }, + telemetry = { + enable = false, + }, + }, + }, + } + + vim.lsp.config.bashls = { + capabilities = capabilities, + filetypes = { "sh", "bash" }, + } + + vim.lsp.config.clangd = { + capabilities = capabilities, + cmd = { + "clangd", + "--background-index", + "--clang-tidy", + "--completion-style=detailed", + "--header-insertion=iwyu", + "--header-insertion-decorators", + "--pch-storage=memory", + "--all-scopes-completion", + "--inlay-hints", + "--function-arg-placeholders", + "--fallback-style=llvm", + }, + } + + vim.lsp.config.prismals = { + capabilities = capabilities, + } + + vim.lsp.config.jsonls = { + capabilities = capabilities, + } + + vim.lsp.config.html = { + capabilities = capabilities, + } + + vim.lsp.config.vtsls = { + capabilities = capabilities, + settings = { + typescript = { + updateImportsOnFileMove = { enabled = "always" }, + suggest = { + completeFunctionCalls = true, + }, + inlayHints = { + enumMemberValues = { enabled = true }, + functionLikeReturnTypes = { enabled = true }, + parameterNames = { enabled = "all" }, + parameterTypes = { enabled = true }, + propertyDeclarationTypes = { enabled = true }, + variableTypes = { enabled = false }, + }, + }, + javascript = { + suggest = { + completeFunctionCalls = true, + }, + inlayHints = { + parameterNames = { enabled = "all" }, + }, + }, + }, + } + + vim.lsp.config.basedpyright = { + capabilities = capabilities, + settings = { + basedpyright = { + analysis = { + diagnosticMode = "openFilesOnly", + inlayHints = { + callArgumentNames = true, + }, + typeCheckingMode = "basic", -- oder "strict" für strenger + autoSearchPaths = true, + useLibraryCodeForTypes = true, + }, + }, + }, + } + + vim.lsp.enable({ + "basedpyright", -- npm install -g basedpyright, brew install basedpyright + "bashls", -- npm install -g bash-language-server, pkg install hs-ShellCheck + "clangd", -- pkg install llvm + "html", -- npm install -g vscode-langservers-extracted + "jsonls", -- npm install -g vscode-langservers-extracted + "lua_ls", -- pkg install lua-language-server, brew install lua-language-server + "prismals", -- npm install -g @prisma/language-server + "vtsls", -- npm install -g @vtsls/language-server + }) + end, + }, +} diff --git a/nvim/lua/plugins/telescope.lua b/nvim/lua/plugins/telescope.lua index d4e3fd3..d7fd279 100644 --- a/nvim/lua/plugins/telescope.lua +++ b/nvim/lua/plugins/telescope.lua @@ -1,21 +1,21 @@ -return { - { - "nvim-telescope/telescope.nvim", - dependencies = { - "nvim-lua/plenary.nvim", - }, - lazy = true, - opts = { - defaults = { - path_display = { "smart", "truncate" }, - }, - }, - keys = { - { "ff", "Telescope find_files", desc = "Find files" }, - { "fg", "Telescope live_grep", desc = "Live grep" }, - { "fb", "Telescope buffers", desc = "Buffers" }, - { "fh", "Telescope help_tags", desc = "Help tags" }, - { "dd", "Telescope diagnostics", desc = "Diagnostics" }, - }, - }, -} +return { + { + "nvim-telescope/telescope.nvim", + dependencies = { + "nvim-lua/plenary.nvim", + }, + lazy = true, + opts = { + defaults = { + path_display = { "smart", "truncate" }, + }, + }, + keys = { + { "ff", "Telescope find_files", desc = "Find files" }, + { "fg", "Telescope live_grep", desc = "Live grep" }, + { "fb", "Telescope buffers", desc = "Buffers" }, + { "fh", "Telescope help_tags", desc = "Help tags" }, + { "dd", "Telescope diagnostics", desc = "Diagnostics" }, + }, + }, +} diff --git a/nvim/lua/plugins/treesitter.lua b/nvim/lua/plugins/treesitter.lua index 954e05f..faa850a 100644 --- a/nvim/lua/plugins/treesitter.lua +++ b/nvim/lua/plugins/treesitter.lua @@ -1,22 +1,22 @@ --- https://github.com/nvim-treesitter/nvim-treesitter/blob/main/README.md - --- Stelle sicher, dass die TreeSitter-CLI installiert ist: --- MacOS: `brew install tree-sitter-cli` --- FreeBSD: `doas pkg install tree-sitter-cli` - -return { - { - "nvim-treesitter/nvim-treesitter", - branch = "main", - build = ":TSUpdate", - lazy = false, - opts = {}, - config = function(_, opts) - local treesitter = require("nvim-treesitter") - local langs = require("config.treesitter").languages - - treesitter.setup(opts) - treesitter.install(langs) - end, - }, -} +-- https://github.com/nvim-treesitter/nvim-treesitter/blob/main/README.md + +-- Stelle sicher, dass die TreeSitter-CLI installiert ist: +-- MacOS: `brew install tree-sitter-cli` +-- FreeBSD: `doas pkg install tree-sitter-cli` + +return { + { + "nvim-treesitter/nvim-treesitter", + branch = "main", + build = ":TSUpdate", + lazy = false, + opts = {}, + config = function(_, opts) + local treesitter = require("nvim-treesitter") + local langs = require("config.treesitter").languages + + treesitter.setup(opts) + treesitter.install(langs) + end, + }, +} -- cgit v1.3