feat(nvim,wezterm,yabai): the big OLEDppuccin update
This commit is contained in:
parent
368c6bbe5b
commit
2f24166856
6 changed files with 99 additions and 63 deletions
|
@ -1,5 +1,17 @@
|
||||||
local colors = require("catppuccin.palettes").get_palette()
|
local colors = require("catppuccin.palettes").get_palette()
|
||||||
vim.g.catppuccin_flavour = "frappe"
|
vim.g.catppuccin_flavour = "mocha"
|
||||||
|
|
||||||
|
local darkmode_overrides = {
|
||||||
|
base = "#000000",
|
||||||
|
crust = "#000000",
|
||||||
|
mantle = "#000000",
|
||||||
|
-- surface0 = "#101010",
|
||||||
|
-- surface1 = "#141414",
|
||||||
|
-- surface2 = "#181818",
|
||||||
|
-- overlay1 = "#202020",
|
||||||
|
-- overlay2 = "#242424",
|
||||||
|
-- overlay3 = "#282828",
|
||||||
|
}
|
||||||
|
|
||||||
require("catppuccin").setup({
|
require("catppuccin").setup({
|
||||||
dim_inactive = {
|
dim_inactive = {
|
||||||
|
@ -62,22 +74,20 @@ require("catppuccin").setup({
|
||||||
telescope = true,
|
telescope = true,
|
||||||
ts_rainbow = true,
|
ts_rainbow = true,
|
||||||
vim_sneak = false,
|
vim_sneak = false,
|
||||||
|
vimwiki = true,
|
||||||
},
|
},
|
||||||
custom_highlights = {
|
custom_highlights = {
|
||||||
DashboardHeader = { fg = colors.pink },
|
DashboardHeader = { fg = colors.pink },
|
||||||
DashboardCenter = { fg = colors.peach },
|
DashboardCenter = { fg = colors.peach },
|
||||||
DashboardShortCut = { fg = colors.yellow },
|
DashboardShortCut = { fg = colors.yellow },
|
||||||
DashboardFooter = { fg = colors.maroon },
|
DashboardFooter = { fg = colors.maroon },
|
||||||
|
TelescopeBorder = { fg = colors.overlay0 },
|
||||||
|
},
|
||||||
|
color_overrides = {
|
||||||
|
mocha = darkmode_overrides,
|
||||||
|
macchiato = darkmode_overrides,
|
||||||
|
frappe = darkmode_overrides,
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
vim.api.nvim_command("colorscheme catppuccin")
|
vim.api.nvim_command("colorscheme catppuccin")
|
||||||
|
|
||||||
-- vim.api.nvim_create_autocmd("ColorScheme", {
|
|
||||||
-- pattern = "*",
|
|
||||||
-- callback = function()
|
|
||||||
-- package.loaded["feline"] = nil
|
|
||||||
-- package.loaded["catppuccin.groups.integrations.feline"] = nil
|
|
||||||
-- require("config.feline")
|
|
||||||
-- end,
|
|
||||||
-- })
|
|
||||||
|
|
|
@ -18,7 +18,7 @@ if not present or not cmp then
|
||||||
end
|
end
|
||||||
|
|
||||||
local has_words_before = function()
|
local has_words_before = function()
|
||||||
local line, col = table.unpack(vim.api.nvim_win_get_cursor(0))
|
local line, col = unpack(vim.api.nvim_win_get_cursor(0))
|
||||||
return col ~= 0
|
return col ~= 0
|
||||||
and vim.api
|
and vim.api
|
||||||
.nvim_buf_get_lines(0, line - 1, line, true)[1]
|
.nvim_buf_get_lines(0, line - 1, line, true)[1]
|
||||||
|
@ -42,8 +42,14 @@ cmp.setup({
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
window = {
|
window = {
|
||||||
completion = cmp.config.window.bordered(),
|
completion = {
|
||||||
documentation = cmp.config.window.bordered(),
|
border = { "╔", "═", "╗", "║", "╝", "═", "╚", "║" },
|
||||||
|
winhighlight = "Normal:CmpPmenu,FloatBorder:CmpBorder,CursorLine:PmenuSel,Search:None",
|
||||||
|
},
|
||||||
|
documentation = {
|
||||||
|
border = { "╔", "═", "╗", "║", "╝", "═", "╚", "║" },
|
||||||
|
winhighlight = "Normal:CmpPmenu,FloatBorder:CmpBorder,CursorLine:PmenuSel,Search:None",
|
||||||
|
},
|
||||||
},
|
},
|
||||||
mapping = cmp.mapping.preset.insert({
|
mapping = cmp.mapping.preset.insert({
|
||||||
["<C-b>"] = cmp.mapping.scroll_docs(-4),
|
["<C-b>"] = cmp.mapping.scroll_docs(-4),
|
||||||
|
@ -78,6 +84,13 @@ cmp.setup({
|
||||||
}, {
|
}, {
|
||||||
{ name = "buffer" },
|
{ name = "buffer" },
|
||||||
}),
|
}),
|
||||||
|
formatting = {
|
||||||
|
format = require("lspkind").cmp_format({
|
||||||
|
mode = "symbol_text",
|
||||||
|
maxwidth = 50,
|
||||||
|
ellipsis_char = "...",
|
||||||
|
}),
|
||||||
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
cmp.setup.filetype("gitcommit", {
|
cmp.setup.filetype("gitcommit", {
|
||||||
|
@ -98,7 +111,7 @@ cmp.setup.cmdline({ "/", "?" }, {
|
||||||
cmp.setup.cmdline(":", {
|
cmp.setup.cmdline(":", {
|
||||||
mapping = cmp.mapping.preset.cmdline(),
|
mapping = cmp.mapping.preset.cmdline(),
|
||||||
sources = cmp.config.sources({
|
sources = cmp.config.sources({
|
||||||
{ name = "path" },
|
{ name = "path", option = { trailing_slash = true } },
|
||||||
}, {
|
}, {
|
||||||
{ name = "cmdline" },
|
{ name = "cmdline" },
|
||||||
}),
|
}),
|
||||||
|
@ -185,6 +198,20 @@ lspconfig.denols.setup({
|
||||||
root_dir = lspconfig.util.root_pattern("deps.ts"),
|
root_dir = lspconfig.util.root_pattern("deps.ts"),
|
||||||
single_file_support = false,
|
single_file_support = false,
|
||||||
})
|
})
|
||||||
|
lspconfig.ltex.setup({
|
||||||
|
capabilities = capabilities,
|
||||||
|
on_attach = function(client, bufnr)
|
||||||
|
require("ltex_extra").setup({
|
||||||
|
load_langs = { "en-US", "de-AT" },
|
||||||
|
init_check = true,
|
||||||
|
path = vim.fn.stdpath("data") .. "/dictionary",
|
||||||
|
})
|
||||||
|
on_attach(client, bufnr)
|
||||||
|
end,
|
||||||
|
settings = {
|
||||||
|
ltex = {},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
local null = require("null-ls")
|
local null = require("null-ls")
|
||||||
local augroup = vim.api.nvim_create_augroup("LspFormatting", {})
|
local augroup = vim.api.nvim_create_augroup("LspFormatting", {})
|
||||||
|
|
|
@ -24,7 +24,6 @@ return packer.startup({
|
||||||
use({
|
use({
|
||||||
"catppuccin/nvim",
|
"catppuccin/nvim",
|
||||||
as = "catppuccin",
|
as = "catppuccin",
|
||||||
run = ":CatppuccinCompile",
|
|
||||||
config = function()
|
config = function()
|
||||||
require("config/catppuccin")
|
require("config/catppuccin")
|
||||||
end,
|
end,
|
||||||
|
@ -41,18 +40,7 @@ return packer.startup({
|
||||||
use({
|
use({
|
||||||
"lukas-reineke/indent-blankline.nvim",
|
"lukas-reineke/indent-blankline.nvim",
|
||||||
config = function()
|
config = function()
|
||||||
require("indent_blankline").setup({
|
require("indent_blankline").setup({})
|
||||||
space_char_blankline = " ",
|
|
||||||
show_current_conext = true,
|
|
||||||
char_highlight_list = {
|
|
||||||
"IndentBlanklineIndent1",
|
|
||||||
"IndentBlanklineIndent2",
|
|
||||||
"IndentBlanklineIndent3",
|
|
||||||
"IndentBlanklineIndent4",
|
|
||||||
"IndentBlanklineIndent5",
|
|
||||||
"IndentBlanklineIndent6",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
vim.g.indent_blankline_filetype_exclude = {
|
vim.g.indent_blankline_filetype_exclude = {
|
||||||
"dashboard",
|
"dashboard",
|
||||||
"help",
|
"help",
|
||||||
|
@ -83,27 +71,6 @@ return packer.startup({
|
||||||
component_separators = { left = "", right = "" },
|
component_separators = { left = "", right = "" },
|
||||||
section_separators = { left = "", right = "" },
|
section_separators = { left = "", right = "" },
|
||||||
},
|
},
|
||||||
sections = {
|
|
||||||
lualine_x = {
|
|
||||||
{
|
|
||||||
"diagnostics",
|
|
||||||
sources = { "nvim_lsp" },
|
|
||||||
-- Displays diagnostics for the defined severity types
|
|
||||||
sections = { "error", "warn", "info", "hint" },
|
|
||||||
diagnostics_color = {
|
|
||||||
-- Same values as the general color option can be used here.
|
|
||||||
error = "DiagnosticError", -- Changes diagnostics' error color.
|
|
||||||
warn = "DiagnosticWarn", -- Changes diagnostics' warn color.
|
|
||||||
info = "DiagnosticInfo", -- Changes diagnostics' info color.
|
|
||||||
hint = "DiagnosticHint", -- Changes diagnostics' hint color.
|
|
||||||
},
|
|
||||||
symbols = { error = "E", warn = "W", info = "I", hint = "H" },
|
|
||||||
colored = true, -- Displays diagnostics status in color if set to true.
|
|
||||||
update_in_insert = false, -- Update diagnostics in insert mode.
|
|
||||||
always_visible = false, -- Show diagnostics even if there are none.
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
})
|
})
|
||||||
end,
|
end,
|
||||||
})
|
})
|
||||||
|
@ -126,6 +93,8 @@ return packer.startup({
|
||||||
require("config/treesitter")
|
require("config/treesitter")
|
||||||
end,
|
end,
|
||||||
})
|
})
|
||||||
|
use("nvim-treesitter/playground")
|
||||||
|
|
||||||
use({
|
use({
|
||||||
"p00f/nvim-ts-rainbow",
|
"p00f/nvim-ts-rainbow",
|
||||||
requires = "nvim-treesitter/nvim-treesitter",
|
requires = "nvim-treesitter/nvim-treesitter",
|
||||||
|
@ -219,9 +188,23 @@ return packer.startup({
|
||||||
"nvim-telescope/telescope.nvim",
|
"nvim-telescope/telescope.nvim",
|
||||||
requires = "nvim-lua/plenary.nvim",
|
requires = "nvim-lua/plenary.nvim",
|
||||||
config = function()
|
config = function()
|
||||||
|
require("telescope").setup({
|
||||||
|
defaults = {
|
||||||
|
borderchars = {
|
||||||
|
"═",
|
||||||
|
"║",
|
||||||
|
"═",
|
||||||
|
"║",
|
||||||
|
"╔",
|
||||||
|
"╗",
|
||||||
|
"╝",
|
||||||
|
"╚",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})
|
||||||
Map("n", "<leader>fr", "<cmd>Telescope asynctasks all<CR>")
|
Map("n", "<leader>fr", "<cmd>Telescope asynctasks all<CR>")
|
||||||
Map("n", "<leader>fb", "<cmd>Telescope file_browser<CR>")
|
Map("n", "<leader>fb", "<cmd>Telescope file_browser<CR>")
|
||||||
Map("n", "<leader>ff", "<cmd>Telescope find_files<CR>")
|
Map("n", "<leader>fd", "<cmd>Telescope find_files<CR>")
|
||||||
Map("n", "<leader>fg", "<cmd>Telescope live_grep<CR>")
|
Map("n", "<leader>fg", "<cmd>Telescope live_grep<CR>")
|
||||||
Map("n", "<leader>fh", "<cmd>Telescope help_tags<CR>")
|
Map("n", "<leader>fh", "<cmd>Telescope help_tags<CR>")
|
||||||
Map("n", "<leader>fp", "<cmd>Telescope project<CR>")
|
Map("n", "<leader>fp", "<cmd>Telescope project<CR>")
|
||||||
|
@ -284,6 +267,7 @@ return packer.startup({
|
||||||
use("hrsh7th/cmp-vsnip")
|
use("hrsh7th/cmp-vsnip")
|
||||||
use("hrsh7th/vim-vsnip")
|
use("hrsh7th/vim-vsnip")
|
||||||
use("petertriho/cmp-git")
|
use("petertriho/cmp-git")
|
||||||
|
use("onsails/lspkind.nvim")
|
||||||
use("rafamadriz/friendly-snippets")
|
use("rafamadriz/friendly-snippets")
|
||||||
use("jose-elias-alvarez/null-ls.nvim")
|
use("jose-elias-alvarez/null-ls.nvim")
|
||||||
use({
|
use({
|
||||||
|
@ -293,13 +277,14 @@ return packer.startup({
|
||||||
require("config/lspsaga")
|
require("config/lspsaga")
|
||||||
end,
|
end,
|
||||||
})
|
})
|
||||||
|
use({ "barreiroleo/ltex-extra.nvim" })
|
||||||
|
|
||||||
use("b0o/schemastore.nvim")
|
use("b0o/schemastore.nvim")
|
||||||
use({
|
use({
|
||||||
"github/copilot.vim",
|
"github/copilot.vim",
|
||||||
config = function()
|
config = function()
|
||||||
local opt = { noremap = true, silent = true, expr = true }
|
local opt = { noremap = true, silent = true, expr = true }
|
||||||
Map("i", "<C-J>", "copilot#Accept(<Tab>)", opt)
|
Map("i", "<C-J>", 'copilot#Accept("<CR>")', opt)
|
||||||
vim.g.copilot_no_tab_map = true
|
vim.g.copilot_no_tab_map = true
|
||||||
end,
|
end,
|
||||||
})
|
})
|
||||||
|
@ -352,7 +337,9 @@ return packer.startup({
|
||||||
end,
|
end,
|
||||||
config = {
|
config = {
|
||||||
display = {
|
display = {
|
||||||
open_fn = require("packer.util").float,
|
open_fn = function()
|
||||||
|
return require("packer.util").float({ border = "double" })
|
||||||
|
end,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
|
@ -34,6 +34,10 @@ if [[ $THEME == 'dark' ]]; then
|
||||||
BASE="303446"
|
BASE="303446"
|
||||||
MANTLE="292c3c"
|
MANTLE="292c3c"
|
||||||
CRUST="232634"
|
CRUST="232634"
|
||||||
|
# overrides
|
||||||
|
BASE="000000"
|
||||||
|
MANTLE="000000"
|
||||||
|
CRUST="000000"
|
||||||
else
|
else
|
||||||
ROSEWATER="dc8a78"
|
ROSEWATER="dc8a78"
|
||||||
FLAMINGO="dd7878"
|
FLAMINGO="dd7878"
|
||||||
|
|
|
@ -5,7 +5,10 @@ local wezterm = require("wezterm")
|
||||||
-- kept seperately from the rest of the config so that I can easily change them
|
-- kept seperately from the rest of the config so that I can easily change them
|
||||||
local fonts = {
|
local fonts = {
|
||||||
berkeley = {
|
berkeley = {
|
||||||
font = "Berkeley Mono",
|
font = {
|
||||||
|
family = "Berkeley Mono",
|
||||||
|
weight = "Bold",
|
||||||
|
},
|
||||||
size = 16,
|
size = 16,
|
||||||
},
|
},
|
||||||
comic = {
|
comic = {
|
||||||
|
@ -198,11 +201,16 @@ wezterm.on("update-status", function(window, pane)
|
||||||
end)
|
end)
|
||||||
-- }}}
|
-- }}}
|
||||||
|
|
||||||
local darkTheme = "Catppuccin Frappe"
|
local custom = wezterm.color.get_builtin_schemes()["Catppuccin Mocha"]
|
||||||
|
custom.background = "#000000"
|
||||||
|
custom.tab_bar.background = "#040404"
|
||||||
|
custom.tab_bar.inactive_tab.bg_color = "#0f0f0f"
|
||||||
|
custom.tab_bar.new_tab.bg_color = "#080808"
|
||||||
|
|
||||||
|
local darkTheme = "OLEDppuccin"
|
||||||
local lightTheme = "Catppuccin Latte"
|
local lightTheme = "Catppuccin Latte"
|
||||||
|
|
||||||
local function scheme_for_appearance(appearance)
|
local function scheme_for_appearance(appearance)
|
||||||
wezterm.log_info(appearance)
|
|
||||||
if string.match(wezterm.target_triple, "linux") then
|
if string.match(wezterm.target_triple, "linux") then
|
||||||
return darkTheme
|
return darkTheme
|
||||||
end
|
end
|
||||||
|
@ -287,7 +295,6 @@ return {
|
||||||
},
|
},
|
||||||
action = wezterm.action_callback(function(window, pane)
|
action = wezterm.action_callback(function(window, pane)
|
||||||
local url = window:get_selection_text_for_pane(pane)
|
local url = window:get_selection_text_for_pane(pane)
|
||||||
wezterm.log_info("opening: " .. url)
|
|
||||||
wezterm.open_with(url)
|
wezterm.open_with(url)
|
||||||
end),
|
end),
|
||||||
}),
|
}),
|
||||||
|
@ -349,6 +356,9 @@ return {
|
||||||
-- don't attempt to resize the window (tiling wm)
|
-- don't attempt to resize the window (tiling wm)
|
||||||
adjust_window_size_when_changing_font_size = false,
|
adjust_window_size_when_changing_font_size = false,
|
||||||
-- theme
|
-- theme
|
||||||
|
color_schemes = {
|
||||||
|
["OLEDppuccin"] = custom,
|
||||||
|
},
|
||||||
color_scheme = scheme_for_appearance(wezterm.gui.get_appearance()),
|
color_scheme = scheme_for_appearance(wezterm.gui.get_appearance()),
|
||||||
-- nightly only
|
-- nightly only
|
||||||
clean_exit_codes = { 130 },
|
clean_exit_codes = { 130 },
|
||||||
|
@ -358,4 +368,5 @@ return {
|
||||||
max_fps = 240,
|
max_fps = 240,
|
||||||
-- scrollbar, currently hidden by default, but better make sure
|
-- scrollbar, currently hidden by default, but better make sure
|
||||||
enable_scroll_bar = false,
|
enable_scroll_bar = false,
|
||||||
|
hide_tab_bar_if_only_one_tab = true,
|
||||||
}
|
}
|
||||||
|
|
|
@ -23,10 +23,7 @@ yabai -m config \
|
||||||
mouse_drop_action swap \
|
mouse_drop_action swap \
|
||||||
window_origin_display default \
|
window_origin_display default \
|
||||||
window_placement second_child \
|
window_placement second_child \
|
||||||
active_window_border_color 0xfff5c2e7 \
|
window_border off \
|
||||||
normal_window_border_color 0xffb4befe \
|
|
||||||
insert_feedback_color 0xfff9e2af \
|
|
||||||
window_border on \
|
|
||||||
window_border_width 2 \
|
window_border_width 2 \
|
||||||
window_opacity on \
|
window_opacity on \
|
||||||
window_opacity_duration 0.1 \
|
window_opacity_duration 0.1 \
|
||||||
|
|
Loading…
Reference in a new issue