mirror of
https://github.com/LunarVim/LunarVim.git
synced 2025-08-03 01:25:03 +02:00
refactor plugin config
This commit is contained in:
parent
0ce8dfd998
commit
b8182d5aee
15 changed files with 259 additions and 243 deletions
5
init.lua
5
init.lua
|
@ -6,10 +6,7 @@ require "plugins"
|
|||
vim.g.colors_name = O.colorscheme -- Colorscheme must get called after plugins are loaded or it will break new installs.
|
||||
require "lv-utils"
|
||||
require "lv-treesitter"
|
||||
if O.plugin.dashboard.active then
|
||||
require("lv-dashboard").config()
|
||||
end
|
||||
-- TODO these gues need to be in language files
|
||||
-- TODO these guys need to be in language files
|
||||
-- require "lsp"
|
||||
-- if O.lang.emmet.active then
|
||||
-- require "lsp.emmet-ls"
|
||||
|
|
|
@ -72,8 +72,6 @@ O = {
|
|||
|
||||
plugin = {
|
||||
-- Builtins
|
||||
dashboard = { active = false },
|
||||
-- zen = { active = false },
|
||||
ts_playground = { active = false },
|
||||
ts_context_commentstring = { active = false },
|
||||
ts_hintobjects = { active = false },
|
||||
|
@ -88,7 +86,6 @@ O = {
|
|||
dap_install = { active = false },
|
||||
lush = { active = false },
|
||||
diffview = { active = false },
|
||||
floatterm = { active = false },
|
||||
},
|
||||
|
||||
user_which_key = {},
|
||||
|
@ -234,32 +231,12 @@ O = {
|
|||
vim = {},
|
||||
yaml = {},
|
||||
},
|
||||
|
||||
dashboard = {
|
||||
|
||||
custom_header = {
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣀⣀⣀⣀⣀⣀⣀⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣠⣤⣶⣾⠿⠿⠟⠛⠛⠛⠛⠿⠿⣿⣷⣤⣄⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
" ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣠⣾⡿⠋⠉⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠙⠿⣷⣤⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣤⡿⠛⠉⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠉⠛⢿⣦⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⡠⠒⠂⠉⠉⠉⠉⢩⣿⡿⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠹⣷⡄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠸⡀⠀⠀⠀⠀⠀⢰⣿⠋⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠙⣿⣧⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠑⠠⡀⠀⠀⢀⣾⠋⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠘⣿⡆⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠢⢀⣸⡟⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢹⣇⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⡧⢄⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⣿⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⡇⠀⠈⠁⠒⠤⣀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⣿⣀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⣇⠀⠀⠀⠀⠀⠀⠉⠢⠤⠀⢀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣸⡟⠈⠑⠄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢿⡄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠉⠑⠒⠤⣀⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢠⣿⡇⠀⠀⢀⣣⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⣿⡟⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠸⣷⡄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠉⠀⠀⠒⠢⠤⠄⣀⣀⠀⠀⠀⢠⣿⡟⠀⠀⠀⣺⣿⡿⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⣿⠇⠀⠀⠀⠀⠀⣤⡄⠀⠀⢠⣤⡄⠀⢨⣭⣠⣤⣤⣤⡀⠀⠀⢀⣤⣤⣤⣤⡄⠀⠀⠀⣤⣄⣤⣤⣤⠀⠀⣿⣯⠉⠉⣿⡟⠀⠈⢩⣭⣤⣤⠀⠀⠀⠀⣠⣤⣤⣤⣄⣤⣤",
|
||||
"⢠⣿⠀⠀⠀⠀⠀⠀⣿⠃⠀⠀⣸⣿⠁⠀⣿⣿⠉⠀⠈⣿⡇⠀⠀⠛⠋⠀⠀⢹⣿⠀⠀⠀⣿⠏⠀⠸⠿⠃⠀⣿⣿⠀⣰⡟⠀⠀⠀⠀⠀⢸⣿⠀⠀⠀⠀⣿⡟⢸⣿⡇⢀⣿",
|
||||
"⣸⡇⠀⠀⠀⠀⠀⢸⣿⠀⠀⠀⣿⡟⠀⢠⣿⡇⠀⠀⢰⣿⡇⠀⣰⣾⠟⠛⠛⣻⡇⠀⠀⢸⡿⠀⠀⠀⠀⠀⠀⢻⣿⢰⣿⠀⠀⠀⠀⠀⠀⣾⡇⠀⠀⠀⢸⣿⠇⢸⣿⠀⢸⡏",
|
||||
"⣿⣧⣤⣤⣤⡄⠀⠘⣿⣤⣤⡤⣿⠇⠀⢸⣿⠁⠀⠀⣼⣿⠀⠀⢿⣿⣤⣤⠔⣿⠃⠀⠀⣾⡇⠀⠀⠀⠀⠀⠀⢸⣿⣿⠋⠀⠀⠀⢠⣤⣤⣿⣥⣤⡄⠀⣼⣿⠀⣸⡏⠀⣿⠃",
|
||||
"⠉⠉⠉⠉⠉⠁⠀⠀⠈⠉⠉⠀⠉⠀⠀⠈⠉⠀⠀⠀⠉⠉⠀⠀⠀⠉⠉⠁⠈⠉⠀⠀⠀⠉⠀⠀⠀⠀⠀⠀⠀⠈⠉⠉⠀⠀⠀⠀⠈⠉⠉⠉⠉⠉⠁⠀⠉⠁⠀⠉⠁⠀⠉⠀",
|
||||
},
|
||||
footer = { "chrisatmachine.com" },
|
||||
},
|
||||
}
|
||||
|
||||
require "lv-zen.config"
|
||||
require "lv-compe.config"
|
||||
require "lv-dashboard.config"
|
||||
require "lv-floatterm.config"
|
||||
require "lv-galaxyline.config"
|
||||
require "lv-gitsigns.config"
|
||||
require "lv-telescope.config"
|
||||
|
|
|
@ -0,0 +1,49 @@
|
|||
O.plugin.dashboard = {
|
||||
active = false,
|
||||
search_handler = "telescope",
|
||||
custom_header = {
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣀⣀⣀⣀⣀⣀⣀⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣠⣤⣶⣾⠿⠿⠟⠛⠛⠛⠛⠿⠿⣿⣷⣤⣄⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
" ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣠⣾⡿⠋⠉⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠙⠿⣷⣤⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣤⡿⠛⠉⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠉⠛⢿⣦⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⡠⠒⠂⠉⠉⠉⠉⢩⣿⡿⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠹⣷⡄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠸⡀⠀⠀⠀⠀⠀⢰⣿⠋⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠙⣿⣧⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠑⠠⡀⠀⠀⢀⣾⠋⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠘⣿⡆⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠢⢀⣸⡟⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢹⣇⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⡧⢄⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⣿⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⡇⠀⠈⠁⠒⠤⣀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⣿⣀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⣇⠀⠀⠀⠀⠀⠀⠉⠢⠤⠀⢀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣸⡟⠈⠑⠄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢿⡄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠉⠑⠒⠤⣀⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢠⣿⡇⠀⠀⢀⣣⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⣿⡟⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠸⣷⡄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠉⠀⠀⠒⠢⠤⠄⣀⣀⠀⠀⠀⢠⣿⡟⠀⠀⠀⣺⣿⡿⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀",
|
||||
"⠀⣿⠇⠀⠀⠀⠀⠀⣤⡄⠀⠀⢠⣤⡄⠀⢨⣭⣠⣤⣤⣤⡀⠀⠀⢀⣤⣤⣤⣤⡄⠀⠀⠀⣤⣄⣤⣤⣤⠀⠀⣿⣯⠉⠉⣿⡟⠀⠈⢩⣭⣤⣤⠀⠀⠀⠀⣠⣤⣤⣤⣄⣤⣤",
|
||||
"⢠⣿⠀⠀⠀⠀⠀⠀⣿⠃⠀⠀⣸⣿⠁⠀⣿⣿⠉⠀⠈⣿⡇⠀⠀⠛⠋⠀⠀⢹⣿⠀⠀⠀⣿⠏⠀⠸⠿⠃⠀⣿⣿⠀⣰⡟⠀⠀⠀⠀⠀⢸⣿⠀⠀⠀⠀⣿⡟⢸⣿⡇⢀⣿",
|
||||
"⣸⡇⠀⠀⠀⠀⠀⢸⣿⠀⠀⠀⣿⡟⠀⢠⣿⡇⠀⠀⢰⣿⡇⠀⣰⣾⠟⠛⠛⣻⡇⠀⠀⢸⡿⠀⠀⠀⠀⠀⠀⢻⣿⢰⣿⠀⠀⠀⠀⠀⠀⣾⡇⠀⠀⠀⢸⣿⠇⢸⣿⠀⢸⡏",
|
||||
"⣿⣧⣤⣤⣤⡄⠀⠘⣿⣤⣤⡤⣿⠇⠀⢸⣿⠁⠀⠀⣼⣿⠀⠀⢿⣿⣤⣤⠔⣿⠃⠀⠀⣾⡇⠀⠀⠀⠀⠀⠀⢸⣿⣿⠋⠀⠀⠀⢠⣤⣤⣿⣥⣤⡄⠀⣼⣿⠀⣸⡏⠀⣿⠃",
|
||||
"⠉⠉⠉⠉⠉⠁⠀⠀⠈⠉⠉⠀⠉⠀⠀⠈⠉⠀⠀⠀⠉⠉⠀⠀⠀⠉⠉⠁⠈⠉⠀⠀⠀⠉⠀⠀⠀⠀⠀⠀⠀⠈⠉⠉⠀⠀⠀⠀⠈⠉⠉⠉⠉⠉⠁⠀⠉⠁⠀⠉⠁⠀⠉⠀",
|
||||
},
|
||||
|
||||
custom_section = {
|
||||
a = {
|
||||
description = { " Find File " },
|
||||
command = "Telescope find_files",
|
||||
},
|
||||
b = {
|
||||
description = { " Recently Used Files" },
|
||||
command = "Telescope oldfiles",
|
||||
},
|
||||
-- c = {
|
||||
-- description = { " Load Last Session " },
|
||||
-- command = "SessionLoad",
|
||||
-- },
|
||||
c = {
|
||||
description = { " Find Word " },
|
||||
command = "Telescope live_grep",
|
||||
},
|
||||
d = {
|
||||
description = { " Settings " },
|
||||
command = ":e " .. CONFIG_PATH .. "/lv-config.lua",
|
||||
},
|
||||
},
|
||||
|
||||
footer = { "chrisatmachine.com" },
|
||||
}
|
|
@ -3,37 +3,17 @@ local M = {}
|
|||
M.config = function()
|
||||
vim.g.dashboard_disable_at_vimenter = 0
|
||||
|
||||
vim.g.dashboard_custom_header = O.dashboard.custom_header
|
||||
vim.g.dashboard_custom_header = O.plugin.dashboard.custom_header
|
||||
|
||||
vim.g.dashboard_default_executive = "telescope"
|
||||
vim.g.dashboard_default_executive = O.plugin.dashboard.search_handler
|
||||
|
||||
vim.g.dashboard_custom_section = O.plugin.dashboard.custom_section
|
||||
|
||||
vim.g.dashboard_custom_section = {
|
||||
a = {
|
||||
description = { " Find File " },
|
||||
command = "Telescope find_files",
|
||||
},
|
||||
b = {
|
||||
description = { " Recently Used Files" },
|
||||
command = "Telescope oldfiles",
|
||||
},
|
||||
-- c = {
|
||||
-- description = { " Load Last Session " },
|
||||
-- command = "SessionLoad",
|
||||
-- },
|
||||
c = {
|
||||
description = { " Find Word " },
|
||||
command = "Telescope live_grep",
|
||||
},
|
||||
d = {
|
||||
description = { " Settings " },
|
||||
command = ":e " .. CONFIG_PATH .. "/lv-config.lua",
|
||||
},
|
||||
-- f = {
|
||||
-- description = { " Neovim Config Files" },
|
||||
-- command = "Telescope find_files cwd=" .. CONFIG_PATH,
|
||||
-- },
|
||||
-- e = {description = {' Marks '}, command = 'Telescope marks'}
|
||||
}
|
||||
vim.cmd "let g:dashboard_session_directory = $HOME..'/.config/nvim/.sessions'"
|
||||
vim.cmd "let packages = len(globpath('~/.local/share/nvim/site/pack/packer/start', '*', 0, 1))"
|
||||
|
||||
|
|
10
lua/lv-floatterm/config.lua
Normal file
10
lua/lv-floatterm/config.lua
Normal file
|
@ -0,0 +1,10 @@
|
|||
O.plugin.floatterm = {
|
||||
active = false,
|
||||
dimensions = {
|
||||
height = 0.9,
|
||||
width = 0.9,
|
||||
x = 0.5,
|
||||
y = 0.3,
|
||||
},
|
||||
border = "single", -- or 'double'
|
||||
}
|
|
@ -6,26 +6,13 @@ M.config = function()
|
|||
return
|
||||
end
|
||||
|
||||
fterm.setup {
|
||||
dimensions = {
|
||||
height = 0.8,
|
||||
width = 0.8,
|
||||
x = 0.5,
|
||||
y = 0.5,
|
||||
},
|
||||
border = "single", -- or 'double'
|
||||
}
|
||||
fterm.setup(O.plugin.floatterm)
|
||||
|
||||
-- Create LazyGit Terminal
|
||||
local term = require "FTerm.terminal"
|
||||
local lazy = term:new():setup {
|
||||
cmd = "lazygit",
|
||||
dimensions = {
|
||||
height = 0.9,
|
||||
width = 0.9,
|
||||
x = 0.5,
|
||||
y = 0.3,
|
||||
},
|
||||
dimensions = O.plugin.floatterm.dimensions,
|
||||
}
|
||||
|
||||
local function is_installed(exe)
|
||||
|
|
22
lua/lv-galaxyline/config.lua
Normal file
22
lua/lv-galaxyline/config.lua
Normal file
|
@ -0,0 +1,22 @@
|
|||
O.plugin.galaxyline = {
|
||||
active = true,
|
||||
colors = {
|
||||
bg = "#2E2E2E",
|
||||
yellow = "#DCDCAA",
|
||||
dark_yellow = "#D7BA7D",
|
||||
cyan = "#4EC9B0",
|
||||
green = "#608B4E",
|
||||
light_green = "#B5CEA8",
|
||||
string_orange = "#CE9178",
|
||||
orange = "#FF8800",
|
||||
purple = "#C586C0",
|
||||
magenta = "#D16D9E",
|
||||
grey = "#858585",
|
||||
blue = "#569CD6",
|
||||
vivid_blue = "#4FC1FF",
|
||||
light_blue = "#9CDCFE",
|
||||
red = "#D16969",
|
||||
error_red = "#F44747",
|
||||
info_yellow = "#FFCC66",
|
||||
},
|
||||
}
|
|
@ -6,27 +6,7 @@ if not status_ok then
|
|||
return
|
||||
end
|
||||
-- get my theme in galaxyline repo
|
||||
-- local colors = require('galaxyline.theme').default
|
||||
local colors = {
|
||||
bg = "#2E2E2E",
|
||||
-- bg = '#292D38',
|
||||
yellow = "#DCDCAA",
|
||||
dark_yellow = "#D7BA7D",
|
||||
cyan = "#4EC9B0",
|
||||
green = "#608B4E",
|
||||
light_green = "#B5CEA8",
|
||||
string_orange = "#CE9178",
|
||||
orange = "#FF8800",
|
||||
purple = "#C586C0",
|
||||
magenta = "#D16D9E",
|
||||
grey = "#858585",
|
||||
blue = "#569CD6",
|
||||
vivid_blue = "#4FC1FF",
|
||||
light_blue = "#9CDCFE",
|
||||
red = "#D16969",
|
||||
error_red = "#F44747",
|
||||
info_yellow = "#FFCC66",
|
||||
}
|
||||
local colors = O.plugin.galaxyline.colors
|
||||
|
||||
local condition = require "galaxyline.condition"
|
||||
local gls = gl.section
|
||||
|
|
47
lua/lv-gitsigns/config.lua
Normal file
47
lua/lv-gitsigns/config.lua
Normal file
|
@ -0,0 +1,47 @@
|
|||
O.plugin.gitsigns = {
|
||||
signs = {
|
||||
-- TODO add hl to colorscheme
|
||||
add = {
|
||||
hl = "GitSignsAdd",
|
||||
text = "▎",
|
||||
numhl = "GitSignsAddNr",
|
||||
linehl = "GitSignsAddLn",
|
||||
},
|
||||
change = {
|
||||
hl = "GitSignsChange",
|
||||
text = "▎",
|
||||
numhl = "GitSignsChangeNr",
|
||||
linehl = "GitSignsChangeLn",
|
||||
},
|
||||
delete = {
|
||||
hl = "GitSignsDelete",
|
||||
text = "契",
|
||||
numhl = "GitSignsDeleteNr",
|
||||
linehl = "GitSignsDeleteLn",
|
||||
},
|
||||
topdelete = {
|
||||
hl = "GitSignsDelete",
|
||||
text = "契",
|
||||
numhl = "GitSignsDeleteNr",
|
||||
linehl = "GitSignsDeleteLn",
|
||||
},
|
||||
changedelete = {
|
||||
hl = "GitSignsChange",
|
||||
text = "▎",
|
||||
numhl = "GitSignsChangeNr",
|
||||
linehl = "GitSignsChangeLn",
|
||||
},
|
||||
},
|
||||
numhl = false,
|
||||
linehl = false,
|
||||
keymaps = {
|
||||
-- Default keymap options
|
||||
noremap = true,
|
||||
buffer = true,
|
||||
},
|
||||
watch_index = { interval = 1000 },
|
||||
sign_priority = 6,
|
||||
update_debounce = 200,
|
||||
status_formatter = nil, -- Use default
|
||||
use_decoration_api = false,
|
||||
}
|
|
@ -5,53 +5,7 @@ M.config = function()
|
|||
if not status_ok then
|
||||
return
|
||||
end
|
||||
gitsigns.setup {
|
||||
signs = {
|
||||
-- TODO add hl to colorscheme
|
||||
add = {
|
||||
hl = "GitSignsAdd",
|
||||
text = "▎",
|
||||
numhl = "GitSignsAddNr",
|
||||
linehl = "GitSignsAddLn",
|
||||
},
|
||||
change = {
|
||||
hl = "GitSignsChange",
|
||||
text = "▎",
|
||||
numhl = "GitSignsChangeNr",
|
||||
linehl = "GitSignsChangeLn",
|
||||
},
|
||||
delete = {
|
||||
hl = "GitSignsDelete",
|
||||
text = "契",
|
||||
numhl = "GitSignsDeleteNr",
|
||||
linehl = "GitSignsDeleteLn",
|
||||
},
|
||||
topdelete = {
|
||||
hl = "GitSignsDelete",
|
||||
text = "契",
|
||||
numhl = "GitSignsDeleteNr",
|
||||
linehl = "GitSignsDeleteLn",
|
||||
},
|
||||
changedelete = {
|
||||
hl = "GitSignsChange",
|
||||
text = "▎",
|
||||
numhl = "GitSignsChangeNr",
|
||||
linehl = "GitSignsChangeLn",
|
||||
},
|
||||
},
|
||||
numhl = false,
|
||||
linehl = false,
|
||||
keymaps = {
|
||||
-- Default keymap options
|
||||
noremap = true,
|
||||
buffer = true,
|
||||
},
|
||||
watch_index = { interval = 1000 },
|
||||
sign_priority = 6,
|
||||
update_debounce = 200,
|
||||
status_formatter = nil, -- Use default
|
||||
use_decoration_api = false,
|
||||
}
|
||||
gitsigns.setup(O.plugin.gitsigns)
|
||||
end
|
||||
|
||||
return M
|
||||
|
|
82
lua/lv-telescope/config.lua
Normal file
82
lua/lv-telescope/config.lua
Normal file
|
@ -0,0 +1,82 @@
|
|||
local status_ok, actions = pcall(require, "telescope.actions")
|
||||
if not status_ok then
|
||||
return
|
||||
end
|
||||
|
||||
O.plugin.telescope = {
|
||||
defaults = {
|
||||
find_command = {
|
||||
"rg",
|
||||
"--no-heading",
|
||||
"--with-filename",
|
||||
"--line-number",
|
||||
"--column",
|
||||
"--smart-case",
|
||||
},
|
||||
prompt_prefix = " ",
|
||||
selection_caret = " ",
|
||||
entry_prefix = " ",
|
||||
initial_mode = "insert",
|
||||
selection_strategy = "reset",
|
||||
sorting_strategy = "descending",
|
||||
layout_strategy = "horizontal",
|
||||
layout_config = {
|
||||
width = 0.75,
|
||||
prompt_position = "bottom",
|
||||
preview_cutoff = 120,
|
||||
horizontal = { mirror = false },
|
||||
vertical = { mirror = false },
|
||||
},
|
||||
file_sorter = require("telescope.sorters").get_fzy_sorter,
|
||||
file_ignore_patterns = {},
|
||||
generic_sorter = require("telescope.sorters").get_generic_fuzzy_sorter,
|
||||
path_display = { "shorten" },
|
||||
winblend = 0,
|
||||
border = {},
|
||||
borderchars = { "─", "│", "─", "│", "╭", "╮", "╯", "╰" },
|
||||
color_devicons = true,
|
||||
use_less = true,
|
||||
set_env = { ["COLORTERM"] = "truecolor" }, -- default = nil,
|
||||
file_previewer = require("telescope.previewers").vim_buffer_cat.new,
|
||||
grep_previewer = require("telescope.previewers").vim_buffer_vimgrep.new,
|
||||
qflist_previewer = require("telescope.previewers").vim_buffer_qflist.new,
|
||||
|
||||
-- Developer configurations: Not meant for general override
|
||||
buffer_previewer_maker = require("telescope.previewers").buffer_previewer_maker,
|
||||
mappings = {
|
||||
i = {
|
||||
["<C-c>"] = actions.close,
|
||||
["<C-j>"] = actions.move_selection_next,
|
||||
["<C-k>"] = actions.move_selection_previous,
|
||||
-- ["<c-t>"] = trouble.open_with_trouble,
|
||||
["<C-q>"] = actions.smart_send_to_qflist + actions.open_qflist,
|
||||
-- To disable a keymap, put [map] = false
|
||||
-- So, to not map "<C-n>", just put
|
||||
-- ["<c-x>"] = false,
|
||||
-- ["<esc>"] = actions.close,
|
||||
|
||||
-- Otherwise, just set the mapping to the function that you want it to be.
|
||||
-- ["<C-i>"] = actions.select_horizontal,
|
||||
|
||||
-- Add up multiple actions
|
||||
["<CR>"] = actions.select_default + actions.center,
|
||||
|
||||
-- You can perform as many actions in a row as you like
|
||||
-- ["<CR>"] = actions.select_default + actions.center + my_cool_custom_action,
|
||||
},
|
||||
n = {
|
||||
["<C-j>"] = actions.move_selection_next,
|
||||
["<C-k>"] = actions.move_selection_previous,
|
||||
-- ["<c-t>"] = trouble.open_with_trouble,
|
||||
["<C-q>"] = actions.smart_send_to_qflist + actions.open_qflist,
|
||||
-- ["<C-i>"] = my_cool_custom_action,
|
||||
},
|
||||
},
|
||||
},
|
||||
extensions = {
|
||||
fzy_native = {
|
||||
override_generic_sorter = false,
|
||||
override_file_sorter = true,
|
||||
},
|
||||
},
|
||||
}
|
|
@ -2,89 +2,4 @@ local status_ok, telescope = pcall(require, "telescope")
|
|||
if not status_ok then
|
||||
return
|
||||
end
|
||||
local actions = require "telescope.actions"
|
||||
-- if O.plugin.trouble.active then
|
||||
-- local trouble = require("trouble.providers.telescope")
|
||||
-- end
|
||||
-- Global remapping
|
||||
------------------------------
|
||||
-- '--color=never',
|
||||
telescope.setup {
|
||||
defaults = {
|
||||
find_command = {
|
||||
"rg",
|
||||
"--no-heading",
|
||||
"--with-filename",
|
||||
"--line-number",
|
||||
"--column",
|
||||
"--smart-case",
|
||||
},
|
||||
prompt_prefix = " ",
|
||||
selection_caret = " ",
|
||||
entry_prefix = " ",
|
||||
initial_mode = "insert",
|
||||
selection_strategy = "reset",
|
||||
sorting_strategy = "descending",
|
||||
layout_strategy = "horizontal",
|
||||
layout_config = {
|
||||
width = 0.75,
|
||||
prompt_position = "bottom",
|
||||
preview_cutoff = 120,
|
||||
horizontal = { mirror = false },
|
||||
vertical = { mirror = false },
|
||||
},
|
||||
file_sorter = require("telescope.sorters").get_fzy_sorter,
|
||||
file_ignore_patterns = {},
|
||||
generic_sorter = require("telescope.sorters").get_generic_fuzzy_sorter,
|
||||
path_display = { "shorten" },
|
||||
winblend = 0,
|
||||
border = {},
|
||||
borderchars = { "─", "│", "─", "│", "╭", "╮", "╯", "╰" },
|
||||
color_devicons = true,
|
||||
use_less = true,
|
||||
set_env = { ["COLORTERM"] = "truecolor" }, -- default = nil,
|
||||
file_previewer = require("telescope.previewers").vim_buffer_cat.new,
|
||||
grep_previewer = require("telescope.previewers").vim_buffer_vimgrep.new,
|
||||
qflist_previewer = require("telescope.previewers").vim_buffer_qflist.new,
|
||||
|
||||
-- Developer configurations: Not meant for general override
|
||||
buffer_previewer_maker = require("telescope.previewers").buffer_previewer_maker,
|
||||
mappings = {
|
||||
i = {
|
||||
["<C-c>"] = actions.close,
|
||||
["<C-j>"] = actions.move_selection_next,
|
||||
["<C-k>"] = actions.move_selection_previous,
|
||||
-- ["<c-t>"] = trouble.open_with_trouble,
|
||||
["<C-q>"] = actions.smart_send_to_qflist + actions.open_qflist,
|
||||
-- To disable a keymap, put [map] = false
|
||||
-- So, to not map "<C-n>", just put
|
||||
-- ["<c-x>"] = false,
|
||||
-- ["<esc>"] = actions.close,
|
||||
|
||||
-- Otherwise, just set the mapping to the function that you want it to be.
|
||||
-- ["<C-i>"] = actions.select_horizontal,
|
||||
|
||||
-- Add up multiple actions
|
||||
["<CR>"] = actions.select_default + actions.center,
|
||||
|
||||
-- You can perform as many actions in a row as you like
|
||||
-- ["<CR>"] = actions.select_default + actions.center + my_cool_custom_action,
|
||||
},
|
||||
n = {
|
||||
["<C-j>"] = actions.move_selection_next,
|
||||
["<C-k>"] = actions.move_selection_previous,
|
||||
-- ["<c-t>"] = trouble.open_with_trouble,
|
||||
["<C-q>"] = actions.smart_send_to_qflist + actions.open_qflist,
|
||||
-- ["<C-i>"] = my_cool_custom_action,
|
||||
},
|
||||
},
|
||||
},
|
||||
extensions = {
|
||||
fzy_native = {
|
||||
override_generic_sorter = false,
|
||||
override_file_sorter = true,
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
-- require'telescope'.load_extension('project')
|
||||
telescope.setup(O.plugin.telescope)
|
||||
|
|
|
@ -164,10 +164,7 @@ local mappings = {
|
|||
k = { "<cmd>lua vim.lsp.diagnostic.goto_prev({popup_opts = {border = O.lsp.popup_border}})<cr>", "Prev Diagnostic" },
|
||||
q = { "<cmd>Telescope quickfix<cr>", "Quickfix" },
|
||||
r = { "<cmd>lua vim.lsp.buf.rename()<cr>", "Rename" },
|
||||
s = {
|
||||
O.plugin.symbol_outline.active and "<cmd>SymbolsOutline<cr>" or "<cmd> Telescope lsp_document_symbols<cr>",
|
||||
"Document Symbols",
|
||||
},
|
||||
s = { "<cmd> Telescope lsp_document_symbols<cr>", "Document Symbols" },
|
||||
S = {
|
||||
"<cmd>Telescope lsp_dynamic_workspace_symbols<cr>",
|
||||
"Workspace Symbols",
|
||||
|
@ -191,11 +188,6 @@ local mappings = {
|
|||
},
|
||||
}
|
||||
|
||||
if O.plugin.symbol_outline.active then
|
||||
vim.api.nvim_set_keymap("n", "<leader>o", ":SymbolsOutline<CR>", { noremap = true, silent = true })
|
||||
mappings["o"] = "Symbols outline"
|
||||
end
|
||||
|
||||
if O.plugin.ts_playground.active then
|
||||
vim.api.nvim_set_keymap("n", "<leader>Th", ":TSHighlightCapturesUnderCursor<CR>", { noremap = true, silent = true })
|
||||
mappings[""] = "Highlight Capture"
|
||||
|
@ -205,6 +197,7 @@ if O.plugin.zen.active then
|
|||
vim.api.nvim_set_keymap("n", "<leader>z", ":ZenMode<CR>", { noremap = true, silent = true })
|
||||
mappings["z"] = "Zen"
|
||||
end
|
||||
|
||||
if O.plugin.telescope_project.active then
|
||||
-- open projects
|
||||
vim.api.nvim_set_keymap(
|
||||
|
|
|
@ -140,10 +140,9 @@ return require("packer").startup(function(use)
|
|||
use {
|
||||
"ChristianChiarulli/dashboard-nvim",
|
||||
event = "BufWinEnter",
|
||||
-- cmd = { "Dashboard", "DashboardNewFile", "DashboardJumpMarks" },
|
||||
-- config = function()
|
||||
-- require("lv-dashboard").config()
|
||||
-- end,
|
||||
config = function()
|
||||
require("lv-dashboard").config()
|
||||
end,
|
||||
disable = not O.plugin.dashboard.active,
|
||||
-- opt = true,
|
||||
}
|
||||
|
|
|
@ -58,3 +58,27 @@ opt.signcolumn = "yes" -- always show the sign column, otherwise it would shift
|
|||
opt.wrap = O.wrap_lines -- display lines as one long line
|
||||
opt.spell = O.spell
|
||||
opt.spelllang = O.spelllang
|
||||
opt.scrolloff = 8 -- is one of my fav
|
||||
--local disabled_built_ins = {
|
||||
-- "netrw",
|
||||
-- "netrwPlugin",
|
||||
-- "netrwSettings",
|
||||
-- "netrwFileHandlers",
|
||||
-- "gzip",
|
||||
-- "zip",
|
||||
-- "zipPlugin",
|
||||
-- "tar",
|
||||
-- "tarPlugin", -- 'man',
|
||||
-- "getscript",
|
||||
-- "getscriptPlugin",
|
||||
-- "vimball",
|
||||
-- "vimballPlugin",
|
||||
-- "2html_plugin",
|
||||
-- "logipat",
|
||||
-- "rrhelper",
|
||||
-- "spellfile_plugin",
|
||||
-- -- 'matchit', 'matchparen', 'shada_plugin',
|
||||
--}
|
||||
--for _, plugin in pairs(disabled_built_ins) do
|
||||
-- vim.g["loaded_" .. plugin] = 1
|
||||
--end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue