summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ftplugin/java.vim28
-rw-r--r--init.vim25
-rw-r--r--lua/lsp.lua21
3 files changed, 59 insertions, 15 deletions
diff --git a/ftplugin/java.vim b/ftplugin/java.vim
index 238ca22..8bf603c 100644
--- a/ftplugin/java.vim
+++ b/ftplugin/java.vim
@@ -1 +1,29 @@
setl textwidth=100
+
+inoreabbrev public public
+inoreabbrev upblic public
+inoreabbrev pbulic public
+inoreabbrev pbulci public
+inoreabbrev pulbic public
+inoreabbrev pubilc public
+inoreabbrev publci public
+
+inoreabbrev rpivate private
+inoreabbrev pirvate private
+inoreabbrev prviate private
+inoreabbrev priavte private
+inoreabbrev privtae private
+inoreabbrev privaet private
+inoreabbrev pirvaet private
+inoreabbrev priavet private
+inoreabbrev piravet private
+
+inoreabbrev tsatic static
+inoreabbrev sattic static
+inoreabbrev sttaic static
+inoreabbrev staitc static
+inoreabbrev statci static
+
+inoreabbrev ovid void
+inoreabbrev viod void
+inoreabbrev vodi void
diff --git a/init.vim b/init.vim
index 45bfeaf..5536a9a 100644
--- a/init.vim
+++ b/init.vim
@@ -45,8 +45,11 @@ Plug 'nvim-treesitter/nvim-treesitter-textobjects'
Plug 'stevearc/aerial.nvim'
Plug 'tpope/vim-surround'
+Plug 'nvim-lualine/lualine.nvim'
+Plug 'linrongbin16/lsp-progress.nvim'
Plug 'git://git.josher.dev/fieldmarshal.vim.git'
+Plug 'git://git.josher.dev/bulletjava.vim.git'
if has('rneovim')
Plug 'git://git.josher.dev/rneovim-userregs.git'
endif
@@ -185,6 +188,10 @@ command! TERM exec "term sh -c " . shellescape(printf("cd %s && exec ", shellesc
" W = w. I often click when typing :w
command! W w
+augroup lualine_augroup
+ autocmd!
+ autocmd User LspProgressStatusUpdated lua require("lualine").refresh()
+augroup END
lua << EOF
@@ -198,6 +205,14 @@ lua << EOF
-- CiderLSP
vim.opt.completeopt = { "menu", "menuone", "noselect" }
+ require("lualine").setup({
+ sections = {
+ lualine_a = { "mode" },
+ lualine_b = { "filename" },
+ lualine_c = {
+ }
+ }
+ })
require("lsp")
require("lspconfig")
@@ -226,14 +241,14 @@ lua << EOF
require('aerial').setup({
-- optionally use on_attach to set keymaps when aerial has attached to a buffer
on_attach = function(bufnr)
- -- Jump forwards/backwards with '{' and '}'
- vim.keymap.set('n', '{', '<cmd>AerialPrev<CR>', {buffer = bufnr})
- vim.keymap.set('n', '}', '<cmd>AerialNext<CR>', {buffer = bufnr})
+ -- Jump forwards/backwards with '[[' and ']]'
+ vim.keymap.set('n', '[[', '<cmd>AerialPrev<CR>', {buffer = bufnr})
+ vim.keymap.set('n', ']]', '<cmd>AerialNext<CR>', {buffer = bufnr})
end
})
--- You probably also want to set a keymap to toggle aerial
-vim.keymap.set('n', '<leader>a', '<cmd>AerialToggle!<CR>')
+ -- You probably also want to set a keymap to toggle aerial
+ vim.keymap.set('n', '<leader>a', '<cmd>AerialToggle!<CR>')
EOF
diff --git a/lua/lsp.lua b/lua/lsp.lua
index 27a8925..0902e06 100644
--- a/lua/lsp.lua
+++ b/lua/lsp.lua
@@ -88,18 +88,10 @@ cmp.setup({
["<C-e>"] = cmp.mapping.close(),
["<C-Space>"] = cmp.mapping(cmp.mapping.complete(), { "i", "c" }),
["<C-n>"] = cmp.mapping(function(fallback)
- if cmp.visible() then
- cmp.select_next_item()
- else
- fallback() -- The fallback function sends a already mapped key. In this case, it's probably `<Tab>`.
- end
+ cmp.select_next_item()
end, { "i", "s" }),
["<C-p>"] = cmp.mapping(function(fallback)
- if cmp.visible() then
- cmp.select_prev_item()
- else
- fallback() -- The fallback function sends a already mapped key. In this case, it's probably `<Tab>`.
- end
+ cmp.select_prev_item()
end, { "i", "s" }),
["<Tab>"] = cmp.mapping(function(fallback)
@@ -225,6 +217,15 @@ nvim_lsp.hls.setup({
nvim_lsp.pylsp.setup({
capabilities = require("cmp_nvim_lsp").default_capabilities(vim.lsp.protocol.make_client_capabilities()),
on_attach = M.on_attach,
+ settings = {
+ pylsp = {
+ plugins = {
+ pycodestyle = {
+ enabled = false
+ }
+ }
+ }
+ }
})
nvim_lsp.bash.setup({