This commit is contained in:
sankalp committed 2024-08-12 19:25:14 +05:45
1 parent 170ae42bea
commit deb9bcea46
12 files changed
+227

No files matched your search

+10
View File
@@ -0,0 +1,10 @@
vim.keymap.set('n', '<C-n>', ':Neotree filesystem reveal left toggle<CR>')
vim.keymap.set('n', '<leader>ff', ':Telescope find_files<CR>')
vim.keymap.set('n', '<leader>tc', ':Telescope colorscheme<CR>')
vim.keymap.set('n', '<leader>of', ':Telescope oldfiles<CR>')
vim.keymap.set('n', '<leader>tl', ':Telescope live_grep<CR>')
vim.keymap.set('n', '<leader>km', ':Telescope keymaps<CR>')
vim.keymap.set('n', '<leader>ft', vim.lsp.buf.format, {})
+1
View File
@@ -0,0 +1 @@
return {}
+8
View File
@@ -0,0 +1,8 @@
return {
'altermo/ultimate-autopair.nvim',
event = { 'InsertEnter', 'CmdlineEnter' },
branch = 'v0.6', --recommended as each new version will have breaking changes
opts = {
--Config goes here
},
}
+27
View File
@@ -0,0 +1,27 @@
return {
'navarasu/onedark.nvim',
config = function()
require('onedark').setup({
style = 'deep',
transparent = true,
term_colors = false,
ending_tildes = false,
cmp_itemkind_reverse = false,
-- toggle_style_key = '<leader>ot',
-- toggle_style_list = { 'dark', 'darker', 'cool', 'warm', 'warmer', 'deep', 'light' },
-- Options are italic, bold, underline, none and combos 'italic,bold'
code_style = {
comments = 'italic',
keywords = 'none',
functions = 'none',
strings = 'none',
variables = 'none',
},
lualine = { transparent = true },
diagnostics = { darker = true, undercurl = true, background = false },
})
end,
}
+62
View File
@@ -0,0 +1,62 @@
return {
{
'hrsh7th/cmp-nvim-lsp',
},
{
'hrsh7th/nvim-cmp',
dependencies = {
'saadparwaiz1/cmp_luasnip',
'L3MON4D3/LuaSnip',
'rafamadriz/friendly-snippets',
'onsails/lspkind.nvim',
},
config = function()
local cmp = require('cmp')
local lspkind = require('lspkind')
cmp.setup({
snippet = {
expand = function(args)
require('luasnip').lsp_expand(args.body) -- For `luasnip` users.
require('luasnip.loaders.from_vscode').lazy_load()
end,
},
window = {
completion = cmp.config.window.bordered(),
documentation = cmp.config.window.bordered(),
},
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 }), -- Accept currently selected item. Set `select` to `false` to only confirm explicitly selected items.
}),
sources = cmp.config.sources({
{ name = 'nvim_lsp' },
{ name = 'luasnip' }, -- For luasnip users.
}, {
{ name = 'buffer' },
}),
formatting = {
format = lspkind.cmp_format({
mode = 'symbol', -- show only symbol annotations
maxwidth = 50, -- prevent the popup from showing more than provided characters (e.g 50 will not show more than 50 characters)
-- can also be a function to dynamically calculate max width such as
-- maxwidth = function() return math.floor(0.45 * vim.o.columns) end,
ellipsis_char = '...', -- when popup menu exceed maxwidth, the truncated part would show ellipsis_char instead (must define maxwidth first)
show_labelDetails = true, -- show labelDetails in menu. Disabled by default
-- The function below will be called before any actual modifications from lspkind
-- so that you can provide more controls on popup customization. (See [#30](https://github.com/onsails/lspkind-nvim/pull/30))
before = function(entry, vim_item)
return vim_item
end,
}),
},
})
end,
},
}
+29
View File
@@ -0,0 +1,29 @@
return {
{
'williamboman/mason.nvim',
config = function()
require('mason').setup()
end,
},
{
'neovim/nvim-lspconfig',
config = function()
local lspconfig = require('lspconfig')
local capabilities = require('cmp_nvim_lsp').default_capabilities()
lspconfig.lua_ls.setup({
settings = {
Lua = {
diagnostics = {
globals = { 'vim' },
},
},
},
capabilities = capabilities,
})
end,
},
}
+9
View File
@@ -0,0 +1,9 @@
return {
'nvim-neo-tree/neo-tree.nvim',
branch = 'v3.x',
dependencies = {
'nvim-lua/plenary.nvim',
'nvim-tree/nvim-web-devicons',
'MunifTanjim/nui.nvim',
},
}
+13
View File
@@ -0,0 +1,13 @@
return {
'nvimtools/none-ls.nvim',
config = function()
local null_ls = require('null-ls')
null_ls.setup({
sources = {
null_ls.builtins.formatting.stylua,
},
})
end,
}
+13
View File
@@ -0,0 +1,13 @@
return {
'nvim-telescope/telescope.nvim',
tag = '0.1.8',
dependencies = { 'nvim-lua/plenary.nvim' },
config = function()
require('telescope').setup({
pickers = {
colorscheme = { enable_preview = true },
},
})
end,
}
+8
View File
@@ -0,0 +1,8 @@
vim.cmd([[autocmd FileType * set formatoptions-=ro]])
vim.cmd('set number')
vim.cmd('set relativenumber')
vim.cmd('set noexpandtab')
vim.cmd('set tabstop=6')
vim.cmd('set shiftwidth=6')
vim.cmd('set nowrap')