aboutsummaryrefslogtreecommitdiff
path: root/.config/nvim/lua
diff options
context:
space:
mode:
authorawy <awy@awy.one>2024-11-24 21:59:54 +0300
committerawy <awy@awy.one>2024-11-24 21:59:54 +0300
commit13fbd5bc4ecf15e8d9b9578e03f83669f218ee32 (patch)
tree2716c11b36383c02a155dd667c7fa59ae698a350 /.config/nvim/lua
parent534aa3ce4c7c35d8f5e325ba27ec8803488a41f3 (diff)
neovim cfg
Diffstat (limited to '.config/nvim/lua')
-rw-r--r--.config/nvim/lua/plugins.lua1
-rw-r--r--.config/nvim/lua/plugins/gruvbox.lua10
-rw-r--r--.config/nvim/lua/plugins/lsp-config.lua28
-rw-r--r--.config/nvim/lua/plugins/lualine.lua11
-rw-r--r--.config/nvim/lua/plugins/neo-tree.lua12
-rw-r--r--.config/nvim/lua/plugins/telescope.lua9
-rw-r--r--.config/nvim/lua/plugins/treesitter.lua11
-rw-r--r--.config/nvim/lua/vim-options.lua4
8 files changed, 86 insertions, 0 deletions
diff --git a/.config/nvim/lua/plugins.lua b/.config/nvim/lua/plugins.lua
new file mode 100644
index 0000000..a564707
--- /dev/null
+++ b/.config/nvim/lua/plugins.lua
@@ -0,0 +1 @@
+return {}
diff --git a/.config/nvim/lua/plugins/gruvbox.lua b/.config/nvim/lua/plugins/gruvbox.lua
new file mode 100644
index 0000000..547af2c
--- /dev/null
+++ b/.config/nvim/lua/plugins/gruvbox.lua
@@ -0,0 +1,10 @@
+return {
+ "ellisonleao/gruvbox.nvim",
+ priority = 1000 ,
+ config = function()
+ require("gruvbox").setup({
+ transparent_mode = true,
+ })
+ vim.cmd.colorscheme "gruvbox"
+ end
+}
diff --git a/.config/nvim/lua/plugins/lsp-config.lua b/.config/nvim/lua/plugins/lsp-config.lua
new file mode 100644
index 0000000..7178d3e
--- /dev/null
+++ b/.config/nvim/lua/plugins/lsp-config.lua
@@ -0,0 +1,28 @@
+return {
+ {
+ "williamboman/mason.nvim",
+ config = function()
+ require("mason").setup()
+ end
+ },
+ {
+ "williamboman/mason-lspconfig.nvim",
+ config = function()
+ require("mason-lspconfig").setup({
+ ensure_installed = { "lua_ls", "clangd", "html", "cssls" }
+ })
+ end
+ },
+ {
+ "neovim/nvim-lspconfig",
+ config = function()
+ local lspconfig = require("lspconfig")
+ local capabilities = vim.lsp.protocol.make_client_capabilities()
+ capabilities.textDocument.completion.completionItem.snippetSupport = true
+ lspconfig.lua_ls.setup({})
+ lspconfig.clangd.setup({})
+ lspconfig.html.setup({capabilities = capabilities,})
+ lspconfig.cssls.setup({capabilities = capabilities,})
+ end
+ }
+}
diff --git a/.config/nvim/lua/plugins/lualine.lua b/.config/nvim/lua/plugins/lualine.lua
new file mode 100644
index 0000000..a8235ae
--- /dev/null
+++ b/.config/nvim/lua/plugins/lualine.lua
@@ -0,0 +1,11 @@
+return {
+ 'nvim-lualine/lualine.nvim',
+ dependencies = { 'nvim-tree/nvim-web-devicons' },
+ config = function()
+ require('lualine').setup({
+ options = {
+ theme = 'gruvbox_dark'
+ }
+ })
+ end
+}
diff --git a/.config/nvim/lua/plugins/neo-tree.lua b/.config/nvim/lua/plugins/neo-tree.lua
new file mode 100644
index 0000000..65f280d
--- /dev/null
+++ b/.config/nvim/lua/plugins/neo-tree.lua
@@ -0,0 +1,12 @@
+return {
+ "nvim-neo-tree/neo-tree.nvim",
+ branch = "v3.x",
+ dependencies = {
+ "nvim-lua/plenary.nvim",
+ "nvim-tree/nvim-web-devicons", -- not strictly required, but recommended
+ "MunifTanjim/nui.nvim",
+ },
+ config = function()
+ vim.keymap.set('n', '<C-n>', ':Neotree filesystem reveal left<CR>', {})
+ end
+}
diff --git a/.config/nvim/lua/plugins/telescope.lua b/.config/nvim/lua/plugins/telescope.lua
new file mode 100644
index 0000000..c646155
--- /dev/null
+++ b/.config/nvim/lua/plugins/telescope.lua
@@ -0,0 +1,9 @@
+return {
+ 'nvim-telescope/telescope.nvim', tag = '0.1.8',
+ dependencies = { 'nvim-lua/plenary.nvim' },
+ config = function()
+ local builtin = require("telescope.builtin")
+ vim.keymap.set('n', '<C-p>', builtin.find_files, {})
+ vim.keymap.set('n', '<leader>fg', builtin.live_grep, {})
+ end
+}
diff --git a/.config/nvim/lua/plugins/treesitter.lua b/.config/nvim/lua/plugins/treesitter.lua
new file mode 100644
index 0000000..0e5b9fe
--- /dev/null
+++ b/.config/nvim/lua/plugins/treesitter.lua
@@ -0,0 +1,11 @@
+return {"nvim-treesitter/nvim-treesitter",
+ build = ":TSUpdate",
+ config = function()
+ local config = require("nvim-treesitter.configs")
+ config.setup({
+ ensure_installed = { "c", "lua", "html", "css" },
+ highlight = { enable = true },
+ indent = { enable = true },
+ })
+ end
+}
diff --git a/.config/nvim/lua/vim-options.lua b/.config/nvim/lua/vim-options.lua
new file mode 100644
index 0000000..8068602
--- /dev/null
+++ b/.config/nvim/lua/vim-options.lua
@@ -0,0 +1,4 @@
+vim.cmd("set title")
+vim.cmd("set clipboard+=unnamedplus")
+vim.cmd("set relativenumber")
+vim.g.mapleader = " "