From 0f1bc61829f6fb88e5d339bdd01b3355c944b69d Mon Sep 17 00:00:00 2001 From: GMAXnoob <83890189+Gmaxnoob@users.noreply.github.com> Date: Sat, 20 Dec 2025 16:25:56 -0500 Subject: [PATCH] Added my custom theme, can definitely change in the future, want to work on implementing transparency effects to it at the moment. --- init.lua | 33 +++++++------ lua/custom/plugins/init.lua | 7 --- theme/colors/theme.lua | 1 + theme/lua/theme/init.lua | 92 +++++++++++++++++++++++++++++++++++++ 4 files changed, 111 insertions(+), 22 deletions(-) delete mode 100644 lua/custom/plugins/init.lua create mode 100644 theme/colors/theme.lua create mode 100644 theme/lua/theme/init.lua diff --git a/init.lua b/init.lua index 4aac9d7c..5c464a11 100644 --- a/init.lua +++ b/init.lua @@ -114,9 +114,6 @@ vim.o.number = true -- Enable mouse mode, can be useful for resizing splits for example! vim.o.mouse = 'a' --- Sets the theme to dark mode -vim.o.background = 'dark' - -- Don't show the mode, since it's already in the status line vim.o.showmode = false @@ -191,6 +188,7 @@ vim.keymap.set('n', '', 'nohlsearch') -- Diagnostic keymaps vim.keymap.set('n', 'q', vim.diagnostic.setloclist, { desc = 'Open diagnostic [Q]uickfix list' }) vim.keymap.set('n', '', ':Neotree', { desc = 'Toggles Neotree' }) +vim.keymap.set('n', '', ':colorscheme theme', { desc = 'Toggles the theme bc wow its annoying asf' }) -- Exit terminal mode in the builtin terminal with a shortcut that is a bit easier -- for people to discover. Otherwise, you normally need to press , which -- is not what someone will guess without a bit more experience. @@ -255,7 +253,6 @@ if not (vim.uv or vim.loop).fs_stat(lazypath) then end end - ---@type vim.Option local rtp = vim.opt.rtp rtp:prepend(lazypath) @@ -280,17 +277,17 @@ require('lazy').setup({ config = function() require('lualine').setup { options = { - theme = 'tomorrow_night', + theme = 'ayu_light', }, } end, }, { - "mason-org/mason-lspconfig.nvim", + 'mason-org/mason-lspconfig.nvim', opts = {}, dependencies = { - { "mason-org/mason.nvim", opts = {} }, - "neovim/nvim-lspconfig", + { 'mason-org/mason.nvim', opts = {} }, + 'neovim/nvim-lspconfig', }, }, { @@ -903,7 +900,7 @@ require('lazy').setup({ -- : Toggle signature help -- -- See :h blink-cmp-config-keymap for defining your own keymap - preset = 'default', + preset = 'super-tab', -- For more advanced Luasnip keymaps (e.g. selecting choice nodes, expansion) see: -- https://github.com/L3MON4D3/LuaSnip?tab=readme-ov-file#keymaps @@ -944,7 +941,7 @@ require('lazy').setup({ }, }, - { -- You can easily change to a different colorscheme. + --[[{ -- You can easily change to a different colorscheme. -- Change the name of the colorscheme plugin below, and then -- change the command in the config to whatever the name of that colorscheme is. -- @@ -962,9 +959,10 @@ require('lazy').setup({ -- Load the colorscheme here. -- Like many other themes, this one has different styles, and you could load -- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'. - vim.cmd.colorscheme 'tokyonight-night' + vim.cmd.colorscheme 'theme' end, - }, + },]] + -- -- Highlight todo, notes, etc in comments { 'folke/todo-comments.nvim', event = 'VimEnter', dependencies = { 'nvim-lua/plenary.nvim' }, opts = { signs = false } }, @@ -1031,7 +1029,6 @@ require('lazy').setup({ -- - Show your current context: https://github.com/nvim-treesitter/nvim-treesitter-context -- - Treesitter + textobjects: https://github.com/nvim-treesitter/nvim-treesitter-textobjects }, - -- The following comments only work if you have downloaded the kickstart repo, not just copy pasted the -- init.lua. If you want these files, they are in the repository, so you can just download them and -- place them in the correct locations. @@ -1058,6 +1055,9 @@ require('lazy').setup({ -- Or use telescope! -- In normal mode type `sh` then write `lazy.nvim-plugin` -- you can continue same window with `sr` which resumes last telescope search + { + dir = '~/AppData/Local/nvim/theme', + }, }, { ui = { -- If you are using a Nerd Font: set icons to an empty table which will use the @@ -1140,8 +1140,11 @@ require('luau-lsp').setup { }, } - - +vim.api.nvim_create_autocmd('Colorscheme', { + callback = function() + require('theme').setup() + end, +}) -- The line beneath this is called `modeline`. See `:help modeline` -- vim: ts=2 sts=2 sw=2 et diff --git a/lua/custom/plugins/init.lua b/lua/custom/plugins/init.lua deleted file mode 100644 index eb2c0df7..00000000 --- a/lua/custom/plugins/init.lua +++ /dev/null @@ -1,7 +0,0 @@ --- You can add your own plugins here or in other files in this directory! --- I promise not to create any merge conflicts in this directory :) --- --- See the kickstart.nvim README for more information - -return { -} diff --git a/theme/colors/theme.lua b/theme/colors/theme.lua new file mode 100644 index 00000000..026475e4 --- /dev/null +++ b/theme/colors/theme.lua @@ -0,0 +1 @@ +require('theme').setup() diff --git a/theme/lua/theme/init.lua b/theme/lua/theme/init.lua new file mode 100644 index 00000000..2828d6fe --- /dev/null +++ b/theme/lua/theme/init.lua @@ -0,0 +1,92 @@ +local M = {} + +function M.setup() + local colors = { + purple = '#7f8cff', + black = '#000000', + white = '#ededed', + orange = '#ffaa00', + green = '#00c427', + red = '#e60000', + blue = '#00a6ff', + } + + local highlights = { + + Normal = { fg = colors.black, bg = colors.white }, + CursorLine = { bg = '#e6e6e6' }, + LineNr = { fg = colors.purple }, + + -- Neovim text configurations -- + Function = { fg = colors.purple }, + Identifier = { fg = colors.purple }, + MoreMsg = { fg = colors.purple }, + String = { fg = colors.purple }, + QuickFixLine = { fg = colors.purple }, + Question = { fg = colors.purple }, + + -- Other configuratiosn -- + Special = { fg = colors.purple }, + + -- Todo configurations -- + TodoFgTODO = { fg = colors.blue }, + TodoFgNOTE = { fg = colors.blue }, + + TodoBgTODO = { fg = colors.white, bg = colors.blue }, + TodoBgNOTE = { fg = colors.white, bg = colors.blue }, + + -- [ TREESITTER RELATED / TEXT CONFIGURATIONS ] -- + + -- Literals -- + ['@string'] = { fg = colors.purple }, + ['@boolean'] = { fg = colors.purple }, + ['@character'] = { fg = colors.purple }, + ['@number'] = { fg = colors.orange }, + + -- Identifiers -- + ['@variable'] = { fg = colors.black }, + ['@module'] = { fg = colors.black }, + + -- Types -- + ['@type'] = { fg = colors.purple }, + ['@property'] = { fg = colors.purple }, + + -- Keyword related -- + ['@keyword'] = { fg = colors.purple }, + + -- Comment related -- + ['@comment'] = { fg = colors.orange }, + ['@comment.warning'] = { fg = colors.orange }, + ['@comment.todo'] = { fg = colors.green }, + ['@comment.documentation'] = { fg = colors.blue }, + ['@comment.note'] = { fg = colors.blue }, + ['@comment.error'] = { fg = colors.red }, + + -- Functions -- + ['@function'] = { fg = colors.purple }, + ['@function.builtin'] = { fg = colors.black }, + ['@constructor'] = { fg = colors.black }, + ['@operator'] = { fg = colors.black }, + + -- Punctuation -- + ['@punctuation'] = { fg = colors.black }, + + -- [ NEOTREE COLOR CONFIGURATIONS ] -- + Removed = { fg = colors.red }, + NeoTreeGitUntracked = { fg = colors.purple }, + Changed = { fg = colors.purple }, + Directory = { fg = colors.purple }, + Added = { fg = colors.green }, + + -- Diagnostic colors -- + DiagnosticInfo = { fg = colors.purple }, + DiagnosticOk = { fg = colors.purple }, + DiagnosticWarn = { fg = colors.orange }, + } + + for group, opts in pairs(highlights) do + vim.api.nvim_set_hl(0, group, opts) + end +end + +return M