]> src.twobees.de Git - dotfiles.git/blobdiff - stow/nvim/.config/nvim/init.lua
up
[dotfiles.git] / stow / nvim / .config / nvim / init.lua
index c02802832b5f829ddc8c68d0395079fb313b65ef..c4922ec27b5c8b157293f8e407ec2cf205f189ff 100644 (file)
@@ -100,12 +100,8 @@ require('lazy').setup({
     },
   },
 
-  {
-    -- Add indentation guides even on blank lines
-    'lukas-reineke/indent-blankline.nvim',
-    main = "ibl",
-    opts = { },
-  },
+  -- {  dir = '~/github/mynvimplugins/btoggle.nvim/' },
+  {  'tobser/btoggle.nvim' },
 
   -- "gc" to comment visual regions/lines
   { 'numToStr/Comment.nvim',         opts = {} },
@@ -156,7 +152,7 @@ require('lazy').setup({
 -- See `:help vim.o`
 
 -- Set highlight on search
-vim.o.hlsearch = false
+vim.o.hlsearch = true
 
 -- Make line numbers default
 vim.wo.relativenumber = true
@@ -272,13 +268,13 @@ augroup END
 require('nvim-treesitter.configs').setup {
   -- Add languages to be installed here that you want installed for treesitter
   ensure_installed = { 'c', 'cpp', 'go', 'lua', 'python', 'rust', 'tsx', 'typescript', 'vimdoc', 'vim', 'html',
-    'c_sharp', 'perl', 'python' },
+    'c_sharp', 'perl', 'bash', 'python' ,'markdown' },
 
   -- Autoinstall languages that are not installed. Defaults to false (but you can change for yourself!)
   auto_install = false,
 
   highlight = { enable = true },
-  indent = { enable = true, disable = { 'python' } },
+  indent = { enable = false, disable = { 'python' } },
   incremental_selection = {
     enable = true,
     keymaps = {
@@ -370,8 +366,6 @@ local on_attach = function(client, bufnr)
   nmap('<leader>ds', require('telescope.builtin').lsp_document_symbols, '[D]ocument [S]ymbols')
   nmap('<leader>ws', require('telescope.builtin').lsp_dynamic_workspace_symbols, '[W]orkspace [S]ymbols')
 
-
-
   -- See `:help K` for why this keymap
   nmap('K', vim.lsp.buf.hover, 'Hover Documentation')
   nmap('<C-k>', vim.lsp.buf.signature_help, 'Signature Documentation')
@@ -435,6 +429,38 @@ mason_lspconfig.setup_handlers {
   end,
 }
 
+-- require('lspconfig').perlls.setup {
+--   settings = {
+--     perl = {
+--       perlInc = {
+--         '/home/pi/git/misterhouse/lib',
+--         '/home/pi/git/misterhouse/bin',
+--       },
+--     },
+--   },
+--   capabilities = capabilities,
+--   on_attach = on_attach,
+-- }
+--
+require('lspconfig').perlpls.setup {
+  on_attach = on_attach,
+  settings = {
+    perl = {
+      perlcritic = {
+        enabled = false
+      },
+      syntax = {
+        enabled = true
+      },
+      inc = {
+        '/home/pi/git/misterhouse/lib',
+        '/home/pi/git/misterhouse/bin',
+      },
+    },
+  },
+  capabilities = capabilities,
+}
+
 -- nvim-cmp setup
 local cmp = require 'cmp'
 local luasnip = require 'luasnip'
@@ -507,6 +533,7 @@ prettier.setup({
     "javascriptreact",
     "json",
     "less",
+    "perl",
     "markdown",
     "scss",
     "typescript",
@@ -519,5 +546,17 @@ vim.opt.diffopt = vim.opt.diffopt + "vertical"
 vim.opt.cursorline = true
 vim.opt.hlsearch = true
 
+local bt =  require("btoggle");
+bt.setup({
+  ["true"] = "false",
+  ["True"] = "False",
+  ["False"] = "True",
+  ["false"] = "true",
+  ["foo"] = "bar",
+  ["bar"] = "bor",
+  ["bor"] = "foo"
+})
+vim.keymap.set('n', '<leader>b', bt.toggle)
+
 -- The line beneath this is called `modeline`. See `:help modeline`
 -- vim: ts=2 sts=2 sw=2 et