change things to use tinty theme
This commit is contained in:
parent
9873905af2
commit
db5afcc9d9
43
init.lua
43
init.lua
@ -1,4 +1,45 @@
|
|||||||
|
local opt = vim.opt
|
||||||
|
vim.g.mapleader = " "
|
||||||
|
vim.g.maplocalleader = "\\"
|
||||||
|
opt.number = true
|
||||||
|
opt.relativenumber = true
|
||||||
|
opt.cursorline = true
|
||||||
|
opt.termguicolors = true
|
||||||
|
opt.winborder = "single"
|
||||||
|
opt.signcolumn = "yes"
|
||||||
|
vim.lsp.inlay_hint.enable = true
|
||||||
|
opt.tabstop = 8
|
||||||
|
vim.opt.expandtab = true
|
||||||
|
|
||||||
|
opt.shiftwidth = 8
|
||||||
|
vim.diagnostic.config({
|
||||||
|
virtual_text = {
|
||||||
|
spacing = 2,
|
||||||
|
source = true,
|
||||||
|
},
|
||||||
|
})
|
||||||
require("config.options")
|
require("config.options")
|
||||||
require("config.lazy")
|
require("config.lazy")
|
||||||
require("config.keymaps")
|
require("config.keymaps")
|
||||||
vim.cmd.colorscheme("base16-catppuccin-mocha")
|
local theme_script_path = vim.fn.expand("~/.local/share/tinted-theming/tinty/base16-vim-colors-file.vim")
|
||||||
|
|
||||||
|
local function file_exists(file_path)
|
||||||
|
return vim.fn.filereadable(file_path) == 1 and true or false
|
||||||
|
end
|
||||||
|
|
||||||
|
local function handle_focus_gained()
|
||||||
|
if file_exists(theme_script_path) then
|
||||||
|
vim.cmd("source " .. theme_script_path)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
if file_exists(theme_script_path) then
|
||||||
|
vim.o.termguicolors = true
|
||||||
|
vim.g.tinted_colorspace = 256
|
||||||
|
|
||||||
|
vim.cmd("source " .. theme_script_path)
|
||||||
|
|
||||||
|
vim.api.nvim_create_autocmd("FocusGained", {
|
||||||
|
callback = handle_focus_gained,
|
||||||
|
})
|
||||||
|
end
|
||||||
|
|||||||
@ -1,18 +1,17 @@
|
|||||||
{
|
{
|
||||||
"base16-nvim": { "branch": "master", "commit": "80ce668de796d1564d875a3c31822b4db3ae1d91" },
|
"blink.cmp": { "branch": "main", "commit": "451168851e8e2466bc97ee3e026c3dcb9141ce07" },
|
||||||
"blink.cmp": { "branch": "main", "commit": "4b18c32adef2898f95cdef6192cbd5796c1a332d" },
|
|
||||||
"bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" },
|
"bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" },
|
||||||
"conform.nvim": { "branch": "master", "commit": "40dcec5555f960b0a04340d76eabdf4efe78599d" },
|
"conform.nvim": { "branch": "master", "commit": "086a40dc7ed8242c03be9f47fbcee68699cc2395" },
|
||||||
"cord.nvim": { "branch": "master", "commit": "283e4a5bdafd0d6187f28e5b739cccab6b4c9c64" },
|
"cord.nvim": { "branch": "master", "commit": "283e4a5bdafd0d6187f28e5b739cccab6b4c9c64" },
|
||||||
"friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" },
|
"friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" },
|
||||||
"lazy.nvim": { "branch": "main", "commit": "306a05526ada86a7b30af95c5cc81ffba93fef97" },
|
"lazy.nvim": { "branch": "main", "commit": "306a05526ada86a7b30af95c5cc81ffba93fef97" },
|
||||||
"lspsaga.nvim": { "branch": "main", "commit": "8efe00d6aed9db6449969f889170f1a7e43101a1" },
|
"lspsaga.nvim": { "branch": "main", "commit": "562d9724e3869ffd1801c572dd149cc9f8d0cc36" },
|
||||||
"lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" },
|
"lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" },
|
||||||
"mason-lspconfig.nvim": { "branch": "main", "commit": "a324581a3c83fdacdb9804b79de1cbe00ce18550" },
|
"mason-lspconfig.nvim": { "branch": "main", "commit": "a676ab7282da8d651e175118bcf54483ca11e46d" },
|
||||||
"mason.nvim": { "branch": "main", "commit": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65" },
|
"mason.nvim": { "branch": "main", "commit": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65" },
|
||||||
"nvim-lspconfig": { "branch": "master", "commit": "ead0f5f342d8d323441e7d4b88f0fc436a81ad5f" },
|
"nvim-lspconfig": { "branch": "master", "commit": "d36ace0851744c7ec20213d1c8ff229806a98234" },
|
||||||
"nvim-tree.lua": { "branch": "master", "commit": "a0db8bf7d6488b1dcd9cb5b0dfd6684a1e14f769" },
|
"nvim-tree.lua": { "branch": "master", "commit": "a0db8bf7d6488b1dcd9cb5b0dfd6684a1e14f769" },
|
||||||
"nvim-treesitter": { "branch": "main", "commit": "cb2cb74f3c3cbbcc17e79cada2060165d616d849" },
|
"nvim-treesitter": { "branch": "main", "commit": "2b50ab5ccbcd9e5708deb351308edd738adbf84c" },
|
||||||
"nvim-web-devicons": { "branch": "master", "commit": "737cf6c657898d0c697311d79d361288a1343d50" },
|
"nvim-web-devicons": { "branch": "master", "commit": "d7462543c9e366c0d196c7f67a945eaaf5d99414" },
|
||||||
"snacks.nvim": { "branch": "main", "commit": "9912042fc8bca2209105526ac7534e9a0c2071b2" }
|
"snacks.nvim": { "branch": "main", "commit": "a049339328e2599ad6e85a69fa034ac501e921b2" }
|
||||||
}
|
}
|
||||||
|
|||||||
64
lua/config/generated.lua
Normal file
64
lua/config/generated.lua
Normal file
@ -0,0 +1,64 @@
|
|||||||
|
-- Generated by Matugen
|
||||||
|
|
||||||
|
require('base16-colorscheme').setup({
|
||||||
|
base00 = "#0b0e12",
|
||||||
|
base01 = "#0b0e12",
|
||||||
|
base02 = "#181c20",
|
||||||
|
base03 = "#42474e",
|
||||||
|
base04 = "#c2c7cf",
|
||||||
|
base05 = "#e0e2e8",
|
||||||
|
base06 = "#2d3135",
|
||||||
|
base07 = "#36393e",
|
||||||
|
|
||||||
|
base08 = "#c8acdf",
|
||||||
|
base09 = "#d4bee6",
|
||||||
|
base0A = "#b9c8da",
|
||||||
|
base0B = "#9dcbfb",
|
||||||
|
base0C = "#504060",
|
||||||
|
base0D = "#124a73",
|
||||||
|
base0E = "#3a4857",
|
||||||
|
base0F = "#98aec8",
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
-- We first theme base16, but we also need to fix some other colors that don't
|
||||||
|
-- contrast well by default
|
||||||
|
|
||||||
|
-- Helper function to set multiple highlight groups at once
|
||||||
|
local function set_hl_mutliple(groups, value)
|
||||||
|
for _, v in pairs(groups) do
|
||||||
|
vim.api.nvim_set_hl(0, v, value)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
-- Make selected text stand out more
|
||||||
|
vim.api.nvim_set_hl(0, 'Visual', {
|
||||||
|
bg = '#124a73',
|
||||||
|
fg = '#cfe5ff', -- normal text contrast
|
||||||
|
})
|
||||||
|
|
||||||
|
-- Make "string" text contrast better
|
||||||
|
set_hl_mutliple({ 'String', 'TSString' }, {
|
||||||
|
fg = '#af87d1',
|
||||||
|
})
|
||||||
|
|
||||||
|
-- Grey out comments
|
||||||
|
set_hl_mutliple({ 'TSComment', 'Comment' }, {
|
||||||
|
fg = '#8c9199',
|
||||||
|
italic = true,
|
||||||
|
})
|
||||||
|
|
||||||
|
-- Color in other highlight groups as you see fit!
|
||||||
|
|
||||||
|
set_hl_mutliple({ 'TSMethod', 'Method' }, {
|
||||||
|
fg = '#d4bee6',
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
set_hl_mutliple({ 'TSFunction', 'Function' }, {
|
||||||
|
fg = '#b9c8da',
|
||||||
|
})
|
||||||
|
|
||||||
|
set_hl_mutliple({ 'Keyword', 'TSKeyword', 'TSKeywordFunction', 'TSRepeat' }, {
|
||||||
|
fg = '#31628d',
|
||||||
|
})
|
||||||
@ -18,24 +18,6 @@ vim.opt.rtp:prepend(lazypath)
|
|||||||
-- Make sure to setup `mapleader` and `maplocalleader` before
|
-- Make sure to setup `mapleader` and `maplocalleader` before
|
||||||
-- loading lazy.nvim so that mappings are correct.
|
-- loading lazy.nvim so that mappings are correct.
|
||||||
-- This is also a good place to setup other settings (vim.opt)
|
-- This is also a good place to setup other settings (vim.opt)
|
||||||
local opt = vim.opt
|
|
||||||
vim.g.mapleader = " "
|
|
||||||
vim.g.maplocalleader = "\\"
|
|
||||||
opt.number = true
|
|
||||||
opt.relativenumber = true
|
|
||||||
opt.cursorline = true
|
|
||||||
opt.termguicolors = true
|
|
||||||
opt.winborder = "single"
|
|
||||||
opt.signcolumn = "yes"
|
|
||||||
vim.lsp.inlay_hint.enable = true
|
|
||||||
opt.tabstop = 8
|
|
||||||
opt.shiftwidth = 8
|
|
||||||
vim.diagnostic.config({
|
|
||||||
virtual_text = {
|
|
||||||
spacing = 2,
|
|
||||||
source = true,
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
-- Setup lazy.nvim
|
-- Setup lazy.nvim
|
||||||
require("lazy").setup({
|
require("lazy").setup({
|
||||||
|
|||||||
@ -1,2 +1 @@
|
|||||||
local opt = vim.opt
|
|
||||||
|
|
||||||
|
|||||||
@ -5,7 +5,7 @@ return {
|
|||||||
opts = {
|
opts = {
|
||||||
display = {
|
display = {
|
||||||
theme = "atom",
|
theme = "atom",
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@ -106,8 +106,6 @@ return {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
notifier = { enabled = true },
|
notifier = { enabled = true },
|
||||||
indent = { enabled = true },
|
|
||||||
picker = { enabled = true },
|
|
||||||
statuscolumn = { enabled = true },
|
statuscolumn = { enabled = true },
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
@ -8,16 +8,12 @@ return {
|
|||||||
},
|
},
|
||||||
opts = {},
|
opts = {},
|
||||||
},
|
},
|
||||||
{ "RRethy/base16-nvim" },
|
|
||||||
{
|
{
|
||||||
"nvim-lualine/lualine.nvim",
|
"nvim-lualine/lualine.nvim",
|
||||||
dependencies = { "nvim-tree/nvim-web-devicons" },
|
dependencies = { "nvim-tree/nvim-web-devicons" },
|
||||||
config = function()
|
config = function()
|
||||||
local has_lualine, lualine = pcall(require, "lualine")
|
|
||||||
if not has_lualine then
|
|
||||||
return
|
|
||||||
end
|
|
||||||
require("lualine").setup({
|
require("lualine").setup({
|
||||||
|
theme = "base16",
|
||||||
options = {
|
options = {
|
||||||
component_separators = { left = "", right = "" },
|
component_separators = { left = "", right = "" },
|
||||||
section_separators = { left = "", right = "" },
|
section_separators = { left = "", right = "" },
|
||||||
@ -45,6 +41,10 @@ return {
|
|||||||
border = "rounded",
|
border = "rounded",
|
||||||
},
|
},
|
||||||
symbol_in_winbar = { enable = true },
|
symbol_in_winbar = { enable = true },
|
||||||
|
lightbulb = {
|
||||||
|
enable = true,
|
||||||
|
sign = false,
|
||||||
|
},
|
||||||
hover = {
|
hover = {
|
||||||
max_width = 0.6,
|
max_width = 0.6,
|
||||||
open_link = "gx",
|
open_link = "gx",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user