diff --git a/nvim/lazy-lock.json b/nvim/lazy-lock.json new file mode 100644 index 0000000..5ad198c --- /dev/null +++ b/nvim/lazy-lock.json @@ -0,0 +1,14 @@ +{ + "catppuccin": { "branch": "main", "commit": "5e36ca599f4aa41bdd87fbf2c5aae4397ac55074" }, + "lazy.nvim": { "branch": "main", "commit": "96584866b9c5e998cbae300594d0ccfd0c464627" }, + "lualine.nvim": { "branch": "master", "commit": "566b7036f717f3d676362742630518a47f132fff" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "0989bdf4fdf7b5aa4c74131d7ffccc3f399ac788" }, + "mason.nvim": { "branch": "main", "commit": "e110bc3be1a7309617cecd77bfe4bf86ba1b8134" }, + "neo-tree.nvim": { "branch": "v3.x", "commit": "77d9f484b88fd380386b46ed9206e5374d69d9d8" }, + "nui.nvim": { "branch": "main", "commit": "35da9ca1de0fc4dda96c2e214d93d363c145f418" }, + "nvim-lspconfig": { "branch": "master", "commit": "796394fd19fb878e8dbc4fd1e9c9c186ed07a5f4" }, + "nvim-web-devicons": { "branch": "master", "commit": "db0c864375c198cacc171ff373e76bfce2a85045" }, + "plenary.nvim": { "branch": "master", "commit": "55d9fe89e33efd26f532ef20223e5f9430c8b0c0" }, + "telescope-ui-select.nvim": { "branch": "master", "commit": "6e51d7da30bd139a6950adf2a47fda6df9fa06d2" }, + "telescope.nvim": { "branch": "master", "commit": "d90956833d7c27e73c621a61f20b29fdb7122709" } +} \ No newline at end of file diff --git a/nvim/lua/plugins/lsp-config.lua b/nvim/lua/plugins/lsp-config.lua new file mode 100644 index 0000000..8036f07 --- /dev/null +++ b/nvim/lua/plugins/lsp-config.lua @@ -0,0 +1,36 @@ +return +{ + { + "williamboman/mason.nvim", + config = function() + require("mason").setup({ + path = "append", + ui = { + icons = { + package_installed = "✓", + package_pending = "➜", + package_uninstalled = "✗" + } + } + }) + end + }, + { + "williamboman/mason-lspconfig.nvim", + config = function() + require("mason-lspconfig").setup { + ensure_installed = { "lua_ls" }, + } + end + }, + { + "neovim/nvim-lspconfig", + config = function() + local lspconfig = require("lspconfig") + lspconfig.lua_ls.setup({}) + vim.keymap.set('n', 'K', vim.lsp.buf.hover, {}) + vim.keymap.set('n', 'gd', vim.lsp.buf.definition, {}) + vim.keymap.set({'n', 'v'}, 'ca', vim.lsp.buf.code_action, {}) + end + } +} diff --git a/nvim/lua/plugins/telescope.lua b/nvim/lua/plugins/telescope.lua index afde4ce..636ae0c 100644 --- a/nvim/lua/plugins/telescope.lua +++ b/nvim/lua/plugins/telescope.lua @@ -1,10 +1,28 @@ return { - 'nvim-telescope/telescope.nvim', tag = '0.1.5', - dependencies = { 'nvim-lua/plenary.nvim' }, - config = function() - local builtin = require("telescope.builtin") - vim.keymap.set('n', '', builtin.find_files, {}) - vim.keymap.set('n', '', builtin.live_grep, {}) - end -} + { + 'nvim-telescope/telescope.nvim', tag = '0.1.5', + dependencies = { 'nvim-lua/plenary.nvim' }, + config = function() + local builtin = require("telescope.builtin") + vim.keymap.set('n', '', builtin.find_files, {}) + vim.keymap.set('n', '', builtin.live_grep, {}) + end + }, + { + 'nvim-telescope/telescope-ui-select.nvim', + config = function() + require("telescope").setup { + extensions = { + ["ui-select"] = { + require("telescope.themes").get_dropdown { + } + } + } + } + -- To get ui-select loaded and working with telescope, you need to call + -- load_extension, somewhere after setup function: + require("telescope").load_extension("ui-select") + end + } +} diff --git a/nvim/lua/plugins/treesitter.lua b/nvim/lua/plugins/treesitter.lua index 90d5b9a..fb40e2e 100644 --- a/nvim/lua/plugins/treesitter.lua +++ b/nvim/lua/plugins/treesitter.lua @@ -1,20 +1,20 @@ return { - "nvim-treesitter/nvim-treesitter", - build = ":TSUpdate", - config = function() - local install = require("nvim-treesitter.install") - local configs = require("nvim-treesitter.configs") + -- "nvim-treesitter/nvim-treesitter", + -- build = ":TSUpdate", + -- config = function() + -- local install = require("nvim-treesitter.install") + -- local configs = require("nvim-treesitter.configs") - install = { - compilers = { clang }, - prefer_git = false, - } + -- install = { + -- compilers = { clang }, + -- prefer_git = false, + -- } - configs.setup({ - ensure_installed = { "c", "cpp", "lua", "vim", "vimdoc", "cmake", "query" }, - sync_install = false, - highlight = { enable = true }, - indent = { enable = true }, - }) - end + -- configs.setup({ + -- ensure_installed = { "c", "cpp", "lua", "vim", "vimdoc", "cmake", "query" }, + -- sync_install = false, + -- highlight = { enable = true }, + -- indent = { enable = true }, + -- }) + -- end } diff --git a/nvim/lua/settings.lua b/nvim/lua/settings.lua index f72e696..5002474 100644 --- a/nvim/lua/settings.lua +++ b/nvim/lua/settings.lua @@ -1,7 +1,9 @@ +vim.cmd("syntax on") vim.cmd("set expandtab") vim.cmd("set tabstop=4") vim.cmd("set softtabstop=4") vim.cmd("set shiftwidth=4") +vim.cmd("set nu") vim.g.mapleader = " "