Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 3c21e12bf3 | |||
| 40aee7d3ce | |||
| f50ddf9d15 | |||
| 2f22ec02d1 |
2
init.lua
2
init.lua
@@ -5,7 +5,7 @@ require('settings/panels')
|
|||||||
require('settings/search')
|
require('settings/search')
|
||||||
|
|
||||||
-- Plugins
|
-- Plugins
|
||||||
require('plugins/packer')
|
require("settings/lazy")
|
||||||
|
|
||||||
-- Keymaps
|
-- Keymaps
|
||||||
require('keymaps/system')
|
require('keymaps/system')
|
||||||
|
|||||||
@@ -156,6 +156,7 @@ end
|
|||||||
if not type -q nvim
|
if not type -q nvim
|
||||||
# Sending the message
|
# Sending the message
|
||||||
print NVIM_NOT_INSTALLED
|
print NVIM_NOT_INSTALLED
|
||||||
|
set_color blue
|
||||||
echo $NVIM_WIKI_INSTALLATION
|
echo $NVIM_WIKI_INSTALLATION
|
||||||
|
|
||||||
# Exit (fail)
|
# Exit (fail)
|
||||||
@@ -170,6 +171,9 @@ if set -q _flag_update
|
|||||||
# Initializing fnm
|
# Initializing fnm
|
||||||
source ~/.config/fish/conf.d/fnm.fish
|
source ~/.config/fish/conf.d/fnm.fish
|
||||||
|
|
||||||
|
# Installing dependencies
|
||||||
|
sudo apt install -y curl zip
|
||||||
|
|
||||||
# Downloadind and installing Node.js:
|
# Downloadind and installing Node.js:
|
||||||
fnm install $NODEJS_VERSION
|
fnm install $NODEJS_VERSION
|
||||||
|
|
||||||
|
|||||||
41
lazy-lock.json
Normal file
41
lazy-lock.json
Normal file
@@ -0,0 +1,41 @@
|
|||||||
|
{
|
||||||
|
"bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" },
|
||||||
|
"coq.artifacts": { "branch": "artifacts", "commit": "ef5f21d638ccc456cfa5b8d0ab37093cefe48c8b" },
|
||||||
|
"coq.thirdparty": { "branch": "3p", "commit": "2bd969a2bcd2624f9c260b1000957c7e665e308e" },
|
||||||
|
"coq_nvim": { "branch": "coq", "commit": "d8b71757358038fa151fb45c493c3a1e8c3629a3" },
|
||||||
|
"diaglist.nvim": { "branch": "master", "commit": "8aba9fcf62cc60e1d5ce941faedecc399d9a1e8b" },
|
||||||
|
"fidget.nvim": { "branch": "main", "commit": "e32b672d8fd343f9d6a76944fedb8c61d7d8111a" },
|
||||||
|
"flexoki": { "branch": "main", "commit": "079554c242a86be5d1a95598c7c6368d6eedd7a3" },
|
||||||
|
"gitsigns.nvim": { "branch": "main", "commit": "5813e4878748805f1518cee7abb50fd7205a3a48" },
|
||||||
|
"jsctags": { "branch": "master", "commit": "22d3fb848c429d4704dc3a8946bc3a4423a8e4a4" },
|
||||||
|
"kommentary": { "branch": "main", "commit": "d5a111a3bc4109a8f913a5863c9092b3b3801482" },
|
||||||
|
"lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" },
|
||||||
|
"lsp-colors.nvim": { "branch": "main", "commit": "2bbe7541747fd339bdd8923fc45631a09bb4f1e5" },
|
||||||
|
"lspkind-nvim": { "branch": "master", "commit": "3ddd1b4edefa425fda5a9f95a4f25578727c0bb3" },
|
||||||
|
"lualine-lsp-progress": { "branch": "master", "commit": "56842d097245a08d77912edf5f2a69ba29f275d7" },
|
||||||
|
"lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" },
|
||||||
|
"lush.nvim": { "branch": "main", "commit": "9c60ec2279d62487d942ce095e49006af28eed6e" },
|
||||||
|
"neo-tree.nvim": { "branch": "v3.x", "commit": "f3df514fff2bdd4318127c40470984137f87b62e" },
|
||||||
|
"nginx.vim": { "branch": "master", "commit": "cffaec54f0c7f9518de053634413a20e90eac825" },
|
||||||
|
"nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" },
|
||||||
|
"nvim-autopairs": { "branch": "master", "commit": "d9e44e54384e5b0f3536339c65484f2e41b528e3" },
|
||||||
|
"nvim-dap": { "branch": "master", "commit": "5860c7c501eb428d3137ee22c522828d20cca0b3" },
|
||||||
|
"nvim-dap-ui": { "branch": "master", "commit": "cf91d5e2d07c72903d052f5207511bf7ecdb7122" },
|
||||||
|
"nvim-dap-virtual-text": { "branch": "master", "commit": "fbdb48c2ed45f4a8293d0d483f7730d24467ccb6" },
|
||||||
|
"nvim-lint": { "branch": "master", "commit": "c47b71d146a0b638f46672e6704c322369385df6" },
|
||||||
|
"nvim-lspconfig": { "branch": "master", "commit": "0d7d33e40f0c27f57cb29654ed78cab17d705e68" },
|
||||||
|
"nvim-nio": { "branch": "master", "commit": "21f5324bfac14e22ba26553caf69ec76ae8a7662" },
|
||||||
|
"nvim-treesitter": { "branch": "main", "commit": "d0bf5ff2b00939eab39c6572aec7cf232f843b1f" },
|
||||||
|
"nvim-web-devicons": { "branch": "master", "commit": "8dcb311b0c92d460fac00eac706abd43d94d68af" },
|
||||||
|
"phpctags": { "branch": "master", "commit": "5ed731eb86227d416977b0a1fd06e77e58363818" },
|
||||||
|
"plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" },
|
||||||
|
"reticle.nvim": { "branch": "main", "commit": "66bfa2b1c28fd71bb8ae4e871e0cd9e9c509ea86" },
|
||||||
|
"tagbar": { "branch": "master", "commit": "7bfffca1f121afb7a9e38747500bf5270e006bb1" },
|
||||||
|
"telescope-dap.nvim": { "branch": "master", "commit": "783366bd6c1e7fa0a5c59c07db37f49c805a28df" },
|
||||||
|
"telescope.nvim": { "branch": "master", "commit": "e69b434b968a33815e2f02a5c7bd7b8dd4c7d4b2" },
|
||||||
|
"trouble.nvim": { "branch": "main", "commit": "bd67efe408d4816e25e8491cc5ad4088e708a69a" },
|
||||||
|
"vim-fish": { "branch": "master", "commit": "50b95cbbcd09c046121367d49039710e9dc9c15f" },
|
||||||
|
"vim-fugitive": { "branch": "master", "commit": "61b51c09b7c9ce04e821f6cf76ea4f6f903e3cf4" },
|
||||||
|
"vim-signify": { "branch": "master", "commit": "9ec7989ef5f92c5073de26abb46fc6a998b75ef8" },
|
||||||
|
"vim-test": { "branch": "master", "commit": "1eeb12774a0f251571700ccf68da27789b2f0852" }
|
||||||
|
}
|
||||||
@@ -62,7 +62,7 @@ vim.keymap.set({ 'n', 'v', 't' }, 'F', function()
|
|||||||
else
|
else
|
||||||
-- LSP-server clients not found
|
-- LSP-server clients not found
|
||||||
|
|
||||||
vim.api.nvim_exec('PrettierAsync', false)
|
-- vim.api.nvim_exec('PrettierAsync', false)
|
||||||
end
|
end
|
||||||
end,
|
end,
|
||||||
{ noremap = true, silent = true, buffer = bufnr })
|
{ noremap = true, silent = true, buffer = bufnr })
|
||||||
|
|||||||
@@ -1,4 +1,12 @@
|
|||||||
require('nvim-autopairs').setup({
|
-- A super powerful autopair plugin for Neovim that supports multiple characters
|
||||||
map_bs = false,
|
return {
|
||||||
map_cr = false
|
'windwp/nvim-autopairs',
|
||||||
})
|
enabled = true,
|
||||||
|
lazy = true,
|
||||||
|
event = 'InsertEnter',
|
||||||
|
opts = {
|
||||||
|
-- map_bs = false,
|
||||||
|
-- map_cr = false
|
||||||
|
},
|
||||||
|
config = true
|
||||||
|
}
|
||||||
|
|||||||
@@ -1,2 +1,67 @@
|
|||||||
require('bufferline').setup({
|
-- A snazzy 💅 buffer line (with tabpage integration) for Neovim built using lua
|
||||||
})
|
return {
|
||||||
|
'akinsho/bufferline.nvim',
|
||||||
|
enabled = true,
|
||||||
|
lazy = false,
|
||||||
|
priority = 40,
|
||||||
|
version = '*',
|
||||||
|
dependencies = {
|
||||||
|
--
|
||||||
|
{ 'nvim-tree/nvim-web-devicons' }
|
||||||
|
},
|
||||||
|
opts = {
|
||||||
|
options = {
|
||||||
|
themable = true,
|
||||||
|
numbers = 'buffer_id',
|
||||||
|
-- close_command = 'bdelete! %d',
|
||||||
|
-- right_mouse_command = 'bdelete! %d',
|
||||||
|
-- left_mouse_command = 'buffer %d',
|
||||||
|
-- middle_mouse_command = nil,
|
||||||
|
indicator = {
|
||||||
|
icon = '▎',
|
||||||
|
style = 'icon',
|
||||||
|
},
|
||||||
|
max_name_length = 24,
|
||||||
|
max_prefix_length = 18,
|
||||||
|
truncate_names = true,
|
||||||
|
tab_size = 18,
|
||||||
|
diagnostics = 'nvim_lsp',
|
||||||
|
offsets = {
|
||||||
|
{
|
||||||
|
filetype = 'NvimTree',
|
||||||
|
text = 'File Explorer',
|
||||||
|
text_align = 'left',
|
||||||
|
separator = true
|
||||||
|
}
|
||||||
|
},
|
||||||
|
color_icons = true,
|
||||||
|
show_buffer_icons = true,
|
||||||
|
show_buffer_close_icons = true,
|
||||||
|
show_close_icon = true,
|
||||||
|
show_tab_indicators = true,
|
||||||
|
show_duplicate_prefix = true,
|
||||||
|
duplicates_across_groups = true,
|
||||||
|
persist_buffer_sort = true,
|
||||||
|
move_wraps_at_ends = false,
|
||||||
|
-- separator_style = 'slant' | 'slope' | 'thick' | 'thin' | { 'any', 'any' },
|
||||||
|
separator_style = 'thin',
|
||||||
|
enforce_regular_tabs = false,
|
||||||
|
always_show_bufferline = true,
|
||||||
|
auto_toggle_bufferline = true,
|
||||||
|
hover = {
|
||||||
|
enabled = true,
|
||||||
|
delay = 200,
|
||||||
|
reveal = {'close'}
|
||||||
|
},
|
||||||
|
--[[ sort_by = 'insert_after_current' |'insert_at_end' | 'id' | 'extension' | 'relative_directory' | 'directory' | 'tabs' | function(buffer_a, buffer_b)
|
||||||
|
local modified_a = vim.fn.getftime(buffer_a.path)
|
||||||
|
local modified_b = vim.fn.getftime(buffer_b.path)
|
||||||
|
return modified_a > modified_b
|
||||||
|
end, ]]
|
||||||
|
sort_by = 'insert_after_current',
|
||||||
|
pick = {
|
||||||
|
alphabet = 'abcdefghijklmopqrstuvwxyzABCDEFGHIJKLMOPQRSTUVWXYZ1234567890',
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -1,4 +1,49 @@
|
|||||||
-- Настройка "ms-jpq/coq_nvim"
|
-- Fast as FUCK nvim completion
|
||||||
vim.g.coq_settings = {
|
return {
|
||||||
auto_start = 'shut-up'
|
'ms-jpq/coq_nvim',
|
||||||
|
enabled = true,
|
||||||
|
lazy = false,
|
||||||
|
branch = 'coq',
|
||||||
|
dependencies = {
|
||||||
|
-- Quickstart configs for Nvim LSP
|
||||||
|
{ 'neovim/nvim-lspconfig' },
|
||||||
|
|
||||||
|
-- 9000+ Snippets
|
||||||
|
{ 'ms-jpq/coq.artifacts', branch = 'artifacts' },
|
||||||
|
|
||||||
|
-- Lua & third party sources. Need to **configure separately**
|
||||||
|
{ 'ms-jpq/coq.thirdparty', branch = '3p' }
|
||||||
|
},
|
||||||
|
config = function()
|
||||||
|
vim.g.coq_settings = {
|
||||||
|
auto_start = 'shut-up',
|
||||||
|
}
|
||||||
|
end,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
--
|
||||||
|
--[[ {
|
||||||
|
'neovim/nvim-lspconfig',
|
||||||
|
lazy = false,
|
||||||
|
dependencies = {
|
||||||
|
-- Fast as FUCK nvim completion
|
||||||
|
{ 'ms-jpq/coq_nvim', branch = 'coq' },
|
||||||
|
|
||||||
|
-- 9000+ Snippets
|
||||||
|
{ 'ms-jpq/coq.artifacts', branch = 'artifacts' },
|
||||||
|
|
||||||
|
-- Lua & third party sources. Need to **configure separately**
|
||||||
|
{ 'ms-jpq/coq.thirdparty', branch = '3p' }
|
||||||
|
},
|
||||||
|
|
||||||
|
init = function()
|
||||||
|
vim.g.coq_settings = {
|
||||||
|
auto_start = 'shut-up',
|
||||||
|
-- Your COQ settings here
|
||||||
|
}
|
||||||
|
end,
|
||||||
|
|
||||||
|
config = function()
|
||||||
|
-- Your LSP settings here
|
||||||
|
end,
|
||||||
|
} ]]
|
||||||
|
|||||||
@@ -1,37 +1,13 @@
|
|||||||
require("nvim-dap-virtual-text").setup {
|
-- Virtual text support to nvim-dap
|
||||||
enabled = true, -- enable this plugin (the default)
|
return {
|
||||||
enabled_commands = true, -- create commands DapVirtualTextEnable, DapVirtualTextDisable, DapVirtualTextToggle, (DapVirtualTextForceRefresh for refreshing when debug adapter did not notify its termination)
|
'theHamsta/nvim-dap-virtual-text',
|
||||||
highlight_changed_variables = true, -- highlight changed values with NvimDapVirtualTextChanged, else always NvimDapVirtualText
|
enabled = true,
|
||||||
highlight_new_as_changed = false, -- highlight new variables in the same way as changed variables (if highlight_changed_variables)
|
lazy = true,
|
||||||
show_stop_reason = true, -- show stop reason when stopped for exceptions
|
dependencies = {
|
||||||
commented = false, -- prefix virtual text with comment string
|
-- Debug Adapter Protocol client implementation for Neovim
|
||||||
only_first_definition = true, -- only show virtual text at first definition (if there are multiple)
|
{ 'mfussenegger/nvim-dap' },
|
||||||
all_references = false, -- show virtual text on all all references of the variable (not only definitions)
|
|
||||||
clear_on_continue = false, -- clear virtual text on "continue" (might cause flickering when stepping)
|
|
||||||
|
|
||||||
--- A callback that determines how a variable is displayed or whether it should be omitted
|
-- Nvim Treesitter configurations and abstraction layer
|
||||||
--- @param variable Variable https://microsoft.github.io/debug-adapter-protocol/specification#Types_Variable
|
{ 'nvim-treesitter/nvim-treesitter' }
|
||||||
--- @param buf number
|
}
|
||||||
--- @param stackframe dap.StackFrame https://microsoft.github.io/debug-adapter-protocol/specification#Types_StackFrame
|
|
||||||
--- @param node userdata tree-sitter node identified as variable definition of reference (see `:h tsnode`)
|
|
||||||
--- @param options nvim_dap_virtual_text_options Current options for nvim-dap-virtual-text
|
|
||||||
--- @return string|nil A text how the virtual text should be displayed or nil, if this variable shouldn't be displayed
|
|
||||||
display_callback = function(variable, buf, stackframe, node, options)
|
|
||||||
|
|
||||||
-- by default, strip out new line characters
|
|
||||||
if options.virt_text_pos == 'inline' then
|
|
||||||
return ' = ' .. variable.value:gsub("%s+", " ")
|
|
||||||
else
|
|
||||||
return variable.name .. ' = ' .. variable.value:gsub("%s+", " ")
|
|
||||||
end
|
|
||||||
end,
|
|
||||||
|
|
||||||
-- position of virtual text, see `:h nvim_buf_set_extmark()`, default tries to inline the virtual text. Use 'eol' to set to end of line
|
|
||||||
virt_text_pos = vim.fn.has 'nvim-0.10' == 1 and 'inline' or 'eol',
|
|
||||||
|
|
||||||
-- experimental features:
|
|
||||||
all_frames = false, -- show virtual text for all stack frames not only current. Only works for debugpy on my machine.
|
|
||||||
virt_lines = false, -- show virtual lines instead of virtual text (will flicker!)
|
|
||||||
virt_text_win_col = nil -- position the virtual text at a fixed window column (starting from the first text column) ,
|
|
||||||
-- e.g. 80 to position at column 80, see `:h nvim_buf_set_extmark()`
|
|
||||||
}
|
}
|
||||||
|
|||||||
32
lua/plugins/dap-ui.lua
Normal file
32
lua/plugins/dap-ui.lua
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
-- A UI for nvim-dap
|
||||||
|
return {
|
||||||
|
'rcarriga/nvim-dap-ui',
|
||||||
|
enabled = true,
|
||||||
|
lazy = true,
|
||||||
|
dependencies = {
|
||||||
|
-- Debug Adapter Protocol client implementation for Neovim
|
||||||
|
'mfussenegger/nvim-dap',
|
||||||
|
|
||||||
|
-- A library for asynchronous IO in Neovim
|
||||||
|
'nvim-neotest/nvim-nio'
|
||||||
|
},
|
||||||
|
config = function()
|
||||||
|
local dap, dapui = require('dap'), require('dapui')
|
||||||
|
|
||||||
|
dap.listeners.before.attach.dapui_config = function()
|
||||||
|
dapui.open()
|
||||||
|
end
|
||||||
|
|
||||||
|
dap.listeners.before.launch.dapui_config = function()
|
||||||
|
dapui.open()
|
||||||
|
end
|
||||||
|
|
||||||
|
dap.listeners.before.event_terminated.dapui_config = function()
|
||||||
|
dapui.close()
|
||||||
|
end
|
||||||
|
|
||||||
|
dap.listeners.before.event_exited.dapui_config = function()
|
||||||
|
dapui.close()
|
||||||
|
end
|
||||||
|
end
|
||||||
|
}
|
||||||
@@ -1,23 +1,29 @@
|
|||||||
-- Initialization
|
-- Debug Adapter Protocol client implementation for Neovim
|
||||||
local dap = require('dap')
|
return {
|
||||||
|
'mfussenegger/nvim-dap',
|
||||||
|
enabled = true,
|
||||||
|
lazy = true,
|
||||||
|
config = function()
|
||||||
|
local dap = require('dap')
|
||||||
|
|
||||||
-- Installing C, Rust and C++
|
-- Installing debuggers for C, Rust and C++
|
||||||
dap.configurations.cpp = {
|
dap.configurations.cpp = {}
|
||||||
}
|
|
||||||
|
|
||||||
-- Initializing PHP adapter
|
-- Initializing PHP debugger adapter
|
||||||
dap.adapters.php = {
|
dap.adapters.php = {
|
||||||
type = "executable",
|
type = 'executable',
|
||||||
command = "node",
|
command = 'node',
|
||||||
args = { os.getenv("HOME") .. "/vscode-php-debug/out/phpDebug.js" }
|
args = { os.getenv('HOME') .. '/vscode-php-debug/out/phpDebug.js' }
|
||||||
}
|
}
|
||||||
|
|
||||||
-- Installing PHP
|
-- Installing PHP debugger
|
||||||
dap.configurations.php = {
|
dap.configurations.php = {
|
||||||
{
|
{
|
||||||
type = "php",
|
type = 'php',
|
||||||
request = "launch",
|
request = 'launch',
|
||||||
name = "Listen for Xdebug",
|
name = 'Listen for Xdebug',
|
||||||
port = 9003
|
port = 9003
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
end
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,19 +0,0 @@
|
|||||||
require('dapui').setup()
|
|
||||||
|
|
||||||
local dap, dapui = require("dap"), require("dapui")
|
|
||||||
|
|
||||||
dap.listeners.before.attach.dapui_config = function()
|
|
||||||
dapui.open()
|
|
||||||
end
|
|
||||||
|
|
||||||
dap.listeners.before.launch.dapui_config = function()
|
|
||||||
dapui.open()
|
|
||||||
end
|
|
||||||
|
|
||||||
dap.listeners.before.event_terminated.dapui_config = function()
|
|
||||||
dapui.close()
|
|
||||||
end
|
|
||||||
|
|
||||||
dap.listeners.before.event_exited.dapui_config = function()
|
|
||||||
dapui.close()
|
|
||||||
end
|
|
||||||
@@ -1,7 +1,11 @@
|
|||||||
require('diaglist').init({
|
-- Live render workspace diagnostics in quickfix with
|
||||||
-- below are defaults
|
-- current buf errors on top, buffer diagnostics in loclist
|
||||||
debug = false,
|
return {
|
||||||
|
'onsails/diaglist.nvim',
|
||||||
-- increase for noisy servers
|
enabled = true,
|
||||||
debounce_ms = 150,
|
lazy = true,
|
||||||
})
|
opts = {
|
||||||
|
debug = false,
|
||||||
|
debounce_ms = 150
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
7
lua/plugins/disabled/prettier.lua
Normal file
7
lua/plugins/disabled/prettier.lua
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
--[[ -- Форматировщик Prettier
|
||||||
|
use {
|
||||||
|
'prettier/vim-prettier',
|
||||||
|
branch = 'master',
|
||||||
|
-- run = 'sudo npm i -g',
|
||||||
|
run = 'yarn install --frozen-lockfile --production'
|
||||||
|
} ]]
|
||||||
@@ -1,95 +1,7 @@
|
|||||||
require('fidget').setup({
|
-- 💫 Extensible UI for Neovim notifications and LSP progress messages
|
||||||
-- Options related to LSP progress subsystem
|
return {
|
||||||
progress = {
|
'j-hui/fidget.nvim',
|
||||||
poll_rate = 0, -- How and when to poll for progress messages
|
enabled = true,
|
||||||
suppress_on_insert = false, -- Suppress new messages while in insert mode
|
lazy = true,
|
||||||
ignore_done_already = false, -- Ignore new tasks that are already complete
|
opts = {}
|
||||||
ignore_empty_message = false, -- Ignore new tasks that don't contain a message
|
}
|
||||||
clear_on_detach = -- Clear notification group when LSP server detaches
|
|
||||||
function(client_id)
|
|
||||||
local client = vim.lsp.get_client_by_id(client_id)
|
|
||||||
return client and client.name or nil
|
|
||||||
end,
|
|
||||||
notification_group = -- How to get a progress message's notification group key
|
|
||||||
function(msg) return msg.lsp_client.name end,
|
|
||||||
ignore = {}, -- List of LSP servers to ignore
|
|
||||||
-- Options related to how LSP progress messages are displayed as notifications
|
|
||||||
display = {
|
|
||||||
render_limit = 16, -- How many LSP messages to show at once
|
|
||||||
done_ttl = 3, -- How long a message should persist after completion
|
|
||||||
done_icon = "✔", -- Icon shown when all LSP progress tasks are complete
|
|
||||||
done_style = "Constant", -- Highlight group for completed LSP tasks
|
|
||||||
progress_ttl = math.huge, -- How long a message should persist when in progress
|
|
||||||
progress_icon = -- Icon shown when LSP progress tasks are in progress
|
|
||||||
{ pattern = "dots", period = 1 },
|
|
||||||
progress_style = -- Highlight group for in-progress LSP tasks
|
|
||||||
"WarningMsg",
|
|
||||||
group_style = "Title", -- Highlight group for group name (LSP server name)
|
|
||||||
icon_style = "Question", -- Highlight group for group icons
|
|
||||||
priority = 30, -- Ordering priority for LSP notification group
|
|
||||||
skip_history = true, -- Whether progress notifications should be omitted from history
|
|
||||||
format_message = -- How to format a progress message
|
|
||||||
require("fidget.progress.display").default_format_message,
|
|
||||||
format_annote = -- How to format a progress annotation
|
|
||||||
function(msg) return msg.title end,
|
|
||||||
format_group_name = -- How to format a progress notification group's name
|
|
||||||
function(group) return tostring(group) end,
|
|
||||||
overrides = { -- Override options from the default notification config
|
|
||||||
rust_analyzer = { name = "rust-analyzer" },
|
|
||||||
},
|
|
||||||
},
|
|
||||||
-- Options related to Neovim's built-in LSP client
|
|
||||||
lsp = {
|
|
||||||
progress_ringbuf_size = 0, -- Configure the nvim's LSP progress ring buffer size
|
|
||||||
},
|
|
||||||
},
|
|
||||||
-- Options related to notification subsystem
|
|
||||||
notification = {
|
|
||||||
poll_rate = 10, -- How frequently to update and render notifications
|
|
||||||
filter = vim.log.levels.INFO, -- Minimum notifications level
|
|
||||||
history_size = 128, -- Number of removed messages to retain in history
|
|
||||||
override_vim_notify = false, -- Automatically override vim.notify() with Fidget
|
|
||||||
configs = -- How to configure notification groups when instantiated
|
|
||||||
{ default = require("fidget.notification").default_config },
|
|
||||||
redirect = -- Conditionally redirect notifications to another backend
|
|
||||||
function(msg, level, opts)
|
|
||||||
if opts and opts.on_open then
|
|
||||||
return require("fidget.integration.nvim-notify").delegate(msg, level, opts)
|
|
||||||
end
|
|
||||||
end,
|
|
||||||
-- Options related to how notifications are rendered as text
|
|
||||||
view = {
|
|
||||||
stack_upwards = true, -- Display notification items from bottom to top
|
|
||||||
icon_separator = " ", -- Separator between group name and icon
|
|
||||||
group_separator = "---", -- Separator between notification groups
|
|
||||||
group_separator_hl = -- Highlight group used for group separator
|
|
||||||
"Comment",
|
|
||||||
},
|
|
||||||
-- Options related to the notification window and buffer
|
|
||||||
window = {
|
|
||||||
normal_hl = "Comment", -- Base highlight group in the notification window
|
|
||||||
winblend = 100, -- Background color opacity in the notification window
|
|
||||||
border = "none", -- Border around the notification window
|
|
||||||
zindex = 45, -- Stacking priority of the notification window
|
|
||||||
max_width = 0, -- Maximum width of the notification window
|
|
||||||
max_height = 0, -- Maximum height of the notification window
|
|
||||||
x_padding = 1, -- Padding from right edge of window boundary
|
|
||||||
y_padding = 0, -- Padding from bottom edge of window boundary
|
|
||||||
align = "bottom", -- How to align the notification window
|
|
||||||
relative = "editor", -- What the notification window position is relative to
|
|
||||||
},
|
|
||||||
},
|
|
||||||
-- Options related to integrating with other plugins
|
|
||||||
integration = {
|
|
||||||
["nvim-tree"] = {
|
|
||||||
enable = true, -- Integrate with nvim-tree/nvim-tree.lua (if installed)
|
|
||||||
},
|
|
||||||
},
|
|
||||||
-- Options related to logging
|
|
||||||
logger = {
|
|
||||||
level = vim.log.levels.WARN, -- Minimum logging level
|
|
||||||
float_precision = 0.01, -- Limit the number of decimals displayed for floats
|
|
||||||
path = -- Where Fidget writes its logs to
|
|
||||||
string.format("%s/fidget.nvim.log", vim.fn.stdpath("cache")),
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|||||||
@@ -1,9 +1,13 @@
|
|||||||
-- Initializing
|
-- Inky color scheme
|
||||||
local flexoki = require('flexoki')
|
-- todo навести порядок
|
||||||
|
return {
|
||||||
-- Installing
|
'nuvic/flexoki-nvim',
|
||||||
flexoki.setup({
|
enabled = true,
|
||||||
variant = "auto", -- auto, moon, or dawn
|
lazy = false,
|
||||||
|
priority = 100,
|
||||||
|
name = 'flexoki',
|
||||||
|
opts = {
|
||||||
|
variant = 'auto', -- auto, moon, or dawn
|
||||||
dim_inactive_windows = false,
|
dim_inactive_windows = false,
|
||||||
extend_background_behind_borders = true,
|
extend_background_behind_borders = true,
|
||||||
|
|
||||||
@@ -17,35 +21,35 @@ flexoki.setup({
|
|||||||
},
|
},
|
||||||
|
|
||||||
groups = {
|
groups = {
|
||||||
border = "muted",
|
border = 'muted',
|
||||||
link = "purple_two",
|
link = 'purple_two',
|
||||||
panel = "surface",
|
panel = 'surface',
|
||||||
|
|
||||||
error = "red_one",
|
error = 'red_one',
|
||||||
hint = "purple_one",
|
hint = 'purple_one',
|
||||||
info = "cyan_one",
|
info = 'cyan_one',
|
||||||
ok = "green_one",
|
ok = 'green_one',
|
||||||
warn = "orange_one",
|
warn = 'orange_one',
|
||||||
note = "blue_one",
|
note = 'blue_one',
|
||||||
todo = "magenta_one",
|
todo = 'magenta_one',
|
||||||
|
|
||||||
git_add = "green_one",
|
git_add = 'green_one',
|
||||||
git_change = "yellow_one",
|
git_change = 'yellow_one',
|
||||||
git_delete = "red_one",
|
git_delete = 'red_one',
|
||||||
git_dirty = "yellow_one",
|
git_dirty = 'yellow_one',
|
||||||
git_ignore = "muted",
|
git_ignore = 'muted',
|
||||||
git_merge = "purple_one",
|
git_merge = 'purple_one',
|
||||||
git_rename = "blue_one",
|
git_rename = 'blue_one',
|
||||||
git_stage = "purple_one",
|
git_stage = 'purple_one',
|
||||||
git_text = "magenta_one",
|
git_text = 'magenta_one',
|
||||||
git_untracked = "subtle",
|
git_untracked = 'subtle',
|
||||||
|
|
||||||
h1 = "purple_two",
|
h1 = 'purple_two',
|
||||||
h2 = "cyan_two",
|
h2 = 'cyan_two',
|
||||||
h3 = "magenta_two",
|
h3 = 'magenta_two',
|
||||||
h4 = "orange_two",
|
h4 = 'orange_two',
|
||||||
h5 = "blue_two",
|
h5 = 'blue_two',
|
||||||
h6 = "cyan_two",
|
h6 = 'cyan_two',
|
||||||
},
|
},
|
||||||
|
|
||||||
palette = {
|
palette = {
|
||||||
@@ -57,8 +61,8 @@ flexoki.setup({
|
|||||||
},
|
},
|
||||||
|
|
||||||
highlight_groups = {
|
highlight_groups = {
|
||||||
-- Comment = { fg = "subtle" },
|
-- Comment = { fg = 'subtle' },
|
||||||
-- VertSplit = { fg = "muted", bg = "muted" },
|
-- VertSplit = { fg = 'muted', bg = 'muted' },
|
||||||
},
|
},
|
||||||
|
|
||||||
before_highlight = function(group, highlight, palette)
|
before_highlight = function(group, highlight, palette)
|
||||||
@@ -71,7 +75,10 @@ flexoki.setup({
|
|||||||
-- if highlight.fg == palette.blue_two then
|
-- if highlight.fg == palette.blue_two then
|
||||||
-- highlight.fg = palette.cyan_two
|
-- highlight.fg = palette.cyan_two
|
||||||
-- end
|
-- end
|
||||||
end,})
|
end,
|
||||||
|
},
|
||||||
-- Activating
|
config = function()
|
||||||
vim.cmd("colorscheme flexoki-moon")
|
-- Activating
|
||||||
|
vim.cmd('colorscheme flexoki')
|
||||||
|
end
|
||||||
|
}
|
||||||
|
|||||||
@@ -1,5 +1,11 @@
|
|||||||
require('gitsigns').setup {
|
-- Git integration for buffers
|
||||||
on_attach = gitsigns_on_attach,
|
-- todo навести порядок
|
||||||
|
return {
|
||||||
|
'lewis6991/gitsigns.nvim',
|
||||||
|
enabled = true,
|
||||||
|
lazy = true,
|
||||||
|
opts = {
|
||||||
|
on_attach = gitsigns_on_attach,
|
||||||
signs = {
|
signs = {
|
||||||
add = { text = '│' },
|
add = { text = '│' },
|
||||||
change = { text = '│' },
|
change = { text = '│' },
|
||||||
@@ -37,7 +43,9 @@ require('gitsigns').setup {
|
|||||||
row = 0,
|
row = 0,
|
||||||
col = 1
|
col = 1
|
||||||
},
|
},
|
||||||
yadm = {
|
--[[ yadm = {
|
||||||
enable = false
|
enable = false
|
||||||
},
|
}, ]]
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
6
lua/plugins/kommentary.lua
Normal file
6
lua/plugins/kommentary.lua
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
-- Neovim commenting plugin, written in lua
|
||||||
|
return {
|
||||||
|
'b3nj5m1n/kommentary',
|
||||||
|
enabled = true,
|
||||||
|
lazy = true
|
||||||
|
}
|
||||||
@@ -1,5 +1,14 @@
|
|||||||
vim.api.nvim_create_autocmd({ 'BufWritePost' }, {
|
-- An asynchronous linter plugin for Neovim complementary
|
||||||
callback = function()
|
-- to the built-in Language Server Protocol support.
|
||||||
require('lint').try_lint()
|
return {
|
||||||
end,
|
'mfussenegger/nvim-lint',
|
||||||
})
|
enabled = true,
|
||||||
|
lazy = true,
|
||||||
|
config = function()
|
||||||
|
vim.api.nvim_create_autocmd({ 'BufWritePost' }, {
|
||||||
|
callback = function()
|
||||||
|
require('lint').try_lint()
|
||||||
|
end
|
||||||
|
})
|
||||||
|
end
|
||||||
|
}
|
||||||
|
|||||||
@@ -1,24 +1,48 @@
|
|||||||
-- Инициализация "neovim/nvim-lspconfig"
|
-- Quickstart configs for Nvim LSP
|
||||||
local lspconfig = require('lspconfig')
|
return {
|
||||||
|
'neovim/nvim-lspconfig',
|
||||||
|
enabled = true,
|
||||||
|
lazy = false,
|
||||||
|
priority = 70,
|
||||||
|
dependencies = {
|
||||||
|
-- 🌈 Plugin that creates missing LSP diagnostics
|
||||||
|
-- highlight groups for color schemes that do not
|
||||||
|
-- yet support the Neovim 0.5 builtin LSP client
|
||||||
|
{ 'folke/lsp-colors.nvim' },
|
||||||
|
|
||||||
|
-- 9000+ Snippets
|
||||||
|
{ 'ms-jpq/coq.artifacts', branch = 'artifacts' },
|
||||||
|
|
||||||
|
-- Lua & third party sources. Need to **configure separately**
|
||||||
|
{ 'ms-jpq/coq.thirdparty', branch = '3p' }
|
||||||
|
},
|
||||||
|
config = function()
|
||||||
|
-- @todo навести порядок
|
||||||
|
|
||||||
-- Активация вещания готовых набросков
|
-- Активация вещания готовых набросков
|
||||||
local capabilities = vim.lsp.protocol.make_client_capabilities()
|
local capabilities = vim.lsp.protocol.make_client_capabilities()
|
||||||
capabilities.textDocument.completion.completionItem.snippetSupport = true
|
capabilities.textDocument.completion.completionItem.snippetSupport = true
|
||||||
|
|
||||||
-- Инициализация "ms-jpq/coq_nvim"
|
-- Инициализация 'ms-jpq/coq_nvim'
|
||||||
local coq = require('coq')
|
local coq = require('coq')
|
||||||
|
|
||||||
-- Инициализация LSP-серверов
|
-- Инициализация LSP-серверов
|
||||||
|
|
||||||
-- Инициализация "bmewburn/vscode-intelephense" (LSP-сервер для PHP)
|
-- Инициализация 'bmewburn/vscode-intelephense' (LSP-сервер для PHP)
|
||||||
lspconfig.intelephense.setup({
|
vim.lsp.config(
|
||||||
on_attach = lspconfig_on_attach,
|
'intelephense',
|
||||||
coq.lsp_ensure_capabilities(),
|
{
|
||||||
capabilities = capabilities
|
on_attach = lspconfig_on_attach,
|
||||||
})
|
coq.lsp_ensure_capabilities(),
|
||||||
|
capabilities = capabilities
|
||||||
|
}
|
||||||
|
)
|
||||||
|
vim.lsp.enable('intelephense')
|
||||||
|
|
||||||
-- Инициализация "hrsh7th/vscode-html-language-server" (LSP-сервер для HTML)
|
-- Инициализация 'hrsh7th/vscode-html-language-server' (LSP-сервер для HTML)
|
||||||
lspconfig.html.setup({
|
vim.lsp.config(
|
||||||
|
'html',
|
||||||
|
{
|
||||||
init_options = {
|
init_options = {
|
||||||
configurationSection = { 'html' },
|
configurationSection = { 'html' },
|
||||||
embeddedLanguages = {
|
embeddedLanguages = {
|
||||||
@@ -30,14 +54,18 @@ lspconfig.html.setup({
|
|||||||
on_attach = lspconfig_on_attach,
|
on_attach = lspconfig_on_attach,
|
||||||
coq.lsp_ensure_capabilities(),
|
coq.lsp_ensure_capabilities(),
|
||||||
capabilities = capabilities
|
capabilities = capabilities
|
||||||
})
|
}
|
||||||
|
)
|
||||||
|
vim.lsp.enable('html')
|
||||||
|
|
||||||
-- Инициализация "aca/emmet-ls" (LSP-сервер для HTML)
|
-- Инициализация 'aca/emmet-ls' (LSP-сервер для HTML)
|
||||||
lspconfig.emmet_ls.setup({
|
vim.lsp.config(
|
||||||
|
'emmet_ls',
|
||||||
|
{
|
||||||
init_options = {
|
init_options = {
|
||||||
html = {
|
html = {
|
||||||
options = {
|
options = {
|
||||||
["bem.enabled"] = true,
|
['bem.enabled'] = true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
@@ -45,9 +73,12 @@ lspconfig.emmet_ls.setup({
|
|||||||
coq.lsp_ensure_capabilities(),
|
coq.lsp_ensure_capabilities(),
|
||||||
capabilities = capabilities
|
capabilities = capabilities
|
||||||
})
|
})
|
||||||
|
vim.lsp.enable('emmet_ls')
|
||||||
|
|
||||||
-- Инициализация "hrsh7th/vscode-langservers-extracted" (LSP-сервер для CSS)
|
-- Инициализация 'hrsh7th/vscode-langservers-extracted' (LSP-сервер для CSS)
|
||||||
lspconfig.cssls.setup({
|
vim.lsp.config(
|
||||||
|
'cssls',
|
||||||
|
{
|
||||||
settings = {
|
settings = {
|
||||||
css = {
|
css = {
|
||||||
validate = true
|
validate = true
|
||||||
@@ -63,9 +94,12 @@ lspconfig.cssls.setup({
|
|||||||
coq.lsp_ensure_capabilities(),
|
coq.lsp_ensure_capabilities(),
|
||||||
capabilities = capabilities
|
capabilities = capabilities
|
||||||
})
|
})
|
||||||
|
vim.lsp.enable('cssls')
|
||||||
|
|
||||||
-- Инициализация "antonk52/cssmodules-language-server" (LSP-сервер для JS, вспомогательный для CSS)
|
-- Инициализация 'antonk52/cssmodules-language-server' (LSP-сервер для JS, вспомогательный для CSS)
|
||||||
lspconfig.cssmodules_ls.setup({
|
vim.lsp.config(
|
||||||
|
'cssmodules_ls',
|
||||||
|
{
|
||||||
init_options = {
|
init_options = {
|
||||||
camelCase = false,
|
camelCase = false,
|
||||||
},
|
},
|
||||||
@@ -73,9 +107,12 @@ lspconfig.cssmodules_ls.setup({
|
|||||||
coq.lsp_ensure_capabilities(),
|
coq.lsp_ensure_capabilities(),
|
||||||
capabilities = capabilities
|
capabilities = capabilities
|
||||||
})
|
})
|
||||||
|
vim.lsp.enable('cssmodules_ls')
|
||||||
|
|
||||||
-- Инициализация "denoland/deno" (LSP-сервер для JavaScript и PostScript)
|
-- Инициализация 'denoland/deno' (LSP-сервер для JavaScript и PostScript)
|
||||||
lspconfig.denols.setup({
|
vim.lsp.config(
|
||||||
|
'denols',
|
||||||
|
{
|
||||||
init_options = {
|
init_options = {
|
||||||
enable = true,
|
enable = true,
|
||||||
unstable = false
|
unstable = false
|
||||||
@@ -84,16 +121,20 @@ lspconfig.denols.setup({
|
|||||||
coq.lsp_ensure_capabilities(),
|
coq.lsp_ensure_capabilities(),
|
||||||
capabilities = capabilities
|
capabilities = capabilities
|
||||||
})
|
})
|
||||||
|
vim.lsp.enable('denols')
|
||||||
|
|
||||||
-- Инициализация "hrsh7th/vscode-langservers-extracted" (LSP-сервер для JSON)
|
-- Инициализация 'hrsh7th/vscode-langservers-extracted' (LSP-сервер для JSON)
|
||||||
lspconfig.jsonls.setup({
|
vim.lsp.config(
|
||||||
|
'jsonls',
|
||||||
|
{
|
||||||
on_attach = lspconfig_on_attach,
|
on_attach = lspconfig_on_attach,
|
||||||
coq.lsp_ensure_capabilities(),
|
coq.lsp_ensure_capabilities(),
|
||||||
capabilities = capabilities
|
capabilities = capabilities
|
||||||
})
|
})
|
||||||
|
vim.lsp.enable('jsonls')
|
||||||
|
|
||||||
-- Инициализация "luals/lua-language-server" (LSP-сервер для Lua)
|
-- Инициализация 'luals/lua-language-server' (LSP-сервер для Lua)
|
||||||
lspconfig.lua_ls.setup({
|
--[[ vim.lsp.config.lua_ls.setup({
|
||||||
settings = {
|
settings = {
|
||||||
Lua = {
|
Lua = {
|
||||||
runtime = {
|
runtime = {
|
||||||
@@ -106,7 +147,7 @@ lspconfig.lua_ls.setup({
|
|||||||
},
|
},
|
||||||
workspace = {
|
workspace = {
|
||||||
-- Make the server aware of Neovim runtime files
|
-- Make the server aware of Neovim runtime files
|
||||||
library = vim.api.nvim_get_runtime_file("", true),
|
library = vim.api.nvim_get_runtime_file('', true),
|
||||||
},
|
},
|
||||||
-- Do not send telemetry data containing a randomized but unique identifier
|
-- Do not send telemetry data containing a randomized but unique identifier
|
||||||
telemetry = {
|
telemetry = {
|
||||||
@@ -116,5 +157,7 @@ lspconfig.lua_ls.setup({
|
|||||||
},
|
},
|
||||||
on_attach = lspconfig_on_attach,
|
on_attach = lspconfig_on_attach,
|
||||||
coq.lsp_ensure_capabilities(),
|
coq.lsp_ensure_capabilities(),
|
||||||
capabilities = capabilities
|
capabilities = capabilities
|
||||||
})
|
})]]
|
||||||
|
end,
|
||||||
|
}
|
||||||
|
|||||||
@@ -1,44 +1,10 @@
|
|||||||
require('lspkind').init({
|
-- VSCode–style pictograms for Neovim completion items
|
||||||
-- defines how annotations are shown
|
return {
|
||||||
-- default: symbol
|
'onsails/lspkind-nvim',
|
||||||
-- options: 'text', 'text_symbol', 'symbol_text', 'symbol'
|
enabled = true,
|
||||||
mode = 'symbol_text',
|
lazy = true,
|
||||||
|
opts = {
|
||||||
-- default symbol map
|
mode = 'symbol',
|
||||||
-- can be either 'default' (requires nerd-fonts font) or
|
preset = 'default',
|
||||||
-- 'codicons' for codicon preset (requires vscode-codicons font)
|
}
|
||||||
--
|
}
|
||||||
-- default: 'default'
|
|
||||||
preset = 'codicons',
|
|
||||||
|
|
||||||
-- override preset symbols
|
|
||||||
--
|
|
||||||
-- default: {}
|
|
||||||
symbol_map = {
|
|
||||||
Text = "",
|
|
||||||
Method = "",
|
|
||||||
Function = "",
|
|
||||||
Constructor = "",
|
|
||||||
Field = "ﰠ",
|
|
||||||
Variable = "",
|
|
||||||
Class = "ﴯ",
|
|
||||||
Interface = "",
|
|
||||||
Module = "",
|
|
||||||
Property = "ﰠ",
|
|
||||||
Unit = "塞",
|
|
||||||
Value = "",
|
|
||||||
Enum = "",
|
|
||||||
Keyword = "",
|
|
||||||
Snippet = "",
|
|
||||||
Color = "",
|
|
||||||
File = "",
|
|
||||||
Reference = "",
|
|
||||||
Folder = "",
|
|
||||||
EnumMember = "",
|
|
||||||
Constant = "",
|
|
||||||
Struct = "פּ",
|
|
||||||
Event = "",
|
|
||||||
Operator = "",
|
|
||||||
TypeParameter = ""
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|||||||
@@ -1,6 +1,23 @@
|
|||||||
require('lualine').setup {
|
-- A blazing fast and easy to configure
|
||||||
options = {
|
-- neovim statusline plugin written in pure lua
|
||||||
icons_enabled = true,
|
-- @todo навести порядок
|
||||||
|
return {
|
||||||
|
'nvim-lualine/lualine.nvim',
|
||||||
|
enabled = true,
|
||||||
|
lazy = false,
|
||||||
|
priority = 80,
|
||||||
|
dependencies = {
|
||||||
|
-- Provides Nerd Font icons (glyphs) for use by neovim plugins
|
||||||
|
{ 'nvim-tree/nvim-web-devicons' },
|
||||||
|
|
||||||
|
-- LSP Progress lualine componenet
|
||||||
|
{ 'arkav/lualine-lsp-progress' },
|
||||||
|
|
||||||
|
-- A Git wrapper so awesome, it should be illegal
|
||||||
|
{ 'tpope/vim-fugitive' }
|
||||||
|
},
|
||||||
|
opts = {
|
||||||
|
icons_enabled = true,
|
||||||
theme = 'auto',
|
theme = 'auto',
|
||||||
component_separators = { left = '', right = ''},
|
component_separators = { left = '', right = ''},
|
||||||
section_separators = { left = '', right = ''},
|
section_separators = { left = '', right = ''},
|
||||||
@@ -11,17 +28,29 @@ require('lualine').setup {
|
|||||||
ignore_focus = {},
|
ignore_focus = {},
|
||||||
always_divide_middle = true,
|
always_divide_middle = true,
|
||||||
always_show_tabline = true,
|
always_show_tabline = true,
|
||||||
globalstatus = false,
|
globalstatus = true,
|
||||||
refresh = {
|
refresh = {
|
||||||
statusline = 100,
|
statusline = 1000,
|
||||||
tabline = 100,
|
tabline = 1000,
|
||||||
winbar = 100,
|
winbar = 1000,
|
||||||
|
refresh_time = 16, -- ~60fps
|
||||||
|
events = {
|
||||||
|
'WinEnter',
|
||||||
|
'BufEnter',
|
||||||
|
'BufWritePost',
|
||||||
|
'SessionLoadPost',
|
||||||
|
'FileChangedShellPost',
|
||||||
|
'VimResized',
|
||||||
|
'Filetype',
|
||||||
|
'CursorMoved',
|
||||||
|
'CursorMovedI',
|
||||||
|
'ModeChanged',
|
||||||
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
sections = {
|
sections = {
|
||||||
lualine_a = {
|
lualine_a = {
|
||||||
{
|
'mode',
|
||||||
'mode',
|
|
||||||
icons_enabled = true,
|
icons_enabled = true,
|
||||||
icon = nil,
|
icon = nil,
|
||||||
separator = nil,
|
separator = nil,
|
||||||
@@ -31,12 +60,11 @@ require('lualine').setup {
|
|||||||
padding = 1,
|
padding = 1,
|
||||||
fmt = nil,
|
fmt = nil,
|
||||||
on_click = nil,
|
on_click = nil,
|
||||||
}
|
},
|
||||||
},
|
|
||||||
lualine_b = {
|
lualine_b = {
|
||||||
'branch',
|
'branch',
|
||||||
'diff',
|
'diff',
|
||||||
{
|
{
|
||||||
'diagnostics',
|
'diagnostics',
|
||||||
sources = { 'coc' },
|
sources = { 'coc' },
|
||||||
sections = { 'error', 'warn', 'info', 'hint' },
|
sections = { 'error', 'warn', 'info', 'hint' },
|
||||||
@@ -51,9 +79,10 @@ require('lualine').setup {
|
|||||||
update_in_insert = false,
|
update_in_insert = false,
|
||||||
always_visible = false
|
always_visible = false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
lualine_c = {'filename', 'lsp_progress'},
|
lualine_c = {'filename', 'lsp_progress'},
|
||||||
lualine_x = {'encoding', 'fileformat', 'filetype'},
|
lualine_x = { FugitiveStatusline, 'encoding', 'fileformat', 'filetype'},
|
||||||
|
-- lualine_x = { FugitiveHead, 'encoding', 'fileformat', 'filetype'},
|
||||||
lualine_y = {'progress'},
|
lualine_y = {'progress'},
|
||||||
lualine_z = {'location'}
|
lualine_z = {'location'}
|
||||||
},
|
},
|
||||||
@@ -68,5 +97,9 @@ require('lualine').setup {
|
|||||||
tabline = {},
|
tabline = {},
|
||||||
winbar = {},
|
winbar = {},
|
||||||
inactive_winbar = {},
|
inactive_winbar = {},
|
||||||
extensions = {'nvim-dap-ui', 'trouble', 'neo-tree'}
|
extensions = {
|
||||||
|
'lazy',
|
||||||
|
'nvim-dap-ui',
|
||||||
|
'trouble',
|
||||||
|
'neo-tree'}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,9 @@
|
|||||||
-- Инициализация плагина
|
-- Create Neovim themes with real-time feedback, export anywhere
|
||||||
local lush = require('lush')
|
return {
|
||||||
|
'rktjmp/lush.nvim',
|
||||||
-- Инициализация ссылки на палитру
|
enabled = true,
|
||||||
local hsl = lush.hsl
|
lazy = false,
|
||||||
|
priority = 100,
|
||||||
-- Тема будет разработана позднее - не до неё сейчас
|
-- if you wish to use your own colorscheme:
|
||||||
|
-- { dir = '/absolute/path/to/colorscheme', lazy = true },
|
||||||
|
}
|
||||||
|
|||||||
@@ -1,48 +1,27 @@
|
|||||||
local highlights = require("neo-tree.ui.highlights")
|
-- Neovim plugin to manage the file system
|
||||||
|
-- and other tree like structures
|
||||||
require('neo-tree').setup({
|
return {
|
||||||
filesystem = {
|
'nvim-neo-tree/neo-tree.nvim',
|
||||||
components = {
|
enabled = true,
|
||||||
--[[
|
lazy = false,
|
||||||
icon = function(config, node, state)
|
priority = 60,
|
||||||
local icon = config.default or ' '
|
branch = 'v3.x',
|
||||||
local padding = config.padding or ' '
|
dependencies = {
|
||||||
local highlight = config.highlight or highlights.FILE_ICON
|
-- Lua functions
|
||||||
|
{ 'nvim-lua/plenary.nvim' },
|
||||||
if node.type == 'directory' then
|
|
||||||
highlight = highlights.DIRECTORY_ICON
|
-- Provides Nerd Font icons (glyphs) for use by neovim plugins
|
||||||
if node:is_expanded() then
|
{ 'nvim-tree/nvim-web-devicons' },
|
||||||
icon = config.folder_open or '-'
|
|
||||||
else
|
-- UI Component Library for Neovim
|
||||||
icon = config.folder_closed or '+'
|
{ 'MunifTanjim/nui.nvim' },
|
||||||
end
|
},
|
||||||
elseif node.type == 'file' then
|
opts = {
|
||||||
local success, web_devicons = pcall(require, 'nvim-web-devicons')
|
close_if_last_window = true,
|
||||||
if success then
|
clipboard = {
|
||||||
local devicon, hl = web_devicons.get_icon(node.name, node.ext)
|
sync = "global"
|
||||||
icon = devicon or icon
|
},
|
||||||
highlight = hl or highlight
|
enable_git_status = true,
|
||||||
end
|
enable_diagnostics = true
|
||||||
end
|
}
|
||||||
|
}
|
||||||
return {
|
|
||||||
text = icon .. padding,
|
|
||||||
highlight = highlight
|
|
||||||
}
|
|
||||||
end
|
|
||||||
},
|
|
||||||
]]
|
|
||||||
window = {
|
|
||||||
mappings = {
|
|
||||||
['o'] = 'system_open'
|
|
||||||
},
|
|
||||||
},
|
|
||||||
commands = {
|
|
||||||
-- Открытие файла через программу по умолчанию в операционной системе
|
|
||||||
system_open = function(state)
|
|
||||||
vim.api.nvim_command(string.format('silent !xdg-open \'%s\'', state.tree:get_node():get_id()))
|
|
||||||
end,
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|||||||
6
lua/plugins/nginx.lua
Normal file
6
lua/plugins/nginx.lua
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
-- Improved nginx vim plugin (incl. syntax highlighting)
|
||||||
|
return {
|
||||||
|
'chr4/nginx.vim',
|
||||||
|
enabled = true,
|
||||||
|
lazy = true
|
||||||
|
}
|
||||||
@@ -1,6 +1,13 @@
|
|||||||
require('nvim-web-devicons').setup {
|
-- Provides Nerd Font icons (glyphs) for use by neovim plugins
|
||||||
override = {},
|
return {
|
||||||
color_icons = true,
|
'nvim-tree/nvim-web-devicons',
|
||||||
default = true,
|
enabled = true,
|
||||||
strict = true
|
lazy = false,
|
||||||
|
priority = 110,
|
||||||
|
opts = {
|
||||||
|
override = {},
|
||||||
|
color_icons = true,
|
||||||
|
default = true,
|
||||||
|
strict = true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,219 +0,0 @@
|
|||||||
-- Инициализация
|
|
||||||
vim.cmd('packadd packer.nvim')
|
|
||||||
|
|
||||||
return require('packer').startup(function(use)
|
|
||||||
-- Менеджер плагинов Packer (автообновление)
|
|
||||||
use 'wbthomason/packer.nvim'
|
|
||||||
|
|
||||||
-- Flexoki colorscheme
|
|
||||||
use {
|
|
||||||
'nuvic/flexoki-nvim',
|
|
||||||
config = function() require('plugins/flexoki') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Быстрая настройка LSP-серверов
|
|
||||||
use {
|
|
||||||
'neovim/nvim-lspconfig',
|
|
||||||
after = 'coq_nvim',
|
|
||||||
config = function() require('plugins/lspconfig') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Прогресс LSP
|
|
||||||
use {
|
|
||||||
'j-hui/fidget.nvim',
|
|
||||||
config = function() require('plugins/fidget') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Интерфейс отображающий найденные проблемы LSP-серверами
|
|
||||||
use {
|
|
||||||
'folke/trouble.nvim',
|
|
||||||
requires = 'kyazdani42/nvim-web-devicons',
|
|
||||||
config = function() require('plugins/trouble') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Пиктограммы для плагинов
|
|
||||||
use {
|
|
||||||
'onsails/lspkind-nvim',
|
|
||||||
config = function() require('plugins/lspkind') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Пиктограммы для плагинов
|
|
||||||
use {
|
|
||||||
'nvim-tree/nvim-web-devicons',
|
|
||||||
config = function() require('plugins/nvim-web-devicons') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Интеграция с GIT
|
|
||||||
use {
|
|
||||||
'lewis6991/gitsigns.nvim',
|
|
||||||
config = function() require('plugins/gitsigns') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Обработчик GIT-команд
|
|
||||||
use 'tpope/vim-fugitive'
|
|
||||||
|
|
||||||
-- Отображение изменений GIT
|
|
||||||
use 'mhinz/vim-signify'
|
|
||||||
|
|
||||||
-- Отрисовка в реальном времени найденных ошибок LSP-серверами
|
|
||||||
use {
|
|
||||||
'onsails/diaglist.nvim',
|
|
||||||
config = function() require('plugins/diaglist') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Интерфейс строки состояния
|
|
||||||
use {
|
|
||||||
'nvim-lualine/lualine.nvim',
|
|
||||||
requires = 'kyazdani42/nvim-web-devicons',
|
|
||||||
config = function() require('plugins/lualine') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Дополнение для "nvim-lualine/lualine.nvim" с отображением прогресса работы с LSP-серверами
|
|
||||||
use {
|
|
||||||
'arkav/lualine-lsp-progress',
|
|
||||||
config = function() require('plugins/lualine-lsp-progress') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Интерфейс строки буфера файлов
|
|
||||||
use {
|
|
||||||
'akinsho/bufferline.nvim',
|
|
||||||
-- tag = "v3.*",
|
|
||||||
requires = 'nvim-tree/nvim-web-devicons',
|
|
||||||
config = function() require('plugins/bufferline') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Интерфейс древовидной структуры файлов
|
|
||||||
use {
|
|
||||||
'nvim-neo-tree/neo-tree.nvim',
|
|
||||||
-- branch = 'v2.x',
|
|
||||||
requires = {
|
|
||||||
'nvim-lua/plenary.nvim',
|
|
||||||
'kyazdani42/nvim-web-devicons',
|
|
||||||
'MunifTanjim/nui.nvim'
|
|
||||||
},
|
|
||||||
config = function() require('plugins/neo-tree') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Автодополнение скобок и кавычек
|
|
||||||
use {
|
|
||||||
'windwp/nvim-autopairs',
|
|
||||||
config = function() require('plugins/autopairs') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Цвета для отображения найденных ошибок LSP-сервером в случае если другие цвета не найдены
|
|
||||||
use 'folke/lsp-colors.nvim'
|
|
||||||
|
|
||||||
-- Автозавершение
|
|
||||||
use {
|
|
||||||
'ms-jpq/coq_nvim',
|
|
||||||
branch = 'coq',
|
|
||||||
config = function() require('plugins/coq') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Готовые наброски для автозавершения "ms-jpq/coq_nvim"
|
|
||||||
use {
|
|
||||||
'ms-jpq/coq.artifacts',
|
|
||||||
branch = 'artifacts'
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Пользовательские готовые наброски для автозавершения "ms-jpq/coq_nvim"
|
|
||||||
use {
|
|
||||||
'ms-jpq/coq.thirdparty',
|
|
||||||
branch = '3p'
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Линтер
|
|
||||||
use {
|
|
||||||
'mfussenegger/nvim-lint',
|
|
||||||
config = function() require('plugins/lint') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Тестирование
|
|
||||||
use {
|
|
||||||
'vim-test/vim-test',
|
|
||||||
config = function() require('plugins/vim-test') end
|
|
||||||
}
|
|
||||||
-- Functions for Telescope
|
|
||||||
use 'nvim-lua/plenary.nvim'
|
|
||||||
|
|
||||||
-- DAP integration for Telescope
|
|
||||||
use 'nvim-telescope/telescope-dap.nvim'
|
|
||||||
|
|
||||||
-- Fuzzy finder over lists (find, filter, preview, pick)
|
|
||||||
use {
|
|
||||||
'nvim-telescope/telescope.nvim',
|
|
||||||
tag = '0.1.8',
|
|
||||||
requires = {'nvim-lua/plenary.nvim'},
|
|
||||||
config = function() require('plugins/telescope') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- UI for Treesitter
|
|
||||||
use {
|
|
||||||
'nvim-treesitter/nvim-treesitter',
|
|
||||||
config = function() require('plugins/treesitter') end,
|
|
||||||
run = function()
|
|
||||||
local ts_update = require('nvim-treesitter.install').update({ with_sync = true })
|
|
||||||
ts_update()
|
|
||||||
end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Удобное комментирование
|
|
||||||
use 'b3nj5m1n/kommentary'
|
|
||||||
|
|
||||||
-- Древовидное представление символов
|
|
||||||
use {
|
|
||||||
'simrat39/symbols-outline.nvim',
|
|
||||||
config = function() require('plugins/symbols-outline') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Интерфейс для отображения тегов в отдельном окне
|
|
||||||
use 'preservim/tagbar'
|
|
||||||
|
|
||||||
-- PHP-теги для "preservim/tagbar" (phpctags для ctags)
|
|
||||||
use {
|
|
||||||
'vim-php/phpctags',
|
|
||||||
run = 'composer install'
|
|
||||||
}
|
|
||||||
|
|
||||||
-- LSP-сервер для Fish Shell
|
|
||||||
use 'dag/vim-fish'
|
|
||||||
|
|
||||||
-- Цветовая тема
|
|
||||||
use {
|
|
||||||
'rktjmp/lush.nvim',
|
|
||||||
config = function() require('plugins/lush') end
|
|
||||||
};
|
|
||||||
|
|
||||||
-- Аналог LSP-сервера для подержки синтаксиса nginx
|
|
||||||
use 'chr4/nginx.vim'
|
|
||||||
|
|
||||||
-- Форматировщик Prettier
|
|
||||||
use {
|
|
||||||
'prettier/vim-prettier',
|
|
||||||
branch = 'master',
|
|
||||||
-- run = 'sudo npm i -g',
|
|
||||||
run = 'yarn install --frozen-lockfile --production'
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Debug Adapter Protocol client implementation --
|
|
||||||
use {
|
|
||||||
'mfussenegger/nvim-dap',
|
|
||||||
config = function() require('plugins/dap') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Asynchronous IO --
|
|
||||||
use 'nvim-neotest/nvim-nio'
|
|
||||||
|
|
||||||
-- UI for DAP client implementation --
|
|
||||||
use {
|
|
||||||
'rcarriga/nvim-dap-ui',
|
|
||||||
requires = {"mfussenegger/nvim-dap", "nvim-neotest/nvim-nio"},
|
|
||||||
config = function() require('plugins/dapui') end
|
|
||||||
}
|
|
||||||
|
|
||||||
-- Virtual text support for DAP client implementation and Treesitter --
|
|
||||||
use {
|
|
||||||
'theHamsta/nvim-dap-virtual-text',
|
|
||||||
config = function() require('plugins/dap-text') end
|
|
||||||
}
|
|
||||||
end)
|
|
||||||
10
lua/plugins/reticle.lua
Normal file
10
lua/plugins/reticle.lua
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
-- Highlight only the screen line of the cursor
|
||||||
|
-- in the currently active window
|
||||||
|
return {
|
||||||
|
'tummetott/reticle.nvim',
|
||||||
|
enabled = true,
|
||||||
|
lazy = true,
|
||||||
|
event = 'VeryLazy',
|
||||||
|
opts = {
|
||||||
|
},
|
||||||
|
}
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
require('symbols-outline').setup({
|
|
||||||
--auto_preview = true,
|
|
||||||
--show_numbers = true
|
|
||||||
})
|
|
||||||
14
lua/plugins/tagbar.lua
Normal file
14
lua/plugins/tagbar.lua
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
-- Vim plugin that displays tags in a window, ordered by scope
|
||||||
|
return {
|
||||||
|
'preservim/tagbar',
|
||||||
|
enabled = true,
|
||||||
|
lazy = false,
|
||||||
|
priority = 40,
|
||||||
|
dependencies = {
|
||||||
|
-- An enhanced ctags compatible index generator written in pure PHP
|
||||||
|
{ 'vim-php/phpctags' },
|
||||||
|
|
||||||
|
-- jsctags generator using tern
|
||||||
|
{ 'sergioramos/jsctags' }
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,27 +1,27 @@
|
|||||||
-- Initializing
|
-- Find, Filter, Preview, Pick. All lua, all the time
|
||||||
local telescope = require('telescope');
|
-- Gaze deeply into unknown regions using the power of the moon
|
||||||
|
return {
|
||||||
|
'nvim-telescope/telescope.nvim',
|
||||||
|
enabled = true,
|
||||||
|
lazy = true,
|
||||||
|
tag = 'v0.2.0',
|
||||||
|
dependencies = {
|
||||||
|
-- Functions for Telescope
|
||||||
|
{ 'nvim-lua/plenary.nvim' },
|
||||||
|
|
||||||
-- Installing
|
-- Integration for nvim-dap with telescope.nvim
|
||||||
telescope.setup {
|
{ 'nvim-telescope/telescope-dap.nvim' }
|
||||||
pickers = {
|
},
|
||||||
-- Default configuration for builtin picikers goes here:
|
opts = {
|
||||||
-- picker_name = {
|
exteinsiions = {
|
||||||
-- picker_configi_key = value,
|
dap = {}
|
||||||
-- ...
|
}
|
||||||
-- }
|
},
|
||||||
-- Now the picker_config_key will be applied every time you call this
|
config = function()
|
||||||
-- builtin picker
|
-- Initializing telescope
|
||||||
},
|
local telescope = require('telescope')
|
||||||
|
|
||||||
exteinsiions = {
|
-- Loading extensions
|
||||||
-- Your extensioni configuration goes here:
|
telescope.load_extension('dap')
|
||||||
-- extension_name = {
|
end
|
||||||
-- extension_config_key = value,
|
|
||||||
-- }
|
|
||||||
-- please take a look at the readme of the extension you want to configure
|
|
||||||
dap = {}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
-- Loading extensions
|
|
||||||
telescope.load_extension('dap')
|
|
||||||
|
|||||||
@@ -1,7 +1,14 @@
|
|||||||
require('nvim-treesitter.configs').setup {
|
-- Nvim Treesitter configurations and abstraction layer
|
||||||
highlight = {
|
return {
|
||||||
enable = true,
|
'nvim-treesitter/nvim-treesitter',
|
||||||
-- additional_vim_regex_highlighting = false
|
enabled = true,
|
||||||
additional_vim_regex_highlighting = true
|
lazy = false,
|
||||||
},
|
priority = 40,
|
||||||
|
build = ':TSUpdate',
|
||||||
|
opts = {
|
||||||
|
highlight = {
|
||||||
|
enable = true,
|
||||||
|
additional_vim_regex_highlighting = true
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,65 +1,115 @@
|
|||||||
require('trouble').setup({
|
-- 🚦 A pretty diagnostics, references, telescope results,
|
||||||
position = "bottom", -- position of the list can be: bottom, top, left, right
|
-- quickfix and location list to help you solve
|
||||||
|
-- all the trouble your code is causing
|
||||||
|
return {
|
||||||
|
'folke/trouble.nvim',
|
||||||
|
enabled = true,
|
||||||
|
lazy = false,
|
||||||
|
priority = 20,
|
||||||
|
dependencies = {
|
||||||
|
-- Nvim Treesitter configurations and abstraction layer
|
||||||
|
{ 'nvim-treesitter/nvim-treesitter' },
|
||||||
|
|
||||||
|
-- Provides Nerd Font icons (glyphs) for use by neovim plugins
|
||||||
|
{ 'nvim-tree/nvim-web-devicons' }
|
||||||
|
},
|
||||||
|
opts = {
|
||||||
|
position = 'bottom', -- position of the list can be: bottom, top, left, right
|
||||||
height = 10, -- height of the trouble list when position is top or bottom
|
height = 10, -- height of the trouble list when position is top or bottom
|
||||||
width = 50, -- width of the list when position is left or right
|
width = 50, -- width of the list when position is left or right
|
||||||
icons = true, -- use devicons for filenames
|
icons = true, -- use devicons for filenames
|
||||||
mode = "workspace_diagnostics", -- "workspace_diagnostics", "document_diagnostics", "quickfix", "lsp_references", "loclist"
|
mode = 'workspace_diagnostics', -- 'workspace_diagnostics', 'document_diagnostics', 'quickfix', 'lsp_references', 'loclist'
|
||||||
fold_open = "", -- icon used for open folds
|
fold_open = '', -- icon used for open folds
|
||||||
fold_closed = "", -- icon used for closed folds
|
fold_closed = '', -- icon used for closed folds
|
||||||
group = true, -- group results by file
|
group = true, -- group results by file
|
||||||
padding = true, -- add an extra new line on top of the list
|
padding = true, -- add an extra new line on top of the list
|
||||||
action_keys = {
|
action_keys = {
|
||||||
-- key mappings for actions in the trouble list
|
-- key mappings for actions in the trouble list
|
||||||
-- map to {} to remove a mapping, for example:
|
-- map to {} to remove a mapping, for example:
|
||||||
-- close = {},
|
-- close = {},
|
||||||
close = "q", -- close the list
|
close = 'q', -- close the list
|
||||||
cancel = "<esc>", -- cancel the preview and get back to your last window / buffer / cursor
|
cancel = '<esc>', -- cancel the preview and get back to your last window / buffer / cursor
|
||||||
refresh = "r", -- manually refresh
|
refresh = 'r', -- manually refresh
|
||||||
jump = { "<cr>", "<tab>" }, -- jump to the diagnostic or open / close folds
|
jump = { '<cr>', '<tab>' }, -- jump to the diagnostic or open / close folds
|
||||||
open_split = { "<c-x>" }, -- open buffer in new split
|
open_split = { '<c-x>' }, -- open buffer in new split
|
||||||
open_vsplit = { "<c-v>" }, -- open buffer in new vsplit
|
open_vsplit = { '<c-v>' }, -- open buffer in new vsplit
|
||||||
open_tab = { "<c-t>" }, -- open buffer in new tab
|
open_tab = { '<c-t>' }, -- open buffer in new tab
|
||||||
jump_close = { "o" }, -- jump to the diagnostic and close the list
|
jump_close = { 'o' }, -- jump to the diagnostic and close the list
|
||||||
toggle_mode = "m", -- toggle between "workspace" and "document" diagnostics mode
|
toggle_mode = 'm', -- toggle between 'workspace' and 'document' diagnostics mode
|
||||||
toggle_preview = "P", -- toggle auto_preview
|
toggle_preview = 'P', -- toggle auto_preview
|
||||||
hover = "K", -- opens a small popup with the full multiline message
|
hover = 'K', -- opens a small popup with the full multiline message
|
||||||
preview = "p", -- preview the diagnostic location
|
preview = 'p', -- preview the diagnostic location
|
||||||
close_folds = { "zM", "zm" }, -- close all folds
|
close_folds = { 'zM', 'zm' }, -- close all folds
|
||||||
open_folds = { "zR", "zr" }, -- open all folds
|
open_folds = { 'zR', 'zr' }, -- open all folds
|
||||||
toggle_fold = { "zA", "za" }, -- toggle fold of current file
|
toggle_fold = { 'zA', 'za' }, -- toggle fold of current file
|
||||||
previous = "k", -- previous item
|
previous = 'k', -- previous item
|
||||||
next = "j" -- next item
|
next = 'j' -- next item
|
||||||
},
|
},
|
||||||
indent_lines = true, -- add an indent guide below the fold icons
|
indent_lines = true, -- add an indent guide below the fold icons
|
||||||
auto_open = false, -- automatically open the list when you have diagnostics
|
auto_open = false, -- automatically open the list when you have diagnostics
|
||||||
auto_close = false, -- automatically close the list when you have no diagnostics
|
auto_close = false, -- automatically close the list when you have no diagnostics
|
||||||
auto_preview = true, -- automatically preview the location of the diagnostic. <esc> to close preview and go back to last window
|
auto_preview = true, -- automatically preview the location of the diagnostic. <esc> to close preview and go back to last window
|
||||||
auto_fold = false, -- automatically fold a file trouble list at creation
|
auto_fold = false, -- automatically fold a file trouble list at creation
|
||||||
auto_jump = { "lsp_definitions" }, -- for the given modes, automatically jump if there is only a single result
|
auto_jump = { 'lsp_definitions' }, -- for the given modes, automatically jump if there is only a single result
|
||||||
signs = {
|
signs = {
|
||||||
-- icons / text used for a diagnostic
|
-- icons / text used for a diagnostic
|
||||||
error = "",
|
error = '',
|
||||||
warning = "",
|
warning = '',
|
||||||
hint = "",
|
hint = '',
|
||||||
information = "",
|
information = '',
|
||||||
other = ""
|
other = ''
|
||||||
},
|
},
|
||||||
use_diagnostic_signs = false -- enabling this will use the signs defined in your lsp client
|
use_diagnostic_signs = false -- enabling this will use the signs defined in your lsp client
|
||||||
})
|
},
|
||||||
|
config = function()
|
||||||
-- Initializing Telescope
|
-- Initializing Telescope
|
||||||
local telescope = require("telescope")
|
local telescope = require('telescope')
|
||||||
local telescope_actions = require("telescope.actions")
|
local telescope_actions = require('telescope.actions')
|
||||||
local telescope_open = require("trouble.sources.telescope").open
|
local telescope_open = require('trouble.sources.telescope').open
|
||||||
|
|
||||||
-- Use this to add more results without clearing the trouble list
|
-- Use this to add more results without clearing the trouble list
|
||||||
local add_to_trouble = require("trouble.sources.telescope").add
|
local add_to_trouble = require('trouble.sources.telescope').add
|
||||||
|
|
||||||
telescope.setup({
|
telescope.setup({
|
||||||
defaults = {
|
defaults = {
|
||||||
mappings = {
|
mappings = {
|
||||||
i = { ["<c-t>"] = telescope_open },
|
i = { ['<c-t>'] = telescope_open },
|
||||||
n = { ["<c-t>"] = telescope_open },
|
n = { ['<c-t>'] = telescope_open },
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
end,
|
||||||
|
cmd = 'Trouble',
|
||||||
|
keys = {
|
||||||
|
{
|
||||||
|
'<leader>xx',
|
||||||
|
'<cmd>Trouble diagnostics toggle<cr>',
|
||||||
|
desc = 'Diagnostics (Trouble)',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
'<leader>xX',
|
||||||
|
'<cmd>Trouble diagnostics toggle filter.buf=0<cr>',
|
||||||
|
desc = 'Buffer Diagnostics (Trouble)',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
'<leader>cs',
|
||||||
|
'<cmd>Trouble symbols toggle focus=false<cr>',
|
||||||
|
desc = 'Symbols (Trouble)',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
'<leader>cl',
|
||||||
|
'<cmd>Trouble lsp toggle focus=false win.position=right<cr>',
|
||||||
|
desc = 'LSP Definitions / references / ... (Trouble)',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
'<leader>xL',
|
||||||
|
'<cmd>Trouble loclist toggle<cr>',
|
||||||
|
desc = 'Location List (Trouble)',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
'<leader>xQ',
|
||||||
|
'<cmd>Trouble qflist toggle<cr>',
|
||||||
|
desc = 'Quickfix List (Trouble)',
|
||||||
|
},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
6
lua/plugins/vim-fish.lua
Normal file
6
lua/plugins/vim-fish.lua
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
-- Run your tests at the speed of thought
|
||||||
|
return {
|
||||||
|
'vim-test/vim-test',
|
||||||
|
enabled = true,
|
||||||
|
lazy = true
|
||||||
|
}
|
||||||
6
lua/plugins/vim-fugitive.lua
Normal file
6
lua/plugins/vim-fugitive.lua
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
-- A Git wrapper so awesome, it should be illegal
|
||||||
|
return {
|
||||||
|
'tpope/vim-fugitive',
|
||||||
|
enabled = true,
|
||||||
|
lazy = true
|
||||||
|
}
|
||||||
6
lua/plugins/vim-signify.lua
Normal file
6
lua/plugins/vim-signify.lua
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
-- ➕ Show a diff using Vim its sign column
|
||||||
|
return {
|
||||||
|
'mhinz/vim-signify',
|
||||||
|
enabled = true,
|
||||||
|
lazy = true
|
||||||
|
}
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
-- Vim support for editing fish scripts
|
||||||
|
return {
|
||||||
|
'dag/vim-fish',
|
||||||
|
enabled = true,
|
||||||
|
lazy = true
|
||||||
|
}
|
||||||
|
|||||||
40
lua/settings/lazy.lua
Normal file
40
lua/settings/lazy.lua
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
-- Bootstrap lazy.nvim
|
||||||
|
local path = vim.fn.stdpath('data') .. '/lazy/lazy.nvim'
|
||||||
|
|
||||||
|
if not (vim.uv or vim.loop).fs_stat(path) then
|
||||||
|
local repository = 'https://github.com/folke/lazy.nvim.git'
|
||||||
|
local out = vim.fn.system({ 'git', 'clone', '--filter=blob:none', '--branch=stable', repository, path })
|
||||||
|
|
||||||
|
if vim.v.shell_error ~= 0 then
|
||||||
|
vim.api.nvim_echo({
|
||||||
|
{ 'Failed to clone lazy.nvim:\n', 'ErrorMsg' },
|
||||||
|
{ out, 'WarningMsg' },
|
||||||
|
{ '\nPress any key to exit...' },
|
||||||
|
}, true, {})
|
||||||
|
|
||||||
|
vim.fn.getchar()
|
||||||
|
|
||||||
|
os.exit(1)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
vim.opt.rtp:prepend(path)
|
||||||
|
|
||||||
|
-- Setup lazy.nvim
|
||||||
|
require('lazy').setup({
|
||||||
|
-- Import plugins
|
||||||
|
spec = {
|
||||||
|
{ import = 'plugins' },
|
||||||
|
},
|
||||||
|
|
||||||
|
-- Configure any other settings here. See the documentation for more details.
|
||||||
|
-- colorscheme that will be used when installing plugins.
|
||||||
|
install = {
|
||||||
|
colorscheme = { 'flexoki' }
|
||||||
|
},
|
||||||
|
|
||||||
|
-- Automatically check for plugin updates
|
||||||
|
checker = {
|
||||||
|
enabled = true
|
||||||
|
},
|
||||||
|
})
|
||||||
@@ -1,3 +1,7 @@
|
|||||||
|
-- Leader button
|
||||||
|
vim.g.mapleader = " "
|
||||||
|
vim.g.maplocalleader = "\\"
|
||||||
|
|
||||||
-- Использовать системный буфер обмена
|
-- Использовать системный буфер обмена
|
||||||
vim.opt.clipboard = 'unnamedplus'
|
vim.opt.clipboard = 'unnamedplus'
|
||||||
|
|
||||||
@@ -28,9 +32,7 @@ vim.opt_local.cursorcolumn = true
|
|||||||
-- Theme
|
-- Theme
|
||||||
vim.opt.background = "dark"
|
vim.opt.background = "dark"
|
||||||
|
|
||||||
-- Colorscheme
|
-- Colorscheme @see plugin "flexoki"
|
||||||
-- vim.cmd.colorscheme('default')
|
|
||||||
-- vim.cmd.colorscheme('koehler')
|
|
||||||
vim.cmd.colorscheme('vim')
|
vim.cmd.colorscheme('vim')
|
||||||
|
|
||||||
-- Добавление ru_RU (переключать через <c-^>)
|
-- Добавление ru_RU (переключать через <c-^>)
|
||||||
@@ -48,3 +50,7 @@ vim.opt_local.spelllang = 'ru_yo,en_us'
|
|||||||
vim.g.markdown_fenced_languages = {
|
vim.g.markdown_fenced_languages = {
|
||||||
"ts=typescript"
|
"ts=typescript"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
-- Syntax hightlighting
|
||||||
|
vim.cmd('syntax on')
|
||||||
|
vim.cmd('filetype plugin on')
|
||||||
|
|||||||
Reference in New Issue
Block a user