diff --git a/init.lua b/init.lua index b1f44cd..faf96da 100644 --- a/init.lua +++ b/init.lua @@ -1,130 +1,132 @@ -- https://learnxinyminutes.com/docs/lua/ vim.g.mapleader = ' ' +vim.g.user_emmet_install_global = 0 +vim.g.user_emmet_leader_key = "," vim.g.maplocalleader = ' ' local lazypath = vim.fn.stdpath 'data' .. '/lazy/lazy.nvim' if not vim.loop.fs_stat(lazypath) then - vim.fn.system { - 'git', - 'clone', - '--filter=blob:none', - 'https://github.com/folke/lazy.nvim.git', - '--branch=stable', -- latest stable release - lazypath, - } + vim.fn.system { + 'git', + 'clone', + '--filter=blob:none', + 'https://github.com/folke/lazy.nvim.git', + '--branch=stable', -- latest stable release + lazypath, + } end vim.opt.rtp:prepend(lazypath) require('lazy').setup({ - -- Git related plugins - 'tpope/vim-fugitive', - 'tpope/vim-rhubarb', - -- Detect tabstop and shiftwidth automatically - 'tpope/vim-sleuth', - { - -- LSP Configuration & Plugins - 'neovim/nvim-lspconfig', - dependencies = { - -- Automatically install LSPs to stdpath for neovim - { 'williamboman/mason.nvim', config = true }, - 'williamboman/mason-lspconfig.nvim', + -- Git related plugins + 'tpope/vim-fugitive', + 'tpope/vim-rhubarb', + -- Detect tabstop and shiftwidth automatically + 'tpope/vim-sleuth', + { + -- LSP Configuration & Plugins + 'neovim/nvim-lspconfig', + dependencies = { + -- Automatically install LSPs to stdpath for neovim + { 'williamboman/mason.nvim', config = true }, + 'williamboman/mason-lspconfig.nvim', - { - 'j-hui/fidget.nvim', - tag = 'legacy', - opts = { - align = { - bottom = false, - }, - window = { - blend = 0, - -- border = "rounded", - }, + { + 'j-hui/fidget.nvim', + tag = 'legacy', + opts = { + align = { + bottom = false, + }, + window = { + blend = 0, + -- border = "rounded", + }, + }, + }, + + 'folke/neodev.nvim', }, - }, - - 'folke/neodev.nvim', }, - }, - -- Useful plugin to show you pending keybinds. - { 'folke/which-key.nvim', opts = {} }, - { - -- Adds git related signs to the gutter, as well as utilities for managing changes - 'lewis6991/gitsigns.nvim', - opts = { - -- See `:help gitsigns.txt` - signs = { - add = { text = '+' }, - change = { text = '~' }, - delete = { text = '_' }, - topdelete = { text = '‾' }, - changedelete = { text = '~' }, - }, - on_attach = function(bufnr) - vim.keymap.set('n', 'gp', require('gitsigns').prev_hunk, - { buffer = bufnr, desc = '[G]o to [P]revious Hunk' }) - vim.keymap.set('n', 'gn', require('gitsigns').next_hunk, { buffer = bufnr, desc = '[G]o to [N]ext Hunk' }) - vim.keymap.set('n', 'ph', require('gitsigns').preview_hunk, { buffer = bufnr, desc = '[P]review [H]unk' }) - end, + -- Useful plugin to show you pending keybinds. + { 'folke/which-key.nvim', opts = {} }, + { + -- Adds git related signs to the gutter, as well as utilities for managing changes + 'lewis6991/gitsigns.nvim', + opts = { + -- See `:help gitsigns.txt` + signs = { + add = { text = '+' }, + change = { text = '~' }, + delete = { text = '_' }, + topdelete = { text = '‾' }, + changedelete = { text = '~' }, + }, + on_attach = function(bufnr) + vim.keymap.set('n', 'gp', require('gitsigns').prev_hunk, + { buffer = bufnr, desc = '[G]o to [P]revious Hunk' }) + vim.keymap.set('n', 'gn', require('gitsigns').next_hunk, + { buffer = bufnr, desc = '[G]o to [N]ext Hunk' }) + vim.keymap.set('n', 'ph', require('gitsigns').preview_hunk, + { buffer = bufnr, desc = '[P]review [H]unk' }) + end, + }, }, - }, - { - -- Set lualine as statusline - 'nvim-lualine/lualine.nvim', - -- See `:help lualine.txt` - opts = { - options = { - icons_enabled = false, - theme = 'ayu_dark', - component_separators = '|', - section_separators = '', - }, + { + -- Set lualine as statusline + 'nvim-lualine/lualine.nvim', + -- See `:help lualine.txt` + opts = { + options = { + icons_enabled = true, + theme = 'moonfly', + component_separators = '|', + section_separators = '', + }, + }, }, - }, - { - -- Add indentation guides even on blank lines - 'lukas-reineke/indent-blankline.nvim', - -- Enable `lukas-reineke/indent-blankline.nvim` - -- See `:help indent_blankline.txt` - opts = { - char = '┊', - show_trailing_blankline_indent = false, + { + -- Add indentation guides even on blank lines + 'lukas-reineke/indent-blankline.nvim', + -- Enable `lukas-reineke/indent-blankline.nvim` + -- See `:help indent_blankline.txt` + main = 'ibl', + opts = {}, }, - }, - -- "gc" to comment visual regions/lines - { 'numToStr/Comment.nvim', opts = {} }, + -- "gc" to comment visual regions/lines + { 'numToStr/Comment.nvim', opts = {} }, - -- Fuzzy Finder (files, lsp, etc) - { 'nvim-telescope/telescope.nvim', branch = '0.1.x', dependencies = { 'nvim-lua/plenary.nvim' } }, + -- Fuzzy Finder (files, lsp, etc) + { 'nvim-telescope/telescope.nvim', branch = '0.1.x', dependencies = { 'nvim-lua/plenary.nvim' } }, - { - 'nvim-telescope/telescope-fzf-native.nvim', - build = 'make', - cond = function() - return vim.fn.executable 'make' == 1 - end, - }, - - { - -- Highlight, edit, and navigate code - 'nvim-treesitter/nvim-treesitter', - dependencies = { - 'nvim-treesitter/nvim-treesitter-textobjects', + { + 'nvim-telescope/telescope-fzf-native.nvim', + build = 'make', + cond = function() + return vim.fn.executable 'make' == 1 + end, }, - build = ':TSUpdate', - }, - require 'kickstart.plugins.autoformat', - require 'kickstart.plugins.debug', + { + -- Highlight, edit, and navigate code + 'nvim-treesitter/nvim-treesitter', + dependencies = { + 'nvim-treesitter/nvim-treesitter-textobjects', + }, + build = ':TSUpdate', + }, - { import = 'custom.plugins' }, + require 'kickstart.plugins.autoformat', + require 'kickstart.plugins.debug', + + { import = 'custom.plugins' }, }, {}) -- Set highlight on search @@ -173,28 +175,29 @@ vim.keymap.set('n', 'j', "v:count == 0 ? 'gj' : 'j'", { expr = true, silent = tr -- [[ Highlight on yank ]] local highlight_group = vim.api.nvim_create_augroup('YankHighlight', { clear = true }) vim.api.nvim_create_autocmd('TextYankPost', { - callback = function() - vim.highlight.on_yank() - end, - group = highlight_group, - pattern = '*', + callback = function() + vim.highlight.on_yank() + end, + group = highlight_group, + pattern = '*', }) +local fb_actions = require "telescope".extensions.file_browser.actions -- [[ Configure Telescope ]] require('telescope').setup { - defaults = { - mappings = { - i = { - [''] = false, - [''] = false, - }, + defaults = { + mappings = { + i = { + [''] = false, + [''] = false, + }, + }, + }, + pickers = { + find_files = { + theme = "ivy", + } }, - }, - pickers = { - find_files = { - theme = "ivy", - } - }, } -- Enable telescope fzf native, if installed @@ -204,11 +207,11 @@ pcall(require('telescope').load_extension, 'fzf') vim.keymap.set('n', '?', require('telescope.builtin').oldfiles, { desc = '[?] Find recently opened files' }) vim.keymap.set('n', '', require('telescope.builtin').buffers, { desc = '[ ] Find existing buffers' }) vim.keymap.set('n', '/', function() - -- You can pass additional configuration to telescope to change theme, layout, etc. - require('telescope.builtin').current_buffer_fuzzy_find(require('telescope.themes').get_dropdown { - winblend = 0, - previewer = false, - }) + -- You can pass additional configuration to telescope to change theme, layout, etc. + require('telescope.builtin').current_buffer_fuzzy_find(require('telescope.themes').get_dropdown { + winblend = 0, + previewer = false, + }) end, { desc = '[/] Fuzzily search in current buffer' }) vim.keymap.set('n', 'gf', require('telescope.builtin').git_files, { desc = 'Search [G]it [F]iles' }) @@ -221,67 +224,67 @@ vim.keymap.set('n', 'sd', require('telescope.builtin').diagnostics, { de -- [[ Configure Treesitter ]] -- See `:help nvim-treesitter` require('nvim-treesitter.configs').setup { - -- Add languages to be installed here that you want installed for treesitter - ensure_installed = { 'c', 'cpp', 'go', 'lua', 'python', 'rust', 'tsx', 'typescript', 'vimdoc', 'vim', 'java' }, + -- Add languages to be installed here that you want installed for treesitter + ensure_installed = { 'c', 'cpp', 'go', 'lua', 'python', 'rust', 'tsx', 'typescript', 'vimdoc', 'vim', 'java' }, - -- Autoinstall languages that are not installed. Defaults to false (but you can change for yourself!) - auto_install = false, + -- Autoinstall languages that are not installed. Defaults to false (but you can change for yourself!) + auto_install = false, - highlight = { enable = true }, - indent = { enable = true }, - incremental_selection = { - enable = true, - keymaps = { - init_selection = '', - node_incremental = '', - scope_incremental = '', - node_decremental = '', + highlight = { enable = true }, + indent = { enable = true }, + incremental_selection = { + enable = true, + keymaps = { + init_selection = '', + node_incremental = '', + scope_incremental = '', + node_decremental = '', + }, }, - }, - textobjects = { - select = { - enable = true, - lookahead = true, -- Automatically jump forward to textobj, similar to targets.vim - keymaps = { - -- You can use the capture groups defined in textobjects.scm - ['aa'] = '@parameter.outer', - ['ia'] = '@parameter.inner', - ['af'] = '@function.outer', - ['if'] = '@function.inner', - ['ac'] = '@class.outer', - ['ic'] = '@class.inner', - }, + textobjects = { + select = { + enable = true, + lookahead = true, -- Automatically jump forward to textobj, similar to targets.vim + keymaps = { + -- You can use the capture groups defined in textobjects.scm + ['aa'] = '@parameter.outer', + ['ia'] = '@parameter.inner', + ['af'] = '@function.outer', + ['if'] = '@function.inner', + ['ac'] = '@class.outer', + ['ic'] = '@class.inner', + }, + }, + move = { + enable = true, + set_jumps = true, -- whether to set jumps in the jumplist + goto_next_start = { + [']m'] = '@function.outer', + [']]'] = '@class.outer', + }, + goto_next_end = { + [']M'] = '@function.outer', + [']['] = '@class.outer', + }, + goto_previous_start = { + ['[m'] = '@function.outer', + ['[['] = '@class.outer', + }, + goto_previous_end = { + ['[M'] = '@function.outer', + ['[]'] = '@class.outer', + }, + }, + swap = { + enable = true, + swap_next = { + ['a'] = '@parameter.inner', + }, + swap_previous = { + ['A'] = '@parameter.inner', + }, + }, }, - move = { - enable = true, - set_jumps = true, -- whether to set jumps in the jumplist - goto_next_start = { - [']m'] = '@function.outer', - [']]'] = '@class.outer', - }, - goto_next_end = { - [']M'] = '@function.outer', - [']['] = '@class.outer', - }, - goto_previous_start = { - ['[m'] = '@function.outer', - ['[['] = '@class.outer', - }, - goto_previous_end = { - ['[M'] = '@function.outer', - ['[]'] = '@class.outer', - }, - }, - swap = { - enable = true, - swap_next = { - ['a'] = '@parameter.inner', - }, - swap_previous = { - ['A'] = '@parameter.inner', - }, - }, - }, } -- Diagnostic keymaps @@ -293,74 +296,76 @@ vim.keymap.set('n', 'q', vim.diagnostic.setloclist, { desc = 'Open diagn -- [[ Configure LSP ]] -- This function gets run when an LSP connects to a particular buffer. local on_attach = function(_, bufnr) - local nmap = function(keys, func, desc) - if desc then - desc = 'LSP: ' .. desc + local nmap = function(keys, func, desc) + if desc then + desc = 'LSP: ' .. desc + end + + vim.keymap.set('n', keys, func, { buffer = bufnr, desc = desc }) end - vim.keymap.set('n', keys, func, { buffer = bufnr, desc = desc }) - end + nmap('rn', vim.lsp.buf.rename, '[R]e[n]ame') + nmap('ca', vim.lsp.buf.code_action, '[C]ode [A]ction') - nmap('rn', vim.lsp.buf.rename, '[R]e[n]ame') - nmap('ca', vim.lsp.buf.code_action, '[C]ode [A]ction') + nmap('gd', vim.lsp.buf.definition, '[G]oto [D]efinition') + nmap('gr', require('telescope.builtin').lsp_references, '[G]oto [R]eferences') + nmap('gI', vim.lsp.buf.implementation, '[G]oto [I]mplementation') + nmap('D', vim.lsp.buf.type_definition, 'Type [D]efinition') + nmap('ds', require('telescope.builtin').lsp_document_symbols, '[D]ocument [S]ymbols') + nmap('ws', require('telescope.builtin').lsp_dynamic_workspace_symbols, '[W]orkspace [S]ymbols') - nmap('gd', vim.lsp.buf.definition, '[G]oto [D]efinition') - nmap('gr', require('telescope.builtin').lsp_references, '[G]oto [R]eferences') - nmap('gI', vim.lsp.buf.implementation, '[G]oto [I]mplementation') - nmap('D', vim.lsp.buf.type_definition, 'Type [D]efinition') - nmap('ds', require('telescope.builtin').lsp_document_symbols, '[D]ocument [S]ymbols') - nmap('ws', require('telescope.builtin').lsp_dynamic_workspace_symbols, '[W]orkspace [S]ymbols') + -- See `:help K` for why this keymap + nmap('K', vim.lsp.buf.hover, 'Hover Documentation') + nmap('', vim.lsp.buf.signature_help, 'Signature Documentation') - -- See `:help K` for why this keymap - nmap('K', vim.lsp.buf.hover, 'Hover Documentation') - nmap('', vim.lsp.buf.signature_help, 'Signature Documentation') + -- Lesser used LSP functionality + nmap('gD', vim.lsp.buf.declaration, '[G]oto [D]eclaration') + nmap('wa', vim.lsp.buf.add_workspace_folder, '[W]orkspace [A]dd Folder') + nmap('wr', vim.lsp.buf.remove_workspace_folder, '[W]orkspace [R]emove Folder') + nmap('wl', function() + print(vim.inspect(vim.lsp.buf.list_workspace_folders())) + end, '[W]orkspace [L]ist Folders') - -- Lesser used LSP functionality - nmap('gD', vim.lsp.buf.declaration, '[G]oto [D]eclaration') - nmap('wa', vim.lsp.buf.add_workspace_folder, '[W]orkspace [A]dd Folder') - nmap('wr', vim.lsp.buf.remove_workspace_folder, '[W]orkspace [R]emove Folder') - nmap('wl', function() - print(vim.inspect(vim.lsp.buf.list_workspace_folders())) - end, '[W]orkspace [L]ist Folders') + -- Create a command `:Format` local to the LSP buffer + vim.api.nvim_buf_create_user_command(bufnr, 'Format', function(_) + vim.lsp.buf.format() + end, { desc = 'Format current buffer with LSP' }) - -- Create a command `:Format` local to the LSP buffer - vim.api.nvim_buf_create_user_command(bufnr, 'Format', function(_) - vim.lsp.buf.format() - end, { desc = 'Format current buffer with LSP' }) - - vim.lsp.handlers['textDocument/hover'] = vim.lsp.with( - vim.lsp.handlers.hover, { - border = "single" - } - ) - vim.lsp.handlers['textDocument/signatureHelp'] = vim.lsp.with( - vim.lsp.handlers.signatureHelp, { - border = "single" - } - ) - vim.diagnostic.config({ float = { border = "single" } }) + vim.lsp.handlers['textDocument/hover'] = vim.lsp.with( + vim.lsp.handlers.hover, { + border = "single" + } + ) + vim.lsp.handlers['textDocument/signatureHelp'] = vim.lsp.with( + vim.lsp.handlers.signatureHelp, { + border = "single" + } + ) + vim.diagnostic.config({ float = { border = "single" } }) end local servers = { - -- clangd = {}, - -- gopls = {}, - -- pyright = {}, - rust_analyzer = {}, - gopls = {}, - -- tsserver = {}, - -- hls = {}, - html = { provideFormatter = false }, - cssls = {}, - tsserver = {}, - pyright = {}, - - - lua_ls = { - Lua = { - workspace = { checkThirdParty = false }, - telemetry = { enable = false }, + -- clangd = {}, + -- hls = {}, + rust_analyzer = {}, + gopls = { + usePlaceholders = true, + analyses = { + unusedparams = true, + } + }, + html = { provideFormatter = false }, + cssls = {}, + tsserver = {}, + pyright = {}, + + + lua_ls = { + Lua = { + workspace = { checkThirdParty = false }, + telemetry = { enable = false }, + }, }, - }, } -- Setup neovim lua configuration @@ -375,26 +380,26 @@ capabilities.textDocument.completion.completionItem.snippetSupport = true local mason_lspconfig = require 'mason-lspconfig' mason_lspconfig.setup { - ensure_installed = vim.tbl_keys(servers), + ensure_installed = vim.tbl_keys(servers), } mason_lspconfig.setup_handlers { - function(server_name) - require('lspconfig')[server_name].setup { - capabilities = capabilities, - on_attach = on_attach, - settings = servers[server_name], - filetypes = (servers[server_name] or {}).filetypes, - } - end + function(server_name) + require('lspconfig')[server_name].setup { + capabilities = capabilities, + on_attach = on_attach, + settings = servers[server_name], + filetypes = (servers[server_name] or {}).filetypes, + } + end } -- this is for my personal config, i cant bother seeing every TJ's default and changing it to my own require("jabuxas") -vim.opt.tabstop = 2 -vim.opt.softtabstop = 2 -vim.opt.shiftwidth = 2 +vim.opt.tabstop = 4 +vim.opt.softtabstop = 4 +vim.opt.shiftwidth = 4 vim.opt.expandtab = true -- The line beneath this is called `modeline`. See `:help modeline` --- vim: ts=2 sts=2 sw=2 et +-- vim: ts=4 sts=4 sw=4 et diff --git a/lua/custom/plugins/bufferline.lua b/lua/custom/plugins/bufferline.lua index 3956be9..f04857f 100644 --- a/lua/custom/plugins/bufferline.lua +++ b/lua/custom/plugins/bufferline.lua @@ -2,8 +2,12 @@ return { 'akinsho/bufferline.nvim', version = "*", dependencies = 'nvim-tree/nvim-web-devicons', + opts = { + options = { + mode = "tabs" + } + }, config = function() - require('bufferline').setup() vim.keymap.set("n", "", "bnext", { desc = "Go to next Buffer" }) vim.keymap.set("n", "", "bprev", { desc = "Go to previous Buffer" }) vim.keymap.set("n", "", "bdelete", { desc = "Delete current buffer" }) diff --git a/lua/custom/plugins/cmp.lua b/lua/custom/plugins/cmp.lua index df1cf75..011e235 100644 --- a/lua/custom/plugins/cmp.lua +++ b/lua/custom/plugins/cmp.lua @@ -142,8 +142,8 @@ return { end, }, window = { - completion = cmp.config.window.bordered({ winhighlight }), - documentation = cmp.config.window.bordered({ winhighlight }), + completion = cmp.config.window.bordered(winhighlight), + documentation = cmp.config.window.bordered(winhighlight), }, } diff --git a/lua/custom/plugins/emmet.lua b/lua/custom/plugins/emmet.lua index ae2ed68..2b0b240 100644 --- a/lua/custom/plugins/emmet.lua +++ b/lua/custom/plugins/emmet.lua @@ -1,15 +1,12 @@ return { "mattn/emmet-vim", config = function() - vim.g.user_emmet_leader_key = "," - vim.g.user_emmet_install_global = 0 - local autocmd = vim.api.nvim_create_autocmd autocmd("FileType", { pattern = "html", command = [[EmmetInstall]] }) autocmd("FileType", { pattern = "css", command = [[EmmetInstall]] }) - vim.keymap.set("n", "e", function() + vim.keymap.set("n", "le", function() vim.cmd(string.format("Emmet %s", vim.fn.input("Emmet: "))) end) - end + end, } diff --git a/lua/custom/plugins/file-browser.lua b/lua/custom/plugins/file-browser.lua new file mode 100644 index 0000000..b784bba --- /dev/null +++ b/lua/custom/plugins/file-browser.lua @@ -0,0 +1,4 @@ +return { + "nvim-telescope/telescope-file-browser.nvim", + dependencies = { "nvim-telescope/telescope.nvim", "nvim-lua/plenary.nvim" } +} diff --git a/lua/custom/plugins/live-server.lua b/lua/custom/plugins/live-server.lua new file mode 100644 index 0000000..5e56f16 --- /dev/null +++ b/lua/custom/plugins/live-server.lua @@ -0,0 +1,13 @@ +return { + "aurum77/live-server.nvim", + opts = {}, + cmd = { + "LiveServer", + "LiveServerStart", + "LiveServerStop", + "LiveServerInstall", + }, + build = function() + require("live_server.util").install() + end, +} diff --git a/lua/custom/plugins/moonfly.lua b/lua/custom/plugins/moonfly.lua index 1354a8d..d82593b 100644 --- a/lua/custom/plugins/moonfly.lua +++ b/lua/custom/plugins/moonfly.lua @@ -1,12 +1,13 @@ return { - "bluz71/vim-nightfly-colors", - name = "nightfly", + "bluz71/vim-moonfly-colors", + name = "moonfly", lazy = false, priority = 1000, config = function() vim.o.termguicolors = true - vim.cmd [[colorscheme nightfly]] - vim.g.nightflyCursorColor = true - vim.g.nightflyNormalFloat = true + vim.cmd [[colorscheme moonfly]] + vim.g.moonflyCursorColor = true + vim.g.moonflyNormalFloat = true + vim.g.moonflyTransparent = true end } diff --git a/lua/custom/plugins/neosolarized.lua b/lua/custom/plugins/neosolarized.lua index b87a8a2..4d78a69 100644 --- a/lua/custom/plugins/neosolarized.lua +++ b/lua/custom/plugins/neosolarized.lua @@ -39,7 +39,7 @@ return { -- Group.new("DiagnosticUnderlineInfo", colors.none, colors.none, styles.undercurl, cInfo) -- Group.new("DiagnosticUnderlineHint", colors.none, colors.none, styles.undercurl, cHint) -- Group.new("Macro", groups.PreProc, colors.none, styles.italic + styles.bold) - -- Group.link("Function", groups.Function, colors.none, styles.italic) + -- Group.new("Function", groups.Function, colors.none, styles.italic) -- Group.new("Conditional", groups.Statement, colors.none, styles.italic) -- Group.new("Boolean", groups.Constant, colors.none, styles.bold) -- Group.new("HoverBorder", colors.yellow, colors.none, styles.NONE) diff --git a/lua/custom/plugins/solarized.lua b/lua/custom/plugins/solarized.lua index e6fcada..685251b 100644 --- a/lua/custom/plugins/solarized.lua +++ b/lua/custom/plugins/solarized.lua @@ -3,10 +3,10 @@ return { -- lazy = false, -- priority = 1000, -- config = function() - -- vim.o.background = 'dark' -- or 'light' + -- vim.o.background = 'light' -- or 'light' -- require('solarized').setup({ -- transparent = true, - -- theme = 'neo', + -- theme = 'default', -- styles = { -- functions = { bold = true, italic = false } -- }, @@ -14,5 +14,3 @@ return { -- vim.cmd.colorscheme 'solarized' -- end, } - --- vim: sw=2 ts=2 sts=2 et diff --git a/lua/custom/plugins/surround.lua b/lua/custom/plugins/surround.lua new file mode 100644 index 0000000..55b112d --- /dev/null +++ b/lua/custom/plugins/surround.lua @@ -0,0 +1,6 @@ +return { + "kylechui/nvim-surround", + version = "*", + event = "VeryLazy", + opts = {}, +} diff --git a/lua/custom/plugins/transparent.lua b/lua/custom/plugins/transparent.lua index 1f74083..ae48e6f 100644 --- a/lua/custom/plugins/transparent.lua +++ b/lua/custom/plugins/transparent.lua @@ -3,7 +3,8 @@ return { lazy = false, opts = { extra_groups = { - "NormalFloat", -- plugins which have float panel such as Lazy, Mason, LspInfo + "NormalFloat", -- plugins which have float panel such as Lazy, Mason, LspInfo + "FloatBorder", "NvimTreeNormal" -- NvimTree }, }, diff --git a/lua/custom/plugins/zen.lua b/lua/custom/plugins/zen.lua index 6852a17..2d12cf9 100644 --- a/lua/custom/plugins/zen.lua +++ b/lua/custom/plugins/zen.lua @@ -2,12 +2,26 @@ return { "folke/zen-mode.nvim", opts = { plugins = { - tmux = { enabled = true }, kitty = { enabled = true, - font = "+5", - } + font = "+3", + }, + wezterm = { + enabled = true, + font = "+3" + }, + tmux = { enabled = true }, }, + on_open = function() + vim.fn.system("kitty @ set-font-size +5") + vim.fn.system("tmux set status off") + vim.fn.system("tmux set -w pane-border-status off") + end, + on_close = function() + vim.fn.system("kitty @ set-font-size +0") + vim.fn.system("tmux set status on") + vim.fn.system("tmux set -w pane-border-status on") + end, }, config = function() vim.keymap.set("n", "z", "ZenMode", { silent = true }) diff --git a/lua/jabuxas/set.lua b/lua/jabuxas/set.lua index d934653..d18acb8 100644 --- a/lua/jabuxas/set.lua +++ b/lua/jabuxas/set.lua @@ -29,9 +29,9 @@ vim.opt.isfname:append("@-@") vim.opt.updatetime = 50 vim.opt.colorcolumn = "80" -vim.cmd[[highlight ColorColumn ctermbg=235 guibg=#262626]] -vim.api.nvim_create_autocmd({"WinLeave"}, {pattern = "*", callback = function() vim.opt.colorcolumn = "0" end,}) -vim.api.nvim_create_autocmd({"WinEnter"}, {pattern = "*", callback = function() vim.opt.colorcolumn = "80" end,}) +vim.cmd [[highlight ColorColumn ctermbg=235 guibg=#262626]] +vim.api.nvim_create_autocmd({ "WinLeave" }, { pattern = "*", callback = function() vim.opt.colorcolumn = "0" end, }) +vim.api.nvim_create_autocmd({ "WinEnter" }, { pattern = "*", callback = function() vim.opt.colorcolumn = "80" end, }) vim.g.mapleader = " "