summaryrefslogtreecommitdiffstats
path: root/lua/Nanderty/Plugins
diff options
context:
space:
mode:
Diffstat (limited to 'lua/Nanderty/Plugins')
-rw-r--r--lua/Nanderty/Plugins/bufferline.lua2
-rw-r--r--lua/Nanderty/Plugins/cmp.lua60
-rw-r--r--lua/Nanderty/Plugins/lualine.lua5
-rw-r--r--lua/Nanderty/Plugins/startify.lua0
-rw-r--r--lua/Nanderty/Plugins/telescope.lua6
-rw-r--r--lua/Nanderty/Plugins/treesitter.lua13
-rw-r--r--lua/Nanderty/Plugins/vimtex.lua5
7 files changed, 91 insertions, 0 deletions
diff --git a/lua/Nanderty/Plugins/bufferline.lua b/lua/Nanderty/Plugins/bufferline.lua
new file mode 100644
index 0000000..c5accc7
--- /dev/null
+++ b/lua/Nanderty/Plugins/bufferline.lua
@@ -0,0 +1,2 @@
+vim.opt.termguicolors = true
+require("bufferline").setup{}
diff --git a/lua/Nanderty/Plugins/cmp.lua b/lua/Nanderty/Plugins/cmp.lua
new file mode 100644
index 0000000..2c73b05
--- /dev/null
+++ b/lua/Nanderty/Plugins/cmp.lua
@@ -0,0 +1,60 @@
+require('mason').setup()
+
+require('mason-lspconfig').setup({
+ ensure_installed = {
+ }
+})
+
+local lsp_capabilities = require('cmp_nvim_lsp').default_capabilities()
+local lsp_attach = function(client, bufnr)
+end
+
+local lspconfig = require('lspconfig')
+require('mason-lspconfig').setup_handlers({
+ function(server_name)
+ lspconfig[server_name].setup({
+ on_attach = lsp_attach,
+ capabilities = lsp_capabilities,
+ })
+ end,
+})
+
+local cmp = require'cmp'
+
+cmp.setup({
+ snippet = {
+ expand = function(args)
+ vim.fn["UltiSnips#Anon"](args.body)
+ end,
+ },
+ window = {
+ },
+ mapping = cmp.mapping.preset.insert({
+ ['<C-b>'] = cmp.mapping.scroll_docs(-4),
+ ['<C-f>'] = cmp.mapping.scroll_docs(4),
+ ['<C-Space>'] = cmp.mapping.complete(),
+ ['<C-e>'] = cmp.mapping.abort(),
+ ['<CR>'] = cmp.mapping.confirm({ select = true }),
+ }),
+ sources = cmp.config.sources({
+ { name = 'nvim_lsp' },
+ { name = 'ultisnips' },
+ { name = 'omni' },
+ { name = 'buffer' },
+ })
+})
+
+local lsp_capabilities = require('cmp_nvim_lsp').default_capabilities()
+local lsp_attach = function(client, bufnr)
+ -- Create your keybindings here...
+end
+
+local lspconfig = require('lspconfig')
+require('mason-lspconfig').setup_handlers({
+ function(server_name)
+ lspconfig[server_name].setup({
+ on_attach = lsp_attach,
+ capabilities = lsp_capabilities,
+ })
+ end,
+})
diff --git a/lua/Nanderty/Plugins/lualine.lua b/lua/Nanderty/Plugins/lualine.lua
new file mode 100644
index 0000000..5ace147
--- /dev/null
+++ b/lua/Nanderty/Plugins/lualine.lua
@@ -0,0 +1,5 @@
+require('lualine').setup {
+ options = {
+ theme = 'onedark'
+ }
+}
diff --git a/lua/Nanderty/Plugins/startify.lua b/lua/Nanderty/Plugins/startify.lua
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/lua/Nanderty/Plugins/startify.lua
diff --git a/lua/Nanderty/Plugins/telescope.lua b/lua/Nanderty/Plugins/telescope.lua
new file mode 100644
index 0000000..4806008
--- /dev/null
+++ b/lua/Nanderty/Plugins/telescope.lua
@@ -0,0 +1,6 @@
+local builtin = require('telescope.builtin')
+vim.keymap.set('n', '<leader>pf', builtin.find_files, {})
+vim.keymap.set('n', '<C-p>', builtin.git_files, {})
+vim.keymap.set('n', '<leader>ps', function()
+ builtin.grep_string({ search = vim.fn.input("Grep > ") });
+end)
diff --git a/lua/Nanderty/Plugins/treesitter.lua b/lua/Nanderty/Plugins/treesitter.lua
new file mode 100644
index 0000000..7baec80
--- /dev/null
+++ b/lua/Nanderty/Plugins/treesitter.lua
@@ -0,0 +1,13 @@
+require'nvim-treesitter.configs'.setup {
+ ensure_installed = {"help", "javascript", "html", "css", "python", "cpp", "c", "lua", "php",},
+
+ sync_install = false,
+
+ auto_install = true,
+
+
+ highlight = {
+ enable = true,
+
+ },
+}
diff --git a/lua/Nanderty/Plugins/vimtex.lua b/lua/Nanderty/Plugins/vimtex.lua
new file mode 100644
index 0000000..511c2bf
--- /dev/null
+++ b/lua/Nanderty/Plugins/vimtex.lua
@@ -0,0 +1,5 @@
+vim.g.tex_flavor='latex'
+vim.g.vimtex_view_mehtod = 'mupdf'
+vim.g.vimtex_quickfix_open_on_warning = 0
+
+vim.keymap.set('n', '<leader>ll', '<Cmd>VimtexCompile<CR>', {} )