From 2f7af27c28a68d633f736d3281ed5a6041624c31 Mon Sep 17 00:00:00 2001 From: delta Date: Sun, 27 Aug 2023 20:50:32 +0200 Subject: add nvim config Signed-off-by: delta --- .config/nvim/lua/options.lua | 23 ++++++++++++ .config/nvim/lua/plugins.lua | 83 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 106 insertions(+) create mode 100644 .config/nvim/lua/options.lua create mode 100644 .config/nvim/lua/plugins.lua (limited to '.config/nvim/lua') diff --git a/.config/nvim/lua/options.lua b/.config/nvim/lua/options.lua new file mode 100644 index 0000000..94ded94 --- /dev/null +++ b/.config/nvim/lua/options.lua @@ -0,0 +1,23 @@ +local o = vim.o +local opt = vim.opt +local wo = vim.wo +local bo = vim.bo + +-- Global options -- +o.smarttab = true +o.clipboard = "unnamedplus" +o.termguicolors = 24 +o.list = true +opt.listchars = { space = "⋅", tab = " " } +o.autochdir = true + +-- Window options -- +wo.number = true +wo.relativenumber = true + +-- Buffer options -- +bo.expandtab = true +bo.tabstop = 4 +bo.smartindent = true +--bo.softtabstop = 0 +bo.shiftwidth = 2 diff --git a/.config/nvim/lua/plugins.lua b/.config/nvim/lua/plugins.lua new file mode 100644 index 0000000..7cc8321 --- /dev/null +++ b/.config/nvim/lua/plugins.lua @@ -0,0 +1,83 @@ +return { + { "echasnovski/mini.move", config = true }, + -- QoL + { "max397574/better-escape.nvim", config = true }, + + { "nvim-treesitter/nvim-treesitter", build = ":TSUpdate" }, + + -- UI + { + "lukas-reineke/indent-blankline.nvim", + config = true + }, + { + "folke/noice.nvim", + event = "VeryLazy", + opts = { + lsp = { + -- override markdown rendering so that **cmp** and other plugins use **Treesitter** + override = { + ["vim.lsp.util.convert_input_to_markdown_lines"] = true, + ["vim.lsp.util.stylize_markdown"] = true, + ["cmp.entry.get_documentation"] = true, + }, + }, + -- you can enable a preset for easier configuration + presets = { + -- bottom_search = true, -- use a classic bottom cmdline for search + command_palette = true, -- position the cmdline and popupmenu together + long_message_to_split = true, -- long messages will be sent to a split + inc_rename = false, -- enables an input dialog for inc-rename.nvim + lsp_doc_border = false, -- add a border to hover docs and signature help + }, + }, + dependencies = { + "MunifTanjim/nui.nvim", + }, + }, + { + "nvim-telescope/telescope.nvim", + config = true, + dependencies = { "nvim-lua/plenary.nvim" } + }, + { + "nvim-lualine/lualine.nvim", + opts = { + options = { + section_separators = { left = " ", right = " " }, + }, + sections = { + lualine_a = { "mode" }, + lualine_b = { "filename" }, + lualine_c = {}, + lualine_x = { "filetype" }, + lualine_y = { "progress" }, + lualine_z = { "location" }, + }, + }, + }, + { "stevearc/dressing.nvim", config = true }, + { + "folke/tokyonight.nvim", + lazy = false, + priority = 1000, + config = function() + vim.cmd [[colorscheme tokyonight-night]] + end, + }, + { + "nvim-neo-tree/neo-tree.nvim", + dependencies = { + "nvim-lua/plenary.nvim", + "nvim-tree/nvim-web-devicons", -- not strictly required, but recommended + "MunifTanjim/nui.nvim", + }, + }, + { + "goolord/alpha-nvim", + dependencies = { "nvim-tree/nvim-web-devicons" }, + config = function() + require("alpha").setup(require("alpha.themes.dashboard").config) + end, + }, +} -- cgit v1.2.3