winbar
This commit is contained in:
@@ -0,0 +1 @@
|
||||
require("tiny-inline-diagnostic").setup({})
|
||||
@@ -0,0 +1,73 @@
|
||||
require("actions-preview").setup {
|
||||
-- options for vim.diff(): https://neovim.io/doc/user/lua.html#vim.diff()
|
||||
diff = {
|
||||
ctxlen = 3,
|
||||
},
|
||||
|
||||
highlight_command = {
|
||||
-- require("actions-preview.highlight").delta(),
|
||||
-- require("actions-preview.highlight").diff_so_fancy(),
|
||||
-- require("actions-preview.highlight").diff_highlight(),
|
||||
},
|
||||
|
||||
-- priority list of preferred backend
|
||||
backend = { "snacks", "nui" },
|
||||
|
||||
-- options related to telescope.nvim
|
||||
telescope = vim.tbl_extend(
|
||||
"force",
|
||||
require("telescope.themes").get_dropdown(),
|
||||
-- a table for customizing content
|
||||
{
|
||||
-- a function to make a table containing the values to be displayed.
|
||||
-- fun(action: Action): { title: string, client_name: string|nil }
|
||||
make_value = nil,
|
||||
|
||||
-- a function to make a function to be used in `display` of a entry.
|
||||
-- see also `:h telescope.make_entry` and `:h telescope.pickers.entry_display`.
|
||||
-- fun(values: { index: integer, action: Action, title: string, client_name: string }[]): function
|
||||
make_make_display = nil,
|
||||
}
|
||||
),
|
||||
|
||||
-- options for nui.nvim components
|
||||
nui = {
|
||||
-- component direction. "col" or "row"
|
||||
dir = "col",
|
||||
-- keymap for selection component: https://github.com/MunifTanjim/nui.nvim/tree/main/lua/nui/menu#keymap
|
||||
keymap = nil,
|
||||
-- options for nui Layout component: https://github.com/MunifTanjim/nui.nvim/tree/main/lua/nui/layout
|
||||
layout = {
|
||||
position = "50%",
|
||||
size = {
|
||||
width = "60%",
|
||||
height = "100%",
|
||||
},
|
||||
min_width = 40,
|
||||
min_height = 10,
|
||||
relative = "editor",
|
||||
},
|
||||
-- options for preview area: https://github.com/MunifTanjim/nui.nvim/tree/main/lua/nui/popup
|
||||
preview = {
|
||||
size = "80%",
|
||||
border = {
|
||||
style = "rounded",
|
||||
padding = { 0, 1 },
|
||||
},
|
||||
},
|
||||
-- options for selection area: https://github.com/MunifTanjim/nui.nvim/tree/main/lua/nui/menu
|
||||
select = {
|
||||
size = "20%",
|
||||
border = {
|
||||
style = "rounded",
|
||||
padding = { 0, 1 },
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
--- options for snacks picker
|
||||
---@type snacks.picker.Config
|
||||
snacks = {
|
||||
layout = { preset = "default" },
|
||||
},
|
||||
}
|
||||
+24
-24
@@ -1,37 +1,37 @@
|
||||
require("auto-session").setup ({
|
||||
{
|
||||
enabled = true,
|
||||
root_dir = vim.fn.stdpath "data" .. "/sessions/",
|
||||
auto_save = true,
|
||||
auto_restore = true,
|
||||
auto_create = true,
|
||||
suppressed_dirs = nil,
|
||||
allowed_dirs = nil,
|
||||
auto_restore_last_session = false,
|
||||
use_git_branch = false,
|
||||
lazy_support = true,
|
||||
bypass_save_filetypes = nil,
|
||||
close_unsupported_windows = true,
|
||||
args_allow_single_directory = true,
|
||||
args_allow_files_auto_save = false,
|
||||
continue_restore_on_error = true,
|
||||
show_auto_restore_notif = false,
|
||||
cwd_change_handling = false,
|
||||
lsp_stop_on_restore = false,
|
||||
log_level = "error",
|
||||
enabled = true,
|
||||
root_dir = vim.fn.stdpath "data" .. "/sessions/",
|
||||
auto_save = true,
|
||||
auto_restore = true,
|
||||
auto_create = true,
|
||||
suppressed_dirs = nil,
|
||||
allowed_dirs = nil,
|
||||
auto_restore_last_session = false,
|
||||
use_git_branch = false,
|
||||
lazy_support = true,
|
||||
bypass_save_filetypes = nil,
|
||||
close_unsupported_windows = true,
|
||||
args_allow_single_directory = true,
|
||||
args_allow_files_auto_save = false,
|
||||
continue_restore_on_error = true,
|
||||
show_auto_restore_notif = false,
|
||||
cwd_change_handling = false,
|
||||
lsp_stop_on_restore = false,
|
||||
log_level = "error",
|
||||
session_lens = {
|
||||
load_on_setup = true,
|
||||
theme_conf = {
|
||||
load_on_setup = true,
|
||||
theme_conf = {
|
||||
},
|
||||
previewer = false,
|
||||
previewer = false,
|
||||
mappings = {
|
||||
delete_session = { "i", "<C-D>" },
|
||||
alternate_session = { "i", "<C-S>" },
|
||||
copy_session = { "i", "<C-Y>" },
|
||||
},
|
||||
session_control = {
|
||||
control_dir = vim.fn.stdpath "data" .. "/auto_session/",
|
||||
control_filename = "session_control.json",
|
||||
control_dir = vim.fn.stdpath "data" .. "/auto_session/",
|
||||
control_filename = "session_control.json",
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
return {
|
||||
"yarospace/dev-tools.nvim",
|
||||
opts = {
|
||||
actions = {},
|
||||
|
||||
filetypes = {
|
||||
include = {},
|
||||
exclude = {},
|
||||
},
|
||||
|
||||
builtin_actions = {
|
||||
include = {},
|
||||
exclude = {},
|
||||
},
|
||||
|
||||
action_opts = {
|
||||
{
|
||||
group = "Debuggins",
|
||||
name = "Log vars under cursor",
|
||||
opts = {
|
||||
keymap = {
|
||||
global = "<leader>dl",
|
||||
picker = "<M-l>",
|
||||
hide = true,
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
ui = {
|
||||
override = true,
|
||||
group_actions = true,
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
return {
|
||||
"Bekaboo/dropbar.nvim",
|
||||
dependencies = {
|
||||
"nvim-telescope/telescope-fzf-native.nvim",
|
||||
run = "make"
|
||||
},
|
||||
|
||||
opts = {
|
||||
bar = {
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
require("lint").linters_by_ft = {
|
||||
javascript = { "eslint" },
|
||||
javascriptreact = { "eslint" },
|
||||
typescript = { "eslint" },
|
||||
typescriptreact = { "eslint" },
|
||||
lua = { "luacheck" },
|
||||
python = { "pylint" },
|
||||
go = { "golangci_lint" },
|
||||
rust = { "clippy" },
|
||||
zsh = { "zsh" },
|
||||
sh = { "zsh" },
|
||||
bash = { "zsh" },
|
||||
cpp = { "cpplint" },
|
||||
markdown = { "markdownlint" },
|
||||
json = { "jsonlint" },
|
||||
yaml = { "yamllint" },
|
||||
qml = { "qmllint" },
|
||||
}
|
||||
|
||||
local default_severity = {
|
||||
['error'] = vim.diagnostic.severity.ERROR,
|
||||
['warning'] = vim.diagnostic.severity.WARN,
|
||||
['information'] = vim.diagnostic.severity.INFO,
|
||||
['hint'] = vim.diagnostic.severity.HINT,
|
||||
}
|
||||
require("lint").linters.qmllint = {
|
||||
name = "qmllint",
|
||||
cmd = "qmllint",
|
||||
stdin = true,
|
||||
append_fname = true,
|
||||
args = {},
|
||||
stream = nil,
|
||||
ignore_exitcode = true,
|
||||
env = nil,
|
||||
parser = require("lint.parser").from_pattern(
|
||||
"([^:]+):(%d+) : (.+)",
|
||||
{ "filename", "lnum", "message" },
|
||||
default_severity,
|
||||
{[ "source" ] = "qmllint" }
|
||||
)
|
||||
}
|
||||
@@ -1,3 +1,17 @@
|
||||
local function flatten_to_array(t)
|
||||
local res = {}
|
||||
local function _flatten(tbl)
|
||||
for _, v in ipairs(tbl) do
|
||||
if type(v) == "table" then
|
||||
_flatten(v)
|
||||
else
|
||||
table.insert(res, v)
|
||||
end
|
||||
end
|
||||
end
|
||||
_flatten(t)
|
||||
return res
|
||||
end
|
||||
local cmp = require("cmp")
|
||||
local cmp_lsp = require("cmp_nvim_lsp")
|
||||
local capabilities = vim.tbl_deep_extend(
|
||||
@@ -229,8 +243,16 @@ local servers = {
|
||||
"sourcekit",
|
||||
"qmlls",
|
||||
"tailwindcss",
|
||||
require("mason-lspconfig").get_installed_servers(),
|
||||
}
|
||||
|
||||
for _, server in ipairs(servers) do
|
||||
local flat_servers = flatten_to_array(servers)
|
||||
|
||||
for _, server in ipairs(flat_servers) do
|
||||
lspconfig(server, {
|
||||
on_attach = function(client, bufnr)
|
||||
require("workspace-diagnostics").populate_workspace_diagnostics( client, bufnr )
|
||||
end,
|
||||
})
|
||||
lspenable(server)
|
||||
end
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
require("lspsaga").setup({
|
||||
|
||||
symbol_in_winbar = {
|
||||
enable = false,
|
||||
},
|
||||
|
||||
ui = {
|
||||
code_action = " ",
|
||||
}
|
||||
})
|
||||
+13
-1
@@ -75,6 +75,14 @@ local virtual_env = function()
|
||||
end
|
||||
end
|
||||
|
||||
local lint_progress = function()
|
||||
local linters = require("lint").get_running()
|
||||
if #linters == 0 then
|
||||
return ""
|
||||
end
|
||||
return table.concat(linters, ", ")
|
||||
end
|
||||
|
||||
require("lualine").setup {
|
||||
laststatus = 0,
|
||||
options = {
|
||||
@@ -132,9 +140,13 @@ require("lualine").setup {
|
||||
ime_state,
|
||||
color = { fg = "black", bg = "#f46868" },
|
||||
},
|
||||
{
|
||||
lint_progress,
|
||||
icon = " ",
|
||||
},
|
||||
{
|
||||
get_active_lsp,
|
||||
icon = " LSP:",
|
||||
icon = " ",
|
||||
},
|
||||
{
|
||||
"diagnostics",
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@ require("tmux").setup({
|
||||
copy_sync = {
|
||||
enable = true,
|
||||
redirect_to_clipboard = true,
|
||||
sync_clipboard = true,
|
||||
sync_clipboard = false,
|
||||
sync_registers = true,
|
||||
},
|
||||
navigation = {
|
||||
|
||||
Reference in New Issue
Block a user