backup
This commit is contained in:
parent
0121bf564e
commit
c8d0ff7f3a
|
@ -1,9 +1,9 @@
|
||||||
require('plugins')
|
require('plugins')
|
||||||
require('visuals')
|
require('visuals')
|
||||||
require('handling')
|
require('handling')
|
||||||
require('completion')
|
|
||||||
require('development')
|
require('development')
|
||||||
require('keybindings')
|
require('keybindings')
|
||||||
|
require('completion')
|
||||||
|
|
||||||
vim.opt.tabstop = 2
|
vim.opt.tabstop = 2
|
||||||
vim.opt.shiftwidth = 2
|
vim.opt.shiftwidth = 2
|
||||||
|
|
|
@ -1,26 +1,29 @@
|
||||||
local cmp = require("cmp")
|
local cmp = require("cmp")
|
||||||
cmp.setup({
|
cmp.setup({
|
||||||
snippet = {
|
snippet = {
|
||||||
-- REQUIRED - you must specify a snippet engine
|
|
||||||
expand = function(args)
|
expand = function(args)
|
||||||
require('luasnip').lsp_expand(args.body) -- For `luasnip` users.
|
require('luasnip').lsp_expand(args.body) -- For `luasnip` users.
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
window = {
|
window = {
|
||||||
-- completion = cmp.config.window.bordered(),
|
completion = cmp.config.window.bordered(),
|
||||||
-- documentation = cmp.config.window.bordered(),
|
documentation = cmp.config.window.bordered(),
|
||||||
},
|
},
|
||||||
mapping = cmp.mapping.preset.insert({
|
mapping = cmp.mapping.preset.insert({
|
||||||
['<C-b>'] = cmp.mapping.scroll_docs(-4),
|
['<C-b>'] = cmp.mapping.scroll_docs(-4),
|
||||||
['<C-f>'] = cmp.mapping.scroll_docs(4),
|
['<C-f>'] = cmp.mapping.scroll_docs(4),
|
||||||
['<C-Space>'] = cmp.mapping.complete(),
|
['<C-Space>'] = cmp.mapping.complete(),
|
||||||
['<C-e>'] = cmp.mapping.abort(),
|
['<C-e>'] = cmp.mapping.abort(),
|
||||||
['<CR>'] = cmp.mapping.confirm({ select = true }),
|
['<CR>'] = cmp.mapping.confirm({ select = true, behavior = cmp.ConfirmBehavior.Replace }),
|
||||||
}),
|
}),
|
||||||
sources = cmp.config.sources({
|
sources = cmp.config.sources({
|
||||||
{ name = 'copilot', group_index = 2 },
|
{ name = 'copilot', group_index = 2 },
|
||||||
{ name = 'nvim_lsp', group_index = 2 },
|
{ name = 'nvim_lsp', group_index = 2 },
|
||||||
}, {
|
{ name = 'luasnip', group_index = 2 },
|
||||||
|
},{
|
||||||
{ name = 'buffer' },
|
{ name = 'buffer' },
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
|
require('copilot').setup()
|
||||||
|
require('copilot_cmp').setup()
|
||||||
|
|
|
@ -1,9 +1,10 @@
|
||||||
local capabilities = vim.lsp.protocol.make_client_capabilities()
|
local capabilities = vim.lsp.protocol.make_client_capabilities()
|
||||||
capabilities = require('cmp_nvim_lsp').update_capabilities(capabilities)
|
capabilities = require('cmp_nvim_lsp').default_capabilities(capabilities)
|
||||||
|
|
||||||
require'lspconfig'.pyright.setup{
|
require('lspconfig').pyright.setup{
|
||||||
capabilities = capabilities,
|
capabilities = capabilities,
|
||||||
}
|
}
|
||||||
|
require('lspconfig').tsserver.setup {}
|
||||||
|
|
||||||
require('dap-python').setup('~/.local/share/virtualenvs/debugpy/bin/python')
|
require('dap-python').setup('~/.local/share/virtualenvs/debugpy/bin/python')
|
||||||
require('dap-python').test_runner = 'pytest'
|
require('dap-python').test_runner = 'pytest'
|
||||||
|
@ -58,3 +59,37 @@ require("coverage").setup({
|
||||||
-- customize language specific settings
|
-- customize language specific settings
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
require("rest-nvim").setup({
|
||||||
|
-- Open request results in a horizontal split
|
||||||
|
result_split_horizontal = false,
|
||||||
|
-- Keep the http file buffer above|left when split horizontal|vertical
|
||||||
|
result_split_in_place = true,
|
||||||
|
-- Skip SSL verification, useful for unknown certificates
|
||||||
|
skip_ssl_verification = false,
|
||||||
|
-- Encode URL before making request
|
||||||
|
encode_url = true,
|
||||||
|
-- Highlight request on run
|
||||||
|
highlight = {
|
||||||
|
enabled = true,
|
||||||
|
timeout = 150,
|
||||||
|
},
|
||||||
|
result = {
|
||||||
|
-- toggle showing URL, HTTP info, headers at top the of result window
|
||||||
|
show_url = true,
|
||||||
|
show_http_info = true,
|
||||||
|
show_headers = true,
|
||||||
|
-- executables or functions for formatting response body [optional]
|
||||||
|
-- set them to false if you want to disable them
|
||||||
|
formatters = {
|
||||||
|
json = "jq",
|
||||||
|
html = function(body)
|
||||||
|
return vim.fn.system({"tidy", "-i", "-q", "-"}, body)
|
||||||
|
end
|
||||||
|
},
|
||||||
|
},
|
||||||
|
-- Jump to request line on run
|
||||||
|
jump_to_request = false,
|
||||||
|
env_file = '.env',
|
||||||
|
custom_dynamic_variables = {},
|
||||||
|
yank_dry_run = true,
|
||||||
|
})
|
||||||
|
|
|
@ -2,8 +2,8 @@ require('leap').set_default_keymaps()
|
||||||
require('litee.lib').setup()
|
require('litee.lib').setup()
|
||||||
require('litee.gh').setup()
|
require('litee.gh').setup()
|
||||||
|
|
||||||
require("toggleterm").setup{
|
require("toggleterm").setup {
|
||||||
size = 60,
|
size = 60,
|
||||||
direction = 'vertical',
|
direction = 'horizontal',
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -13,7 +13,7 @@ vim.api.nvim_set_keymap('n', '<M-2>',
|
||||||
|
|
||||||
--TESTING
|
--TESTING
|
||||||
vim.api.nvim_set_keymap('n', '<F10>',
|
vim.api.nvim_set_keymap('n', '<F10>',
|
||||||
"<cmd>lua require('neotest').output.open()<CR>",
|
"<cmd>lua require('neotest').output.open({enter=true, auto_close=true})<CR>",
|
||||||
{ noremap = true, silent = true }
|
{ noremap = true, silent = true }
|
||||||
)
|
)
|
||||||
vim.api.nvim_set_keymap('n', '<F58>',
|
vim.api.nvim_set_keymap('n', '<F58>',
|
||||||
|
@ -44,6 +44,11 @@ vim.api.nvim_set_keymap('n', '<F35>',
|
||||||
"<cmd>lua require('coverage').toggle()<CR>",
|
"<cmd>lua require('coverage').toggle()<CR>",
|
||||||
{ noremap = true, silent = true }
|
{ noremap = true, silent = true }
|
||||||
)
|
)
|
||||||
|
vim.api.nvim_set_keymap('n', '<F28>',
|
||||||
|
"<Plug>RestNvim<CR>",
|
||||||
|
{ noremap = true, silent = true }
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
--DEBUGGING
|
--DEBUGGING
|
||||||
|
@ -55,7 +60,7 @@ vim.api.nvim_set_keymap('n', '<F57>',
|
||||||
"<cmd>lua require('dapui').toggle()<CR>",
|
"<cmd>lua require('dapui').toggle()<CR>",
|
||||||
{ noremap = true, silent = true }
|
{ noremap = true, silent = true }
|
||||||
)
|
)
|
||||||
vim.api.nvim_set_keymap('n', '<F45>',
|
vim.api.nvim_set_keymap('n', '<F44>',
|
||||||
"<cmd>lua require('dap').continue()<CR>",
|
"<cmd>lua require('dap').continue()<CR>",
|
||||||
{ noremap = true, silent = true }
|
{ noremap = true, silent = true }
|
||||||
)
|
)
|
||||||
|
@ -87,7 +92,7 @@ vim.keymap.set("n", "<F5>", "<cmd>TroubleToggle document_diagnostics<cr>",
|
||||||
|
|
||||||
|
|
||||||
--TERMINAL BINDINGS
|
--TERMINAL BINDINGS
|
||||||
vim.api.nvim_set_keymap('n', '<F12>', "<cmd>ToggleTerm<CR>", { noremap = true, silent = true })
|
vim.api.nvim_set_keymap('n', '<F12>', "<cmd>ToggleTerm size=60<CR>", { noremap = true, silent = true })
|
||||||
vim.api.nvim_set_keymap('n', '<F36>', "<cmd>ToggleTermToggleAll<CR>", { noremap = true, silent = true })
|
vim.api.nvim_set_keymap('n', '<F36>', "<cmd>ToggleTermToggleAll<CR>", { noremap = true, silent = true })
|
||||||
vim.api.nvim_set_keymap('t', '<F12>', "<cmd>ToggleTermToggleAll<CR>", { noremap = true, silent = true })
|
vim.api.nvim_set_keymap('t', '<F12>', "<cmd>ToggleTermToggleAll<CR>", { noremap = true, silent = true })
|
||||||
vim.keymap.set('t', '<ESC>', "<C-\\><C-n>",
|
vim.keymap.set('t', '<ESC>', "<C-\\><C-n>",
|
||||||
|
@ -101,6 +106,10 @@ vim.api.nvim_set_keymap('t', '<C-L>', "<cmd>wincmd l<CR>", { noremap = true, sil
|
||||||
-- WHICH KEY
|
-- WHICH KEY
|
||||||
local wk = require("which-key")
|
local wk = require("which-key")
|
||||||
wk.register({
|
wk.register({
|
||||||
|
b = {
|
||||||
|
name = "+Buffer",
|
||||||
|
c = { "<cmd>w | %bd | e#<cr>", "Close All But this Buffer" }
|
||||||
|
},
|
||||||
g = {
|
g = {
|
||||||
name = "+Git",
|
name = "+Git",
|
||||||
h = {
|
h = {
|
||||||
|
|
|
@ -23,7 +23,7 @@ return require('packer').startup(function(use)
|
||||||
|
|
||||||
-- Handling
|
-- Handling
|
||||||
use {
|
use {
|
||||||
'nvim-telescope/telescope.nvim', tag = '0.1.0',
|
'nvim-telescope/telescope.nvim', tag = '0.1.1',
|
||||||
requires = { {'nvim-lua/plenary.nvim'} }
|
requires = { {'nvim-lua/plenary.nvim'} }
|
||||||
}
|
}
|
||||||
use 'ggandor/leap.nvim'
|
use 'ggandor/leap.nvim'
|
||||||
|
@ -41,33 +41,15 @@ return require('packer').startup(function(use)
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
}
|
}
|
||||||
use {
|
use 'akinsho/toggleterm.nvim'
|
||||||
"akinsho/toggleterm.nvim",
|
|
||||||
config = function()
|
|
||||||
require("toggleterm").setup{
|
|
||||||
size = 20,
|
|
||||||
direction = 'vertical',
|
|
||||||
}
|
|
||||||
end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Completion
|
-- Completion
|
||||||
use 'github/copilot.vim'
|
use 'github/copilot.vim'
|
||||||
use 'hrsh7th/nvim-cmp'
|
use 'hrsh7th/nvim-cmp'
|
||||||
use 'L3MON4D3/LuaSnip'
|
use 'L3MON4D3/LuaSnip'
|
||||||
use {
|
use 'saadparwaiz1/cmp_luasnip'
|
||||||
"zbirenbaum/copilot.lua",
|
use 'zbirenbaum/copilot.lua'
|
||||||
event = {"VimEnter"},
|
use 'zbirenbaum/copilot-cmp'
|
||||||
config = function()
|
|
||||||
vim.defer_fn(function()
|
|
||||||
require("copilot").setup()
|
|
||||||
end, 100)
|
|
||||||
end,
|
|
||||||
}
|
|
||||||
use {
|
|
||||||
"zbirenbaum/copilot-cmp",
|
|
||||||
module = "copilot_cmp",
|
|
||||||
}
|
|
||||||
use 'hrsh7th/cmp-nvim-lsp'
|
use 'hrsh7th/cmp-nvim-lsp'
|
||||||
|
|
||||||
-- Development
|
-- Development
|
||||||
|
@ -76,6 +58,10 @@ return require('packer').startup(function(use)
|
||||||
use 'mfussenegger/nvim-dap-python'
|
use 'mfussenegger/nvim-dap-python'
|
||||||
use 'rcarriga/nvim-dap-ui'
|
use 'rcarriga/nvim-dap-ui'
|
||||||
use 'theHamsta/nvim-dap-virtual-text'
|
use 'theHamsta/nvim-dap-virtual-text'
|
||||||
|
use {
|
||||||
|
'rest-nvim/rest.nvim',
|
||||||
|
requires = {'nvim-lua/plenary.nvim'}
|
||||||
|
}
|
||||||
use {
|
use {
|
||||||
"nvim-neotest/neotest",
|
"nvim-neotest/neotest",
|
||||||
requires = {
|
requires = {
|
||||||
|
@ -89,8 +75,5 @@ return require('packer').startup(function(use)
|
||||||
use({
|
use({
|
||||||
"andythigpen/nvim-coverage",
|
"andythigpen/nvim-coverage",
|
||||||
requires = "nvim-lua/plenary.nvim",
|
requires = "nvim-lua/plenary.nvim",
|
||||||
-- config = function()
|
|
||||||
-- require("user.coverage")
|
|
||||||
-- end,
|
|
||||||
})
|
})
|
||||||
end)
|
end)
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
vim.opt.termguicolors = true
|
vim.opt.termguicolors = true
|
||||||
vim.cmd[[colorscheme iceberg]]
|
--vim.cmd[[colorscheme iceberg]]
|
||||||
|
|
||||||
require('lualine').setup {
|
require('lualine').setup {
|
||||||
options = {
|
options = {
|
||||||
icons_enabled = true,
|
icons_enabled = true,
|
||||||
theme = 'iceberg_dark',
|
-- theme = 'iceberg_dark',
|
||||||
component_separators = { left = '', right = ''},
|
component_separators = { left = '', right = ''},
|
||||||
section_separators = { left = '', right = ''},
|
section_separators = { left = '', right = ''},
|
||||||
disabled_filetypes = {
|
disabled_filetypes = {
|
||||||
|
|
Loading…
Reference in New Issue