From dfb6906bff06e8904cd3ea8d8b251522c46b95c6 Mon Sep 17 00:00:00 2001 From: Jeff LANCE Date: Sat, 6 Jan 2024 23:01:06 +0100 Subject: [PATCH] Add lvim. --- dot_config/lvim/after/.keep | 0 dot_config/lvim/config.lua | 214 ++++++++++++++++++++++++++++++ dot_config/lvim/ftdetect/.keep | 0 dot_config/lvim/ftplugin/.keep | 0 dot_config/lvim/lazy-lock.json | 75 +++++++++++ dot_config/lvim/lua/.keep | 0 dot_config/lvim/luasnippets/.keep | 0 7 files changed, 289 insertions(+) create mode 100644 dot_config/lvim/after/.keep create mode 100644 dot_config/lvim/config.lua create mode 100644 dot_config/lvim/ftdetect/.keep create mode 100644 dot_config/lvim/ftplugin/.keep create mode 100644 dot_config/lvim/lazy-lock.json create mode 100644 dot_config/lvim/lua/.keep create mode 100644 dot_config/lvim/luasnippets/.keep diff --git a/dot_config/lvim/after/.keep b/dot_config/lvim/after/.keep new file mode 100644 index 0000000..e69de29 diff --git a/dot_config/lvim/config.lua b/dot_config/lvim/config.lua new file mode 100644 index 0000000..cc05e5e --- /dev/null +++ b/dot_config/lvim/config.lua @@ -0,0 +1,214 @@ +--[[-- +File : /home/jeff/.config/lvim/config.lua +Author : Jeff Lance +Date : 03.08.2023 16:16:54 +Last Modified Date: 10.08.2023 00:57:51 +Last Modified By : Jeff Lance + +--- + +lvim is the global options object + +--]]-- + + + +-- general +-- + +-- lvim config +lvim.log.level = "warn" +lvim.format_on_save.enabled = true +lvim.format_on_save.pattern = { "*.asy", "*.py", ".toml" } +lvim.colorscheme = "onedark_dark" +lvim.background = "dark" +lvim.transparent_window = true +-- to disable icons and use a minimalist setup, uncomment the following +-- lvim.use_icons = false + +-- core plugins config +-- local components = require("lvim.core.lualine.components") +lvim.builtin.lualine.sections.lualine_a = { "mode" } +-- lvim.builtin.lualine.sections.lualine_y = { +-- -- components.spaces, +-- -- components.location +-- } +lvim.builtin.alpha.active = true +lvim.builtin.alpha.mode = "dashboard" +lvim.builtin.luasnip.enable_autosnippets = true +lvim.builtin.nvimtree.active = false +lvim.builtin.nvimtree.setup.view.side = "left" +lvim.builtin.nvimtree.setup.renderer.icons.show.git = false +lvim.builtin.terminal.active = true + + + +-- theme settings +-- + +-- lvim.builtin.theme.options.dim_inactive = true +-- lvim.builtin.theme.options.style = "storm" + + + +-- variables +-- +local home = vim.fn.expand("$HOME") + + + +-- ============================================== +-- Trying to make a modular configuration +-- plugins +-- +require("user.plugins").setup() + + + +-- functions +-- +require("user.functions") + + + +-- keybindings +-- +require("user.keybindings").setup() +-- + + + +-- which_key +-- +require("user.whichkey").setup() +-- +-- ============================================== + + + +-- Treesitter settings +-- + +-- if you don't want all the parsers change this to a table of the ones you want +lvim.builtin.treesitter.ensure_installed = { + "bash", + "c", + "java", + "javascript", + "json", + "julia", + "latex", + "lua", + "perl", + "python", + "typescript", + "tsx", + "css", + "ruby", + "rust", + "toml", + "yaml", +} + +lvim.builtin.treesitter.ignore_install = { "comment" } +lvim.builtin.treesitter.highlight.enable = true +lvim.builtin.treesitter.highlight.disable( "latex" ) +lvim.builtin.treesitter.rainbow.enable = true + + + +-- LSP settings +-- + +require("user.lsp").setup() + + + +-- Setup formatters and linters +-- +-- Currently started with ftplugin for: +-- latex +-- python + + + +-- Debug adapters +-- + +require("user.dap").setup() + + + +-- Tests framework +-- + +require("user.tests").setup() + + + +-- Telescope plugins load +-- + +lvim.builtin.telescope.on_config_done = function(telescope) + -- pcall(telescope.load_extension, "project") + -- any other extensions loading +end + + + +-- Autocommands (https://neovim.io/doc/user/autocmd.html) +-- + +-- minimap view +-- lvim.autocommands = { +-- { +-- {"BufEnter", "Filetype"}, +-- { +-- desc = "Open mini.map and exclude some filetypes", +-- pattern = { "*" }, +-- callback = function() +-- local exclude_ft = { +-- "qf", +-- "NvimTree", +-- "toggleterm", +-- "TelescopePrompt", +-- "alpha", +-- "netrw", +-- } + +-- local map = require('mini.map') +-- if vim.tbl_contains(exclude_ft, vim.o.filetype) then +-- vim.b.minimap_disable = true +-- map.close() +-- elseif vim.o.buftype == "" then +-- map.open() +-- end +-- end, +-- }, +-- }, +-- } + +-- wrap mode for json files +vim.api.nvim_create_autocmd("BufEnter", { + pattern = { "*.json", "*.jsonc" }, + -- enable wrap mode for json files only + command = "setlocal wrap", +}) + +-- bash highlight for zsh files +vim.api.nvim_create_autocmd("FileType", { + pattern = "zsh", + callback = function() + -- let treesitter use bash highlight for zsh files as well + require("nvim-treesitter.highlight").attach(0, "bash") + end, +}) + +-- -- latex cmp +-- vim.api.nvim_create_autocmd("FileType", { +-- group = vim.api.nvim_create_augroup("LaTeXGroup", { clear = true }), +-- pattern = "tex", +-- callback = function() +-- require("user.cmp") +-- end, +-- }) diff --git a/dot_config/lvim/ftdetect/.keep b/dot_config/lvim/ftdetect/.keep new file mode 100644 index 0000000..e69de29 diff --git a/dot_config/lvim/ftplugin/.keep b/dot_config/lvim/ftplugin/.keep new file mode 100644 index 0000000..e69de29 diff --git a/dot_config/lvim/lazy-lock.json b/dot_config/lvim/lazy-lock.json new file mode 100644 index 0000000..661708c --- /dev/null +++ b/dot_config/lvim/lazy-lock.json @@ -0,0 +1,75 @@ +{ + "Abstract-cs": { "branch": "main", "commit": "07475aa22943dc25080239c8cab613ab0a2945df" }, + "AdvancedNewFile.nvim": { "branch": "main", "commit": "9b4576dcf916d848148241e7269c9cd78f299b22" }, + "ChatGPT.nvim": { "branch": "main", "commit": "48c59167beeb6ee0caa501c46cecc97b9be8571d" }, + "Comment.nvim": { "branch": "master", "commit": "38d3b7eb553872d8866f14a0dd4fe84126068fce" }, + "LuaSnip": { "branch": "master", "commit": "e77fa9ad0b1f4fc6cddf54e51047e17e90c7d7ed" }, + "alpha-nvim": { "branch": "main", "commit": "87c204040e3f5d4c1c95067b35905d8f8a2f2545" }, + "asyncrun.vim": { "branch": "master", "commit": "61cc3081963a12048e00e89f8cedc8bd1cb83b8c" }, + "bigfile.nvim": { "branch": "main", "commit": "c1bad34ce742b4f360b67ca23c873fef998240fc" }, + "bufferline.nvim": { "branch": "main", "commit": "a4bd44523316928a7c4a5c09a3407d02c30b6027" }, + "cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" }, + "cmp-nvim-lsp": { "branch": "main", "commit": "0e6b2ed705ddcff9738ec4ea838141654f12eeef" }, + "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" }, + "cmp-tabnine": { "branch": "main", "commit": "b93f82ef5150e578677fc2e2b4b328b19eed77e1" }, + "cmp-vimtex": { "branch": "master", "commit": "50da2d9baeca3e9efb9ca9d90f68c7cc01377bc2" }, + "cmp_luasnip": { "branch": "master", "commit": "18095520391186d634a0045dacaa346291096566" }, + "dressing.nvim": { "branch": "master", "commit": "94b0d24483d56f3777ee0c8dc51675f21709318c" }, + "friendly-snippets": { "branch": "main", "commit": "631f79e346b0b3203d2ce3eae619ca8d612e5463" }, + "gitsigns.nvim": { "branch": "main", "commit": "e5edefd9976039f5352e0c900f35206770b33a2d" }, + "indent-blankline.nvim": { "branch": "master", "commit": "018bd04d80c9a73d399c1061fa0c3b14a7614399" }, + "lazy.nvim": { "branch": "main", "commit": "d6a782c7002682f4a01b79fc3918c4584ad6e8fb" }, + "lir.nvim": { "branch": "master", "commit": "1aa871f20637eccc4e1e26b0fbcf9aafc9b6caf7" }, + "lualine.nvim": { "branch": "master", "commit": "84ffb80e452d95e2c46fa29a98ea11a240f7843e" }, + "lunar.nvim": { "branch": "master", "commit": "08bbc93b96ad698d22fc2aa01805786bcedc34b9" }, + "markdown-preview.nvim": { "branch": "master", "commit": "a923f5fc5ba36a3b17e289dc35dc17f66d0548ee" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "7276ffffcf51a8304b5fd4b81293be4ee010ec47" }, + "mason.nvim": { "branch": "main", "commit": "057ac5ca159c83e302a55bd839a96ff1ea2396db" }, + "mini.map": { "branch": "stable", "commit": "85c8ebdca96ae139ed70dde149c66e9d4100d5bb" }, + "modus-theme-vim": { "branch": "master", "commit": "4d827fbf1aad55f4d62225f7b999efc5023864a3" }, + "neodev.nvim": { "branch": "main", "commit": "0043cf91c18aeac8db5765eb86c6078e17ac9325" }, + "neoscroll.nvim": { "branch": "master", "commit": "be4ebf855a52f71ca4338694a5696675d807eff9" }, + "neotest": { "branch": "master", "commit": "1ee3fcc150207f33dba8c9b3f478e5a0148d661d" }, + "neotest-python": { "branch": "master", "commit": "86ac2bbc8a4da3f203e56d9303d6ed1d7e50c1f6" }, + "nlsp-settings.nvim": { "branch": "main", "commit": "32aa12da328258f2dccb15d327c26a8d21d9f4bd" }, + "nui.nvim": { "branch": "main", "commit": "35da9ca1de0fc4dda96c2e214d93d363c145f418" }, + "null-ls.nvim": { "branch": "main", "commit": "33b853a3933eed3137cd055aac4e539e69832ad0" }, + "nvim-autopairs": { "branch": "master", "commit": "7566a86f44bb72ba2b1a609f528a27d93241502d" }, + "nvim-cmp": { "branch": "main", "commit": "11102d3db12c7f8b35265ad0e17a21511e5b1e68" }, + "nvim-colorizer.lua": { "branch": "master", "commit": "36c610a9717cc9ec426a07c8e6bf3b3abcb139d6" }, + "nvim-dap": { "branch": "master", "commit": "6cedcb527e264c8f25e86afa8dae74c6692dee51" }, + "nvim-dap-python": { "branch": "master", "commit": "091e4ae00a12085f9ed4200a3cd04af7179b8a23" }, + "nvim-dap-ui": { "branch": "master", "commit": "286f682f366fbc652b38dff893569374e9433dd3" }, + "nvim-lspconfig": { "branch": "master", "commit": "427378a03ffc1e1bc023275583a49b1993e524d0" }, + "nvim-navic": { "branch": "master", "commit": "83dc174da915f9dbc9b51169e9b62a2e0d42b527" }, + "nvim-treesitter": { "branch": "master", "commit": "2ce3c9080cfe4a39c7907e672edafd2a95244a7c" }, + "nvim-ts-context-commentstring": { "branch": "main", "commit": "0bf8fbc2ca8f8cdb6efbd0a9e32740d7a991e4c3" }, + "nvim-ts-rainbow": { "branch": "master", "commit": "8312b513ce930e7669a1721befbe56f2e1853301" }, + "nvim-web-devicons": { "branch": "master", "commit": "986875b7364095d6535e28bd4aac3a9357e91bbe" }, + "onedarker.nvim": { "branch": "freeze", "commit": "b00dd2189f264c5aeb4cf04c59439655ecd573ec" }, + "onedarkpro.nvim": { "branch": "main", "commit": "44badbaa1c4408679adc6b6979b669540db3fb46" }, + "papercolor-theme": { "branch": "master", "commit": "9051480ad9129ff4ab4fffb38b44779b9081626f" }, + "plenary.nvim": { "branch": "master", "commit": "9ac3e9541bbabd9d73663d757e4fe48a675bb054" }, + "project.nvim": { "branch": "main", "commit": "8c6bad7d22eef1b71144b401c9f74ed01526a4fb" }, + "rnvimr": { "branch": "main", "commit": "5f0483d1c107ab1fe7e0af08cdf7900aa0dcb40e" }, + "schemastore.nvim": { "branch": "main", "commit": "0b396f538f195c249f021a48c3d8988f0d3f86f7" }, + "structlog.nvim": { "branch": "main", "commit": "45b26a2b1036bb93c0e83f4225e85ab3cee8f476" }, + "suda.vim": { "branch": "master", "commit": "8b0fc3711760195aba104e2d190cff9af8267052" }, + "swenv.nvim": { "branch": "main", "commit": "87216f6ed7886a8cbd2b8fede1ccbdb2c91733c2" }, + "telescope-fzf-native.nvim": { "branch": "main", "commit": "580b6c48651cabb63455e97d7e131ed557b8c7e2" }, + "telescope.nvim": { "branch": "0.1.x", "commit": "9de317bdea2bc393074651179c4fc7f93e9b2d56" }, + "tex-conceal.vim": { "branch": "master", "commit": "93ae39d9222b0892684d02324b85ee9d3647bf8e" }, + "toggleterm.nvim": { "branch": "main", "commit": "68fdf851c2b7901a7065ff129b77d3483419ddce" }, + "tokyonight.nvim": { "branch": "main", "commit": "c5df636ce62a8aab7565f35da143cfd672526302" }, + "trouble.nvim": { "branch": "main", "commit": "f1168feada93c0154ede4d1fe9183bf69bac54ea" }, + "vim-abolish": { "branch": "master", "commit": "dcbfe065297d31823561ba787f51056c147aa682" }, + "vim-gitignore": { "branch": "master", "commit": "47e85aec1a87715981b5aec96c46fb408863804b" }, + "vim-grammalecte": { "branch": "master", "commit": "a0ce51a77e56151f62ddbfd10e7dec46000f2848" }, + "vim-header": { "branch": "master", "commit": "4447b601dd2439586a6d3ff4c3fefec86a522294" }, + "vim-illuminate": { "branch": "master", "commit": "a2907275a6899c570d16e95b9db5fd921c167502" }, + "vim-repeat": { "branch": "master", "commit": "24afe922e6a05891756ecf331f39a1f6743d3d5a" }, + "vim-surround": { "branch": "master", "commit": "3d188ed2113431cf8dac77be61b842acb64433d9" }, + "vimtex": { "branch": "master", "commit": "f9b19d09ee6f0ba70dad0b5c2e710dd700681000" }, + "which-key.nvim": { "branch": "main", "commit": "4acffc92953a90a790603bfdab7c92319ab167b1" }, + "zk-nvim": { "branch": "main", "commit": "fb0962b75a680561f94cae0588b8da92ea8d2fae" } +} \ No newline at end of file diff --git a/dot_config/lvim/lua/.keep b/dot_config/lvim/lua/.keep new file mode 100644 index 0000000..e69de29 diff --git a/dot_config/lvim/luasnippets/.keep b/dot_config/lvim/luasnippets/.keep new file mode 100644 index 0000000..e69de29