1
0

switch to rose pine to cover both light and dark themes

This commit is contained in:
2025-04-01 18:41:25 +02:00
parent 2c50bc303b
commit b0cbc93c8a
10 changed files with 411 additions and 75 deletions

View File

@@ -1,17 +1,17 @@
-- Bootstrap lazy.nvim
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not (vim.uv or vim.loop).fs_stat(lazypath) then
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
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
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
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(lazypath)
@@ -23,19 +23,19 @@ vim.g.maplocalleader = "\\"
-- Setup lazy.nvim
require("lazy").setup({
spec = {
-- import your plugins
{ import = "plugins" },
},
-- Configure any other settings here. See the documentation for more details.
-- colorscheme that will be used when installing plugins.
install = { colorscheme = { "dracula" } },
-- automatically check for plugin updates
checker = {
enabled = false,
concurrency = nil,
notify = false,
frequency = 3600,
check_pinned = false,
},
spec = {
-- import your plugins
{ import = "plugins" },
},
-- Configure any other settings here. See the documentation for more details.
-- colorscheme that will be used when installing plugins.
install = { colorscheme = { "rose-pine" } },
-- automatically check for plugin updates
checker = {
enabled = false,
concurrency = nil,
notify = false,
frequency = 3600,
check_pinned = false,
},
})

View File

@@ -1,30 +1,29 @@
return {
{ -- colorscheme
"Mofiqul/dracula.nvim",
{
"zaldih/themery.nvim",
lazy = false,
name = "dracula",
priority = 1000,
config = function()
local dracula = require("dracula")
dracula.setup({
colors = {
visual = "#5a5e77",
},
-- show the '~' characters after the end of buffers
show_end_of_buffer = true, -- default false
-- use transparent background
transparent_bg = false, -- default false
-- set custom lualine background color
lualine_bg_color = "#44475a", -- default nil
-- set italic comment
italic_comment = true, -- default false
-- overrides the default highlights with table see `:h synIDattr`
overrides = {
CursorLine = { bg = "#3e4153" },
CursorLineNr = { fg = "DarkOrange", bold = true },
},
require("themery").setup({
-- add the config here
themes = { "rose-pine-dawn", "rose-pine-main" }, -- Your list of installed colorschemes.
livePreview = true, -- Apply theme while picking. Default to true.
})
vim.cmd([[colorscheme dracula-soft]])
vim.keymap.set("n", "<leader>tt", function()
local themery = require("themery")
local currentTheme = themery.getCurrentTheme()
if currentTheme and currentTheme.name == "rose-pine-dawn" then
themery.setThemeByName("rose-pine-main", true)
else
themery.setThemeByName("rose-pine-dawn", true)
end
end, { noremap = true, desc = "Alternate between light and dark mode" })
end,
},
{
"rose-pine/neovim",
name = "rose-pine",
config = function()
-- vim.cmd("colorscheme rose-pine")
end,
},
-- highlight color hex codes
@@ -44,7 +43,7 @@ return {
options = {
section_separators = "",
component_separators = "",
theme = "dracula-nvim",
theme = "rose-pine",
},
-- extensions = { "neo-tree", "lazy", "fzf" },
extensions = { "fugitive", "lazy" },