Merge branch 'main' of git.andr3h3nriqu3s.com:andr3/nvim-config
This commit is contained in:
commit
1da39178be
@ -53,7 +53,7 @@ require("nvim-tree").setup{ -- BEGIN_DEFAULT_OPTS
|
|||||||
centralize_selection = false,
|
centralize_selection = false,
|
||||||
width = 30,
|
width = 30,
|
||||||
hide_root_folder = false,
|
hide_root_folder = false,
|
||||||
side = "left",
|
side = "right",
|
||||||
preserve_window_proportions = false,
|
preserve_window_proportions = false,
|
||||||
number = false,
|
number = false,
|
||||||
relativenumber = false,
|
relativenumber = false,
|
||||||
@ -153,7 +153,7 @@ require("nvim-tree").setup{ -- BEGIN_DEFAULT_OPTS
|
|||||||
enable = true,
|
enable = true,
|
||||||
show_on_dirs = false,
|
show_on_dirs = false,
|
||||||
debounce_delay = 50,
|
debounce_delay = 50,
|
||||||
icons = { error = "☣️ ", warning = "😞", hint = "❤️ ", info = "ℹ️ " }
|
icons = { error = "☣️ ", warning = "😞", hint = "❤️ ", info = "🆓" }
|
||||||
,
|
,
|
||||||
},
|
},
|
||||||
filters = {
|
filters = {
|
||||||
@ -283,4 +283,5 @@ for key, value in pairs(hls) do
|
|||||||
vim.api.nvim_set_hl(0, key, value)
|
vim.api.nvim_set_hl(0, key, value)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
require("transparent").setup()
|
||||||
|
|
||||||
|
1
lua/andr3/langs/.gitignore
vendored
Normal file
1
lua/andr3/langs/.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
ltex-key
|
12
lua/andr3/langs/go.lua
Normal file
12
lua/andr3/langs/go.lua
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
local O = {};
|
||||||
|
local lspConfig = require('lspconfig')
|
||||||
|
|
||||||
|
function O.setup(on_attach, lsp_flags, capabilities)
|
||||||
|
lspConfig['gopls'].setup{
|
||||||
|
on_attach = on_attach,
|
||||||
|
flags = lsp_flags,
|
||||||
|
capabilities = capabilities,
|
||||||
|
}
|
||||||
|
end
|
||||||
|
|
||||||
|
return O
|
19
lua/andr3/langs/htmlcss.lua
Normal file
19
lua/andr3/langs/htmlcss.lua
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
local O = {};
|
||||||
|
local lspConfig = require('lspconfig')
|
||||||
|
|
||||||
|
function O.setup(on_attach, lsp_flags, capabilities)
|
||||||
|
lspConfig['cssls'].setup{
|
||||||
|
on_attach = on_attach,
|
||||||
|
flags = lsp_flags,
|
||||||
|
capabilities = capabilities,
|
||||||
|
cmd = {"css-languageserver", "--stdio"}
|
||||||
|
}
|
||||||
|
lspConfig['html'].setup{
|
||||||
|
on_attach = on_attach,
|
||||||
|
flags = lsp_flags,
|
||||||
|
capabilities = capabilities,
|
||||||
|
cmd = {"html-languageserver", "--stdio"}
|
||||||
|
}
|
||||||
|
end
|
||||||
|
|
||||||
|
return O
|
3
lua/andr3/langs/ltex-key-bak
Normal file
3
lua/andr3/langs/ltex-key-bak
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
http://api.languagetoolplus.com/
|
||||||
|
andr3h3nriqu3s@gmail.com
|
||||||
|
pit-Z31pae3YaG1c
|
12
lua/andr3/langs/ocaml.lua
Normal file
12
lua/andr3/langs/ocaml.lua
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
local O = {};
|
||||||
|
local lspConfig = require('lspconfig')
|
||||||
|
|
||||||
|
function O.setup(on_attach, lsp_flags, capabilities)
|
||||||
|
lspConfig['ocamllsp'].setup{
|
||||||
|
on_attach = on_attach,
|
||||||
|
flags = lsp_flags,
|
||||||
|
capabilities = capabilities,
|
||||||
|
}
|
||||||
|
end
|
||||||
|
|
||||||
|
return O
|
@ -2,10 +2,50 @@ local O = {};
|
|||||||
local lspConfig = require('lspconfig')
|
local lspConfig = require('lspconfig')
|
||||||
|
|
||||||
function O.setup(on_attach, lsp_flags, capabilities)
|
function O.setup(on_attach, lsp_flags, capabilities)
|
||||||
|
local path = debug.getinfo(1).source
|
||||||
|
local acpath = path:sub(2, #path - 7).."ltex-key"
|
||||||
|
|
||||||
|
local f = io.open(acpath, "r")
|
||||||
|
|
||||||
|
if f == nil then
|
||||||
|
lspConfig['ltex'].setup{
|
||||||
|
on_attach = on_attach,
|
||||||
|
flags = lsp_flags,
|
||||||
|
capabilities = capabilities,
|
||||||
|
}
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
|
io.input(f)
|
||||||
|
local url = io.read("*line")
|
||||||
|
local user = io.read("*line")
|
||||||
|
local key = io.read("*line")
|
||||||
|
io.close(f)
|
||||||
|
|
||||||
|
if user == nil or key == nil or url == nil then
|
||||||
|
lspConfig['ltex'].setup{
|
||||||
|
on_attach = on_attach,
|
||||||
|
flags = lsp_flags,
|
||||||
|
capabilities = capabilities,
|
||||||
|
}
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
lspConfig['ltex'].setup{
|
lspConfig['ltex'].setup{
|
||||||
on_attach = on_attach,
|
on_attach = on_attach,
|
||||||
flags = lsp_flags,
|
flags = lsp_flags,
|
||||||
capabilities = capabilities,
|
capabilities = capabilities,
|
||||||
|
settings = {
|
||||||
|
ltex = {
|
||||||
|
language = "en-GB",
|
||||||
|
languageToolHttpServerUri = url,
|
||||||
|
languageToolOrg = {
|
||||||
|
username = user,
|
||||||
|
apiKey = file
|
||||||
|
},
|
||||||
|
|
||||||
|
},
|
||||||
|
},
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -64,6 +64,7 @@ saga.setup{
|
|||||||
enable_in_insert = true,
|
enable_in_insert = true,
|
||||||
cache_code_action = true,
|
cache_code_action = true,
|
||||||
sign = true,
|
sign = true,
|
||||||
|
icon = signs.CodeAction,
|
||||||
update_time = 150,
|
update_time = 150,
|
||||||
sign_priority = 20,
|
sign_priority = 20,
|
||||||
virtual_text = true,
|
virtual_text = true,
|
||||||
@ -114,12 +115,16 @@ saga.setup{
|
|||||||
},
|
},
|
||||||
custom_kind = {},
|
custom_kind = {},
|
||||||
server_filetype_map = {},
|
server_filetype_map = {},
|
||||||
|
ui = {
|
||||||
|
code_action = signs.CodeAction,
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
keymap("n", "<leader>sf", "<cmd>Lspsaga lsp_finder<CR>", { silent = true })
|
keymap("n", "<leader>sf", "<cmd>Lspsaga lsp_finder<CR>", { silent = true })
|
||||||
keymap("n", "<leader>t", "<cmd>terminal<CR>", { silent = true })
|
keymap("n", "<leader>t", "<cmd>terminal<CR>", { silent = true })
|
||||||
keymap({"n","v"}, "<leader>ca", function () saga.code_action() end, {})
|
keymap({"n","v"}, "<leader>ca", function () saga.code_action() end, {})
|
||||||
keymap("n", "gr", "<cmd>Lspsaga rename<CR>", { silent = true })
|
keymap("n", "gr", "<cmd>Lspsaga rename<CR>", { silent = true })
|
||||||
|
keymap("n", "<F2>", "<cmd>Lspsaga rename<CR>", { silent = true })
|
||||||
keymap("n", "gd", "<cmd>Lspsaga peek_definition<CR>", { silent = true })
|
keymap("n", "gd", "<cmd>Lspsaga peek_definition<CR>", { silent = true })
|
||||||
keymap("n", "<leader>cd", "<cmd>Lspsaga show_cursor_diagnostics<CR>", { silent = true })
|
keymap("n", "<leader>cd", "<cmd>Lspsaga show_cursor_diagnostics<CR>", { silent = true })
|
||||||
keymap("n", "<leader>cr", "<cmd>Lspsaga rename<CR>", { silent = true })
|
keymap("n", "<leader>cr", "<cmd>Lspsaga rename<CR>", { silent = true })
|
||||||
@ -265,4 +270,7 @@ require 'andr3.langs.python'.setup(on_attach, lsp_flags, capabilities)
|
|||||||
require 'andr3.langs.bash'.setup(on_attach, lsp_flags, capabilities)
|
require 'andr3.langs.bash'.setup(on_attach, lsp_flags, capabilities)
|
||||||
require 'andr3.langs.zig'.setup(on_attach, lsp_flags, capabilities)
|
require 'andr3.langs.zig'.setup(on_attach, lsp_flags, capabilities)
|
||||||
require 'andr3.langs.tex'.setup(on_attach, lsp_flags, capabilities)
|
require 'andr3.langs.tex'.setup(on_attach, lsp_flags, capabilities)
|
||||||
|
require 'andr3.langs.ocaml'.setup(on_attach, lsp_flags, capabilities)
|
||||||
|
require 'andr3.langs.go'.setup(on_attach, lsp_flags, capabilities)
|
||||||
|
require 'andr3.langs.htmlcss'.setup(on_attach, lsp_flags, capabilities)
|
||||||
|
|
||||||
|
@ -13,8 +13,10 @@ return require('packer').startup(function()
|
|||||||
use { "catppuccin/nvim", as = "catppuccin" }
|
use { "catppuccin/nvim", as = "catppuccin" }
|
||||||
use {'nyoom-engineering/oxocarbon.nvim'}
|
use {'nyoom-engineering/oxocarbon.nvim'}
|
||||||
use 'NLKNguyen/papercolor-theme'
|
use 'NLKNguyen/papercolor-theme'
|
||||||
|
|
||||||
-- use 'baskerville/bubblegum'
|
-- use 'baskerville/bubblegum'
|
||||||
use 'git@git.andr3h3nriqu3s.com:andr3/bubblegum-theme.git'
|
use 'git@git.andr3h3nriqu3s.com:andr3/bubblegum-theme.git'
|
||||||
|
use 'xiyaowong/transparent.nvim'
|
||||||
|
|
||||||
-- other stuff
|
-- other stuff
|
||||||
|
|
||||||
@ -55,9 +57,6 @@ return require('packer').startup(function()
|
|||||||
-- If you want to have icons in your statusline choose one of these
|
-- If you want to have icons in your statusline choose one of these
|
||||||
use 'nvim-tree/nvim-web-devicons'
|
use 'nvim-tree/nvim-web-devicons'
|
||||||
|
|
||||||
--use 'vim-airline/vim-airline'
|
|
||||||
--use 'vim-airline/vim-airline-themes'
|
|
||||||
|
|
||||||
use 'airblade/vim-gitgutter'
|
use 'airblade/vim-gitgutter'
|
||||||
|
|
||||||
use 'mbbill/undotree'
|
use 'mbbill/undotree'
|
||||||
|
Loading…
Reference in New Issue
Block a user