From 02d8fff47e41db3d8c2db16d83feb410683a4114 Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Mon, 8 Jun 2026 06:54:42 -0500 Subject: [PATCH 01/17] feat: Adding gitconfig support finally --- deploy.sh | 1 + gitconfig | 41 +++++++++++++++++++++++++++ nvim/lua/plugins/language_support.lua | 2 +- 3 files changed, 43 insertions(+), 1 deletion(-) create mode 100644 gitconfig diff --git a/deploy.sh b/deploy.sh index 18995cf..a3bb989 100755 --- a/deploy.sh +++ b/deploy.sh @@ -17,6 +17,7 @@ declare -A configs=( ["nvim/snippets"]="$HOME/.config/nvim/" ["tmux.conf"]="$HOME/.tmux.conf" ["wezterm/wezterm.lua"]="$HOME/.config/wezterm/wezterm.lua" + ["gitconfig"]="$HOME/.gitconfig" ) declare -a config_directories=( diff --git a/gitconfig b/gitconfig new file mode 100644 index 0000000..7847182 --- /dev/null +++ b/gitconfig @@ -0,0 +1,41 @@ +[push] + default = simple + +[core] + autocrlf = input + +[filter "lfs"] + clean = git-lfs clean -- %f + process = git-lfs filter-process + required = true + smudge = git-lfs smudge -- %f + +[pull] + rebase = false + +[init] + defaultBranch = main + +[alias] + c = commit + d = diff + dl = diff HEAD^ HEAD + ds = diff --staged + l = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit + s = status + branches = branch -avv + staash = stash --all + supdate = submodule update --remote + srupdate = submodule update --recursive + +[merge] + tool = nvimdiff + +[core] + editor = nvim + +[rerere] + enabled = true + +[include] + path = ~/.config/git/local diff --git a/nvim/lua/plugins/language_support.lua b/nvim/lua/plugins/language_support.lua index 63c5c33..2f0c747 100644 --- a/nvim/lua/plugins/language_support.lua +++ b/nvim/lua/plugins/language_support.lua @@ -1,7 +1,7 @@ -- Treesitter local rocks_path = os.getenv('HOME') .. "/.luarocks/lib/luarocks/rocks-5.1" --- Pick up the installed +-- Pick up the installed parsers in the install dir for _, parser_dir in ipairs(vim.fn.glob(rocks_path .. '/tree-sitter-*/*/', true, true)) do vim.opt.runtimepath:prepend(parser_dir) end From c3fad7d51f50b0451d579fbc498e52917c120e02 Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Mon, 8 Jun 2026 21:03:11 -0500 Subject: [PATCH 02/17] feat: Adding in several flags for neovim's calling of luarocks to prevent the need for environment configuration to install/use tree-sitter. --- gitconfig | 2 ++ nvim/lua/custom_commands.lua | 2 +- nvim/lua/plugins/mason.lua | 1 - 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/gitconfig b/gitconfig index 7847182..e6e2302 100644 --- a/gitconfig +++ b/gitconfig @@ -39,3 +39,5 @@ [include] path = ~/.config/git/local + +# vim: ft=gitconfig diff --git a/nvim/lua/custom_commands.lua b/nvim/lua/custom_commands.lua index c1ead32..55f14f9 100644 --- a/nvim/lua/custom_commands.lua +++ b/nvim/lua/custom_commands.lua @@ -10,7 +10,7 @@ end, { nargs = '*' }) vim.api.nvim_create_user_command('TreeSitterInstall', function(opts) for index, value in ipairs(opts.fargs) do if index > 0 then - local result = vim.system({ 'luarocks', 'install', 'tree-sitter-' .. value }, { text = true }):wait() + local result = vim.system({ 'luarocks', '--local', '--lua-version', '5.1', 'install', 'tree-sitter-' .. value }, { text = true }):wait() if result.code == 0 then print('Completed install of tree-sitter-' .. value) diff --git a/nvim/lua/plugins/mason.lua b/nvim/lua/plugins/mason.lua index 3935866..9ad49c9 100644 --- a/nvim/lua/plugins/mason.lua +++ b/nvim/lua/plugins/mason.lua @@ -16,7 +16,6 @@ require('mason-lspconfig').setup { 'marksman', -- markdown 'pylsp', -- Python 'rust_analyzer', -- Rust - 'ts_ls', -- Typscript 'yamlls', -- YAML } } From 4d291369e34a6cc431a2194714bdebe2a420cba1 Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Thu, 11 Jun 2026 06:46:40 -0500 Subject: [PATCH 03/17] feat: Replacement of the autopairs plugin using snippets, extension of snippets (mainly python) and cleanup of keymappings for snippets. --- nvim/after/lsp/pylsp.lua | 5 ++- nvim/lua/plugins.lua | 2 -- nvim/lua/plugins/luasnip.lua | 11 ++++--- nvim/snippets/all.lua | 36 ++++++++++++++++++++ nvim/snippets/python.lua | 64 ++++++++++++++++-------------------- wezterm/wezterm.lua | 2 ++ 6 files changed, 74 insertions(+), 46 deletions(-) create mode 100644 nvim/snippets/all.lua diff --git a/nvim/after/lsp/pylsp.lua b/nvim/after/lsp/pylsp.lua index 0bf57fe..fee203d 100644 --- a/nvim/after/lsp/pylsp.lua +++ b/nvim/after/lsp/pylsp.lua @@ -3,9 +3,9 @@ return { pylsp = { plugins = { pycodestyle = { - enabled = false, + enabled = true, ignore = { - 'E501' + 'E501' -- line-too-long }, maxLineLength = 120, }, @@ -13,7 +13,6 @@ return { enabled = true, args = { '--disable=line-too-long', - '--disable=missing-function-docstring' }, } } diff --git a/nvim/lua/plugins.lua b/nvim/lua/plugins.lua index d3cfc45..f17bf4f 100644 --- a/nvim/lua/plugins.lua +++ b/nvim/lua/plugins.lua @@ -17,13 +17,11 @@ vim.schedule(function() require('plugins.render-markdown') -- Render markdown directly in neovim vim.pack.add({ - 'https://github.com/windwp/nvim-autopairs', -- Autocomplete symbol pairs when typing 'https://github.com/tpope/vim-surround', -- Change surrounding characters (doesn't need setup called) 'https://github.com/tpope/vim-fugitive', -- _The_ Git integration plugin people have been using forever 'https://github.com/habamax/vim-godot' -- Godot specific bindings and debug }) - require('nvim-autopairs').setup() -- Automatic pair completion of paranteticals, braces, quotes, etc. require('plugins.dap') -- DAP debugging plugin require('plugins.dap-python') -- Debug plugin settings specifically for python diff --git a/nvim/lua/plugins/luasnip.lua b/nvim/lua/plugins/luasnip.lua index 0ddffca..731d01f 100644 --- a/nvim/lua/plugins/luasnip.lua +++ b/nvim/lua/plugins/luasnip.lua @@ -1,5 +1,5 @@ vim.pack.add({ - -- 'https://github.com/saadparwaiz1/cmp_luasnip', + 'https://github.com/saadparwaiz1/cmp_luasnip', 'https://github.com/rafamadriz/friendly-snippets', 'https://github.com/L3MON4D3/LuaSnip' }) @@ -18,7 +18,8 @@ local function luasnip_dependency_update() if out.code == 0 then vim.notify('LuaSnip jsregexp built successfully!', vim.log.levels.INFO) else - vim.notify('Failed to build LuaSnip jsregexp:\n' .. (out.stderr or out.stdout or ''), vim.log.levels.ERROR) + vim.notify('Failed to build LuaSnip jsregexp:\n' .. (out.stderr or out.stdout or ''), + vim.log.levels.ERROR) end end) end) @@ -42,6 +43,6 @@ require('luasnip.loaders.from_vscode').lazy_load() require('luasnip.loaders.from_lua').lazy_load({ paths = "./snippets" }) -- TODO: Figure out keymappings that make sense -vim.keymap.set({ 'i' }, '', function() require('luasnip').expand() end, { silent = true }) -vim.keymap.set({ 'i', 's' }, '', function() require('luasnip').jump(1) end, { silent = true }) -vim.keymap.set({ 'i', 's' }, '', function() require('luasnip').jump(-1) end, { silent = true }) +vim.keymap.set({ 'i' }, '', function() require('luasnip').expand() end, { silent = true }) +vim.keymap.set({ 'i', 's' }, '', function() require('luasnip').jump(1) end, { silent = true }) +vim.keymap.set({ 'i', 's' }, '', function() require('luasnip').jump(-1) end, { silent = true }) diff --git a/nvim/snippets/all.lua b/nvim/snippets/all.lua new file mode 100644 index 0000000..96e91b6 --- /dev/null +++ b/nvim/snippets/all.lua @@ -0,0 +1,36 @@ +-- require('luasnip.session.snippet_collection').clear_snippets('all') + +local ls = require('luasnip') +local s = ls.snippet +local sn = ls.snippet_node +local i = ls.insert_node +local t = ls.text_node +local c = ls.choice_node +local r = ls.restore_node + +-- Replacement of autopairs +local function pair(pair_begin, pair_end) + -- Auto-pair using snippets + return s({ trig = pair_begin, wordTrig = false }, { + t({ pair_begin }), + c(1, { + r(1, "content", i(1)), + sn(nil, { t({"", "\t"}), r(1, "content", i(1)), t({ "", "" }) }), + }), + t({ pair_end }), + }) +end + +ls.add_snippets('all', { + pair('(', ')'), + pair('{', '}'), + pair('[', ']'), + pair('<', '>'), + pair("'", "'"), + pair('"', '"'), + pair('`', '`'), +}, { + type = 'autosnippets', + key = 'all_auto', +}) +-- end autopairs diff --git a/nvim/snippets/python.lua b/nvim/snippets/python.lua index 6bbd1ba..fca7d2e 100644 --- a/nvim/snippets/python.lua +++ b/nvim/snippets/python.lua @@ -1,44 +1,36 @@ local ls = require('luasnip') local s = ls.snippet +-- local sn = ls.snippet_node local i = ls.insert_node local t = ls.text_node -local l = require('luasnip.extras').lambda +-- local l = require('luasnip.extras').lambda local fmt = require('luasnip.extras.fmt').fmt -local ts_post = require('luasnip.extras.treesitter_postfix').treesitter_postfix +-- local ts_post = require('luasnip.extras.treesitter_postfix').treesitter_postfix -return { - ts_post({ - matchTSNode = { - query = [[ - (function_definition - parameters: (parameters) @params - return_type: (type) @return - ) @prefix - ]], - query_lang = "python", - }, - trig = "docstring", - }, fmt([[ - ''' {} - - Keyword arguments: - {} () - - - Return: - {} - {} - ''' +ls.add_snippets('python', { + s('docstring single', { + t("''' "), i(0, 'text'), t(" '''") + }), + s('def', fmt([[ + def {func}({args}) -> {ret}: + ''' {doc} ''' + {body} ]], { - i(1, 'Description'), - l(l.LS_TSCAPTURE_PARAMS), - l(l.LS_TSCAPTURE_RETURN), - l(l.LS_TSDATA), + func = i(1, 'fname'), + args = i(2), + ret = i(3, 'None'), + doc = i(4, 'docstring'), + body = i(5, 'pass'), + }, { })), - -- s( - -- { trig = "thingy" }, - -- { t('Woot!') } - -- ), - -- s( - -- { trig = 'thingy2' }, - -- { t('Woot2!') } - -- ) -} + s('ternary', { + i(1, 'then'), t(' if '), i(2, 'condition'), t(' else '), i(3, 'else') + }), + s('tuple ternary', fmt([[ + ({if_true}, {if_false})[{condition}] + ]], { + if_true = i(1, 'if_true'), + if_false = i(2, 'if_false'), + condition = i(3, 'condition'), + })), +}) diff --git a/wezterm/wezterm.lua b/wezterm/wezterm.lua index 2a4a2e5..b063a81 100644 --- a/wezterm/wezterm.lua +++ b/wezterm/wezterm.lua @@ -53,6 +53,8 @@ if wezterm.target_triple == 'x86_64-unknown-linux-gnu' then config.xcursor_theme = xcursor_theme config.xcursor_size = xcursor_size -- end cursor theme + + config.disable_default_key_bindings = true end local local_config_filename = os.getenv('HOME') .. '/.config/wezterm/local.lua' From e623cfdd402bcfce6e2ddbdf6d235f8ec3c67797 Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Tue, 23 Jun 2026 07:10:09 -0500 Subject: [PATCH 04/17] fix: Cleanup of a few bits in the neovim configs and reverting to the autopairs plugin for pair completion as the snippets are not nuanced enough at the moment (or possibly ever). --- nvim/lua/plugins.lua | 2 ++ nvim/lua/plugins/telescope.lua | 24 +++++++----------------- nvim/lua/settings.lua | 4 ++-- nvim/snippets/all.lua | 4 ++-- 4 files changed, 13 insertions(+), 21 deletions(-) diff --git a/nvim/lua/plugins.lua b/nvim/lua/plugins.lua index f17bf4f..3cfd3a5 100644 --- a/nvim/lua/plugins.lua +++ b/nvim/lua/plugins.lua @@ -17,11 +17,13 @@ vim.schedule(function() require('plugins.render-markdown') -- Render markdown directly in neovim vim.pack.add({ + 'https://github.com/windwp/nvim-autopairs', -- Autocomplete symbol pairs when typing TODO: disabled for now, using snippets instead. remove if that feels better 'https://github.com/tpope/vim-surround', -- Change surrounding characters (doesn't need setup called) 'https://github.com/tpope/vim-fugitive', -- _The_ Git integration plugin people have been using forever 'https://github.com/habamax/vim-godot' -- Godot specific bindings and debug }) + require('nvim-autopairs').setup() -- Automatic pair completion of paranteticals, braces, quotes, etc. require('plugins.dap') -- DAP debugging plugin require('plugins.dap-python') -- Debug plugin settings specifically for python diff --git a/nvim/lua/plugins/telescope.lua b/nvim/lua/plugins/telescope.lua index 70d9db8..b4ab0ff 100644 --- a/nvim/lua/plugins/telescope.lua +++ b/nvim/lua/plugins/telescope.lua @@ -1,6 +1,5 @@ vim.pack.add({ - 'https://github.com/kevinhwang91/nvim-bqf', - 'https://github.com/nvim-telescope/telescope-file-browser.nvim', + -- 'https://github.com/kevinhwang91/nvim-bqf', 'https://github.com/nvim-lua/plenary.nvim', 'https://github.com/nvim-telescope/telescope.nvim', }) @@ -23,9 +22,7 @@ require('telescope').setup { layout_config = { prompt_position = 'bottom' }, -- layout_strategy = 'vertical', mappings = { - i = { - [''] = require('telescope.actions').close, - }, + i = { [''] = require('telescope.actions').close, }, }, prompt_prefix = '  ', results_title = false, @@ -35,7 +32,6 @@ require('telescope').setup { }, pickers = { diagnostics = { - -- theme = 'ivy', initial_mode = 'normal', layout_config = { preview_cutoff = 9999, @@ -46,18 +42,12 @@ require('telescope').setup { local builtin = require('telescope.builtin') -vim.keymap.set('n', ';f', function() - builtin.find_files({ - no_ignore = false, - hidden = true, - }) -end) - -vim.keymap.set('n', ';r', function() builtin.live_grep() end) -vim.keymap.set('n', ';b', function() builtin.buffers() end) -vim.keymap.set('n', ';h', function() builtin.help_tags() end) vim.keymap.set('n', ';;', function() builtin.resume() end) +vim.keymap.set('n', ';b', function() builtin.buffers() end) vim.keymap.set('n', ';d', function() builtin.diagnostics() end) -vim.keymap.set('n', ';t', function() builtin.treesitter() end) +vim.keymap.set('n', ';f', function() builtin.find_files({ no_ignore = false, hidden = true }) end) +vim.keymap.set('n', ';h', function() builtin.help_tags() end) +vim.keymap.set('n', ';r', function() builtin.live_grep() end) vim.keymap.set('n', ';s', function() builtin.lsp_document_symbols() end) +vim.keymap.set('n', ';t', function() builtin.treesitter() end) vim.keymap.set('n', ';w', function() builtin.lsp_dynamic_workspace_symbols() end) diff --git a/nvim/lua/settings.lua b/nvim/lua/settings.lua index 87391fd..7a0e63c 100644 --- a/nvim/lua/settings.lua +++ b/nvim/lua/settings.lua @@ -8,7 +8,7 @@ vim.opt.cursorcolumn = true -- Highlight vim.opt.cursorline = true -- Highlight the line the cursor is on. vim.opt.expandtab = true -- Expand tabs into spaces vim.opt.fileformat = 'unix' -- Explicitly state that files should use the unix style EOL characters. --- vim.opt.fillchars = 'fold: ' -- Sets the character that fills in a fold line (removes the dots) +vim.opt.fillchars = 'fold: ' -- Sets the character that fills in a fold line (removes the dots) vim.opt.foldcolumn = '0' -- Disables the foldcolumn vim.opt.foldexpr = 'v:lua.vim.treesitter.foldexpr()' -- Uses Treesitter to determine where code folding should occur vim.opt.foldlevel = 10 -- Sets the initial level at which folds will be closed @@ -22,7 +22,7 @@ vim.opt.listchars = 'tab:|·,trail:¬,extends:»,precedes:«,nbsp:+' -- Chara vim.opt.mouse = 'a' -- Enable mouse mode vim.opt.number = true -- Show the line number in the gutter. vim.opt.pumheight = 15 -- Maximum height of the auto complete floating window -vim.opt.relativenumber = true -- Relative line number +-- vim.opt.relativenumber = true -- Relative line number vim.opt.sidescrolloff = 8 -- Side scrolling leadoff to keep the cursor a few characters from the screen edge instead of going all the way to it vim.opt.shiftround = true -- Round indentation to shiftwidth vim.opt.shiftwidth = 4 -- Number of spaces a tab counts for when converting tabs to spaces diff --git a/nvim/snippets/all.lua b/nvim/snippets/all.lua index 96e91b6..8d4a7d9 100644 --- a/nvim/snippets/all.lua +++ b/nvim/snippets/all.lua @@ -30,7 +30,7 @@ ls.add_snippets('all', { pair('"', '"'), pair('`', '`'), }, { - type = 'autosnippets', - key = 'all_auto', + -- type = 'autosnippets', + -- key = 'all_auto', }) -- end autopairs From 96e93d46ce8f3aa4f0ce6af7fbc135c59a21a2b2 Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Wed, 8 Jul 2026 14:05:40 -0500 Subject: [PATCH 05/17] feat: Adding in a custom statuscolumn formatting function and lua file --- nvim/lua/autocmds.lua | 53 ++++++++++++++++-------- nvim/lua/settings.lua | 84 +++++++++++++++++++-------------------- nvim/lua/statuscolumn.lua | 23 +++++++++++ 3 files changed, 102 insertions(+), 58 deletions(-) create mode 100644 nvim/lua/statuscolumn.lua diff --git a/nvim/lua/autocmds.lua b/nvim/lua/autocmds.lua index 30969e1..4ef67e9 100644 --- a/nvim/lua/autocmds.lua +++ b/nvim/lua/autocmds.lua @@ -1,22 +1,43 @@ +-- Autocommands for handling large files and switching between large file buffers and others +local largefile_group = vim.api.nvim_create_augroup('largefile', { clear = true }) +local max_filesize = 4 * (1024 * 1024) -- 4 MB + +local old_eventignore = false + -- Disables syntax, treesitter and folding on larger files vim.api.nvim_create_autocmd({ 'BufReadPre' }, { - pattern = '*', - group = vim.api.nvim_create_augroup('largefile', { clear = true }), - callback = function(args) - local max_filesize_MiB = 1 + group = largefile_group, + callback = function(ev) + if ev.file then + local status, size = pcall(function() return vim.loop.fs_stat(ev.file).size end) + if status and size > max_filesize then + old_eventignore = vim.o.eventignore + vim.o.eventignore = 'FileType' -- Reduce the calls for filetype specific plugins or syntax highlighting - local _, stats = pcall(function() - return vim.loop.fs_stat(vim.api.nvim_buf_get_name(args.buf)) - end) - - local file_size = math.floor(0.5 + (stats.size / (1024 * 1024))) - - if file_size > max_filesize_MiB then - print(string.format('File detected above %sMiB. Disabling syntax, treesitter, and folding.', max_filesize_MiB)) - vim.api.nvim_command('set foldmethod=manual') - vim.api.nvim_command('set noswapfile') - vim.api.nvim_command('set noundofile') - vim.api.nvim_command('set noloadplugins') + vim.b[ev.buf].is_large_file = true + vim.bo['bufhidden'] = 'unload' + vim.bo['buftype'] = 'nowrite' + vim.bo['swapfile'] = false + vim.bo['undofile'] = false + vim.bo['undolevels'] = -1 + end end end, }) + +vim.api.nvim_create_autocmd({ 'BufWinEnter' }, { + group = largefile_group, + callback = function(ev) + if old_eventignore ~= false then + vim.o.eventignore = old_eventignore -- Restore the old setting + old_eventignore = false + end + if vim.b[ev.buf].is_large_file then + vim.wo.wrap = false + else + vim.wo.wrap = vim.o.wrap -- Restore to default setting + end + end +}) + +-- End large file handling diff --git a/nvim/lua/settings.lua b/nvim/lua/settings.lua index 7a0e63c..96fc38f 100644 --- a/nvim/lua/settings.lua +++ b/nvim/lua/settings.lua @@ -1,47 +1,47 @@ -- Experimental -- vim.o.autocomplete = true -vim.opt.background = 'dark' -- Force a dark background for the colorscheme -vim.opt.clipboard = 'unnamed,unnamedplus' -- Use both the "*" and "+" registers for yanks and deletes (puts things in the system clipboard) -vim.opt.completeopt = 'fuzzy,menuone,noinsert,popup' -- Change how the completion menu is interacted with and displays -vim.opt.cursorcolumn = true -- Highlight the column the cursor is on -vim.opt.cursorline = true -- Highlight the line the cursor is on. -vim.opt.expandtab = true -- Expand tabs into spaces -vim.opt.fileformat = 'unix' -- Explicitly state that files should use the unix style EOL characters. -vim.opt.fillchars = 'fold: ' -- Sets the character that fills in a fold line (removes the dots) -vim.opt.foldcolumn = '0' -- Disables the foldcolumn -vim.opt.foldexpr = 'v:lua.vim.treesitter.foldexpr()' -- Uses Treesitter to determine where code folding should occur -vim.opt.foldlevel = 10 -- Sets the initial level at which folds will be closed -vim.opt.foldlevelstart = 4 -- Sets the initial fold level -vim.opt.foldmethod = 'expr' -- Attempt to use the syntax of a file to set folds. -vim.opt.foldnestmax = 4 -- Maximum level of fold nesting -vim.opt.formatoptions = 'cqrto' -- Allow auto insertion of comment lines when using o or O on a comment. -vim.opt.ignorecase = true -- Case-insensitive searching -vim.opt.list = true -- Show the listchars -vim.opt.listchars = 'tab:|·,trail:¬,extends:»,precedes:«,nbsp:+' -- Characters to display when showing whitespace -vim.opt.mouse = 'a' -- Enable mouse mode -vim.opt.number = true -- Show the line number in the gutter. -vim.opt.pumheight = 15 -- Maximum height of the auto complete floating window --- vim.opt.relativenumber = true -- Relative line number -vim.opt.sidescrolloff = 8 -- Side scrolling leadoff to keep the cursor a few characters from the screen edge instead of going all the way to it -vim.opt.shiftround = true -- Round indentation to shiftwidth -vim.opt.shiftwidth = 4 -- Number of spaces a tab counts for when converting tabs to spaces -vim.opt.shortmess = 'at' -- Abbreviations and truncation of cmd messages -vim.opt.showmatch = true -- Show matching bracket -vim.opt.signcolumn = 'yes' -- Always show the gutter -vim.opt.smartcase = true -- Keeps searches Case-insensitive until the search has an upper case character -vim.opt.smartindent = true -- Attempt to insert indentation to fit traditional languages. -vim.opt.softtabstop = 4 -- Number of spaces a tab counts for when converting tabs to spaces -vim.opt.splitbelow = true -- Split windows below when horizontal splitting -vim.opt.splitright = true -- Split windows right when vertical splitting -vim.opt.swapfile = false -- Disable the creation of swap files for open files -vim.opt.tabstop = 4 -- Setting the value of spaces per tab -vim.opt.termguicolors = true -- Enable the truecolor GUI colors in a terminal -vim.opt.undodir = os.getenv('HOME') .. '/.config/nvim/undodir' -- Set a specific undo file directory -vim.opt.undofile = true -- Enable undo files -vim.opt.updatetime = 300 -- Swapfile update time in milliseconds -vim.opt.wrap = false -- Do _not_ wrap lines +vim.opt.background = 'dark' -- Force a dark background for the colorscheme +vim.opt.clipboard = 'unnamed,unnamedplus' -- Use both the "*" and "+" registers for yanks and deletes (puts things in the system clipboard) +vim.opt.completeopt = 'fuzzy,menuone,noinsert,popup' -- Change how the completion menu is interacted with and displays +vim.opt.cursorcolumn = true -- Highlight the column the cursor is on +vim.opt.cursorline = true -- Highlight the line the cursor is on. +vim.opt.expandtab = true -- Expand tabs into spaces +vim.opt.fileformat = 'unix' -- Explicitly state that files should use the unix style EOL characters. +vim.opt.fillchars = 'fold: ' -- Sets the character that fills in a fold line (removes the dots) +vim.opt.foldcolumn = '0' -- Disables the foldcolumn +vim.opt.foldexpr = 'v:lua.vim.treesitter.foldexpr()' -- Uses Treesitter to determine where code folding should occur +vim.opt.foldlevel = 10 -- Sets the initial level at which folds will be closed +vim.opt.foldlevelstart = 4 -- Sets the initial fold level +vim.opt.foldmethod = 'expr' -- Attempt to use the syntax of a file to set folds. +vim.opt.foldnestmax = 4 -- Maximum level of fold nesting +vim.opt.formatoptions = 'cqrto' -- Allow auto insertion of comment lines when using o or O on a comment. +vim.opt.ignorecase = true -- Case-insensitive searching +vim.opt.list = true -- Show the listchars +vim.opt.listchars = 'tab:|·,trail:¬,extends:»,precedes:«,nbsp:+' -- Characters to display when showing whitespace +vim.opt.mouse = 'a' -- Enable mouse mode +vim.opt.number = true -- Show the line number in the gutter. +vim.opt.pumheight = 15 -- Maximum height of the auto complete floating window +vim.opt.sidescrolloff = 8 -- Side scrolling leadoff to keep the cursor a few characters from the screen edge instead of going all the way to it +vim.opt.shiftround = true -- Round indentation to shiftwidth +vim.opt.shiftwidth = 4 -- Number of spaces a tab counts for when converting tabs to spaces +vim.opt.shortmess = 'at' -- Abbreviations and truncation of cmd messages +vim.opt.showmatch = true -- Show matching bracket +vim.opt.signcolumn = 'yes' -- Always show the gutter +vim.opt.smartcase = true -- Keeps searches Case-insensitive until the search has an upper case character +vim.opt.smartindent = true -- Attempt to insert indentation to fit traditional languages. +vim.opt.softtabstop = 4 -- Number of spaces a tab counts for when converting tabs to spaces +vim.opt.splitbelow = true -- Split windows below when horizontal splitting +vim.opt.splitright = true -- Split windows right when vertical splitting +vim.opt.statuscolumn = "%!v:lua.require('statuscolumn').statusColumn()" -- Formatting for the statuscolumn (and gutter) +vim.opt.swapfile = false -- Disable the creation of swap files for open files +vim.opt.tabstop = 4 -- Setting the value of spaces per tab +vim.opt.termguicolors = true -- Enable the truecolor GUI colors in a terminal +vim.opt.undodir = os.getenv('HOME') .. '/.config/nvim/undodir' -- Set a specific undo file directory +vim.opt.undofile = true -- Enable undo files +vim.opt.updatetime = 300 -- Swapfile update time in milliseconds +vim.opt.wrap = false -- Do _not_ wrap lines vim.g.netrw_banner = 0 -vim.g.netrw_liststyle = 3 -- Use the tree style display for netrw directory listings -vim.g.netrw_winsize = 25 -- Percentage based pane size for directory exploring +vim.g.netrw_liststyle = 3 -- Use the tree style display for netrw directory listings +vim.g.netrw_winsize = 25 -- Percentage based pane size for directory exploring diff --git a/nvim/lua/statuscolumn.lua b/nvim/lua/statuscolumn.lua new file mode 100644 index 0000000..a1a03c3 --- /dev/null +++ b/nvim/lua/statuscolumn.lua @@ -0,0 +1,23 @@ +local statuscolumn = {} + +statuscolumn.border = function () + return '│' +end + +statuscolumn.numbers = function (config) + return string.format('%-3s %2s ', vim.v.lnum, vim.v.relnum) +end + +statuscolumn.statusColumn = function() + local column_text = '' + + column_text = table.concat({ + '%s', + statuscolumn.numbers(), + statuscolumn.border(), + }) + + return column_text +end + +return statuscolumn From c8ecc183b85b775d5ce1fd18bf3a45d42ee424ad Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Wed, 8 Jul 2026 14:08:07 -0500 Subject: [PATCH 06/17] doc: Adding gitconfig info to the README --- README.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 7a3b596..52e1055 100644 --- a/README.md +++ b/README.md @@ -7,9 +7,9 @@ Included are configs for: - tmux - wezterm - zsh +- gitconfig Planned configs are: -- gitconfig - newsboat ## Deployment @@ -97,3 +97,9 @@ The config adds the following settings outside of oh-my-zsh: - `zsh_exports`: Exported variables for the system - `zsh_functions`: Custom functions beyond simple aliasing can fulfill but not requiring a script - `zsh_local`: Local ZSH settings for a specific system such as any environment specific bash required to set up a system's shell or direct ZSH settings + +### Gitconfig + +The gitconfig, centered on nvim integration, gives contains a selection of useful aliases and sets some basic defaults. + +It also includes a local override config hosted at `~/.config/git/local` for adding username and email as well as any other options needed for a local machine. From f88871bc4ed2d5e955a02ffffe84396963562ff9 Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Wed, 8 Jul 2026 18:13:05 -0500 Subject: [PATCH 07/17] fix: Formatting and addition/disable of folding visualization in the new statuscolumn --- nvim/lua/statuscolumn.lua | 31 +++++++++++++++++++++++++++++-- 1 file changed, 29 insertions(+), 2 deletions(-) diff --git a/nvim/lua/statuscolumn.lua b/nvim/lua/statuscolumn.lua index a1a03c3..b8ac179 100644 --- a/nvim/lua/statuscolumn.lua +++ b/nvim/lua/statuscolumn.lua @@ -1,10 +1,36 @@ local statuscolumn = {} -statuscolumn.border = function () +statuscolumn.border = function() return '│' end -statuscolumn.numbers = function (config) +statuscolumn.folds = function() + local foldlevel = vim.fn.foldlevel(vim.v.lnum) + local foldlevel_before = vim.fn.foldlevel((vim.v.lnum - 1) >= 1 and vim.v.lnum - 1 or 1) + local foldlevel_after = vim.fn.foldlevel((vim.v.lnum + 1) <= vim.fn.line('$') and (vim.v.lnum + 1) or vim.fn.line('$')) + + local foldclosed = vim.fn.foldclosed(vim.v.lnum) + + if foldlevel == 0 then + return ' ' + end + + if foldclosed ~= -1 and foldclosed == vim.v.lnum then + return '▶' + end + + if foldlevel > foldlevel_before then + return '▽' + end + + if foldlevel > foldlevel_after then + return '╰' + end + + return '╎' +end + +statuscolumn.numbers = function() return string.format('%-3s %2s ', vim.v.lnum, vim.v.relnum) end @@ -15,6 +41,7 @@ statuscolumn.statusColumn = function() '%s', statuscolumn.numbers(), statuscolumn.border(), + -- statuscolumn.folds(), ' ', }) return column_text From cf2e947d4315a17a728f01598232266e4ca7df5a Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Wed, 8 Jul 2026 19:58:39 -0500 Subject: [PATCH 08/17] feat: Adding a gradient to the border between the statuscolumn and the text body --- nvim/lua/statuscolumn.lua | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/nvim/lua/statuscolumn.lua b/nvim/lua/statuscolumn.lua index b8ac179..57e8a31 100644 --- a/nvim/lua/statuscolumn.lua +++ b/nvim/lua/statuscolumn.lua @@ -1,7 +1,29 @@ local statuscolumn = {} +statuscolumn.setHL = function () + local colors = { + '#888cd8', + '#8081cd', + '#7877c2', + '#706cb7', + '#6862ad', + '#6057a2', + '#584d97', + '#50438d', + '#493a82', + '#413078', + } + for i, color in ipairs(colors) do + vim.api.nvim_set_hl(0, 'Gradient_' .. i, { fg = color }) + end +end + statuscolumn.border = function() - return '│' + if vim.v.relnum < 9 then + return '%#Gradient_' .. (vim.v.relnum + 1) .. '#│' + else + return '%#Gradient_10#│' + end end statuscolumn.folds = function() @@ -37,6 +59,8 @@ end statuscolumn.statusColumn = function() local column_text = '' + statuscolumn.setHL() + column_text = table.concat({ '%s', statuscolumn.numbers(), From 5741c3ad4ed5c33a31d97f36109692f93624db73 Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Thu, 9 Jul 2026 03:12:22 -0500 Subject: [PATCH 09/17] fix: Reverting the statuscolumn gradient addition for now --- nvim/lua/statuscolumn.lua | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/nvim/lua/statuscolumn.lua b/nvim/lua/statuscolumn.lua index 57e8a31..356136d 100644 --- a/nvim/lua/statuscolumn.lua +++ b/nvim/lua/statuscolumn.lua @@ -19,11 +19,12 @@ statuscolumn.setHL = function () end statuscolumn.border = function() - if vim.v.relnum < 9 then - return '%#Gradient_' .. (vim.v.relnum + 1) .. '#│' - else - return '%#Gradient_10#│' - end + -- if vim.v.relnum < 9 then + -- return '%#Gradient_' .. (vim.v.relnum + 1) .. '#│' + -- else + -- return '%#Gradient_10#│' + -- end + return '│' end statuscolumn.folds = function() From 4efc81858c5dbbefe5410bb3f5b4f4f3e3435e15 Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Wed, 15 Jul 2026 15:40:24 -0500 Subject: [PATCH 10/17] fix: changing up the statuscolumn setup --- nvim/lua/keymappings.lua | 7 +++++++ nvim/lua/plugins.lua | 1 - nvim/lua/statuscolumn.lua | 12 +++++++++--- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/nvim/lua/keymappings.lua b/nvim/lua/keymappings.lua index b16bb8a..8762d2d 100644 --- a/nvim/lua/keymappings.lua +++ b/nvim/lua/keymappings.lua @@ -66,3 +66,10 @@ vim.keymap.set('n', 'eo', ':Lexplore', options) -- Allow for leaving Terminal mode using the escape key instead of the odd default vim.keymap.set('t', '', '') + +local sc = require('statuscolumn') +vim.keymap.set('n', 'q', function () + print('woot') + sc.show_both_nums = not sc.show_both_nums + vim.opt.statuscolumn = "%!v:lua.require('statuscolumn').statusColumn()" +end) diff --git a/nvim/lua/plugins.lua b/nvim/lua/plugins.lua index 3cfd3a5..8484d25 100644 --- a/nvim/lua/plugins.lua +++ b/nvim/lua/plugins.lua @@ -13,7 +13,6 @@ vim.schedule(function() require('plugins.telescope') -- Floating window fuzzy searching different sources require('plugins.telekasten') -- Note taking plugin require('plugins.mason') -- LSP and DAP manager - -- require('plugins.twilight') -- Focus mode, dim lines around the cursor's location require('plugins.render-markdown') -- Render markdown directly in neovim vim.pack.add({ diff --git a/nvim/lua/statuscolumn.lua b/nvim/lua/statuscolumn.lua index 356136d..c5661f1 100644 --- a/nvim/lua/statuscolumn.lua +++ b/nvim/lua/statuscolumn.lua @@ -1,5 +1,7 @@ local statuscolumn = {} +local show_both_nums = false + statuscolumn.setHL = function () local colors = { '#888cd8', @@ -54,18 +56,22 @@ statuscolumn.folds = function() end statuscolumn.numbers = function() - return string.format('%-3s %2s ', vim.v.lnum, vim.v.relnum) + if show_both_nums then + return string.format('%-3s %2s ', vim.v.lnum, vim.v.relnum) + else + return string.format('%2s', vim.v.relnum) + end end statuscolumn.statusColumn = function() local column_text = '' - statuscolumn.setHL() + -- statuscolumn.setHL() column_text = table.concat({ '%s', statuscolumn.numbers(), - statuscolumn.border(), + -- statuscolumn.border(), -- statuscolumn.folds(), ' ', }) From 1425ee295cac40d86a983ec5ba32394905e6b72a Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Tue, 21 Jul 2026 11:29:39 -0500 Subject: [PATCH 11/17] fix: Cleaning up the settings and removing the statusColumn override that was causing formatting issues. --- nvim/lua/settings.lua | 86 +++++++++++++++++++++---------------------- 1 file changed, 43 insertions(+), 43 deletions(-) diff --git a/nvim/lua/settings.lua b/nvim/lua/settings.lua index 96fc38f..03ef825 100644 --- a/nvim/lua/settings.lua +++ b/nvim/lua/settings.lua @@ -1,47 +1,47 @@ -- Experimental -- vim.o.autocomplete = true -vim.opt.background = 'dark' -- Force a dark background for the colorscheme -vim.opt.clipboard = 'unnamed,unnamedplus' -- Use both the "*" and "+" registers for yanks and deletes (puts things in the system clipboard) -vim.opt.completeopt = 'fuzzy,menuone,noinsert,popup' -- Change how the completion menu is interacted with and displays -vim.opt.cursorcolumn = true -- Highlight the column the cursor is on -vim.opt.cursorline = true -- Highlight the line the cursor is on. -vim.opt.expandtab = true -- Expand tabs into spaces -vim.opt.fileformat = 'unix' -- Explicitly state that files should use the unix style EOL characters. -vim.opt.fillchars = 'fold: ' -- Sets the character that fills in a fold line (removes the dots) -vim.opt.foldcolumn = '0' -- Disables the foldcolumn -vim.opt.foldexpr = 'v:lua.vim.treesitter.foldexpr()' -- Uses Treesitter to determine where code folding should occur -vim.opt.foldlevel = 10 -- Sets the initial level at which folds will be closed -vim.opt.foldlevelstart = 4 -- Sets the initial fold level -vim.opt.foldmethod = 'expr' -- Attempt to use the syntax of a file to set folds. -vim.opt.foldnestmax = 4 -- Maximum level of fold nesting -vim.opt.formatoptions = 'cqrto' -- Allow auto insertion of comment lines when using o or O on a comment. -vim.opt.ignorecase = true -- Case-insensitive searching -vim.opt.list = true -- Show the listchars -vim.opt.listchars = 'tab:|·,trail:¬,extends:»,precedes:«,nbsp:+' -- Characters to display when showing whitespace -vim.opt.mouse = 'a' -- Enable mouse mode -vim.opt.number = true -- Show the line number in the gutter. -vim.opt.pumheight = 15 -- Maximum height of the auto complete floating window -vim.opt.sidescrolloff = 8 -- Side scrolling leadoff to keep the cursor a few characters from the screen edge instead of going all the way to it -vim.opt.shiftround = true -- Round indentation to shiftwidth -vim.opt.shiftwidth = 4 -- Number of spaces a tab counts for when converting tabs to spaces -vim.opt.shortmess = 'at' -- Abbreviations and truncation of cmd messages -vim.opt.showmatch = true -- Show matching bracket -vim.opt.signcolumn = 'yes' -- Always show the gutter -vim.opt.smartcase = true -- Keeps searches Case-insensitive until the search has an upper case character -vim.opt.smartindent = true -- Attempt to insert indentation to fit traditional languages. -vim.opt.softtabstop = 4 -- Number of spaces a tab counts for when converting tabs to spaces -vim.opt.splitbelow = true -- Split windows below when horizontal splitting -vim.opt.splitright = true -- Split windows right when vertical splitting -vim.opt.statuscolumn = "%!v:lua.require('statuscolumn').statusColumn()" -- Formatting for the statuscolumn (and gutter) -vim.opt.swapfile = false -- Disable the creation of swap files for open files -vim.opt.tabstop = 4 -- Setting the value of spaces per tab -vim.opt.termguicolors = true -- Enable the truecolor GUI colors in a terminal -vim.opt.undodir = os.getenv('HOME') .. '/.config/nvim/undodir' -- Set a specific undo file directory -vim.opt.undofile = true -- Enable undo files -vim.opt.updatetime = 300 -- Swapfile update time in milliseconds -vim.opt.wrap = false -- Do _not_ wrap lines +vim.opt.background = 'dark' -- Force a dark background for the colorscheme +vim.opt.clipboard = 'unnamed,unnamedplus' -- Use both the "*" and "+" registers for yanks and deletes (puts things in the system clipboard) +vim.opt.completeopt = 'fuzzy,menuone,noinsert,popup' -- Change how the completion menu is interacted with and displays +vim.opt.cursorcolumn = true -- Highlight the column the cursor is on +vim.opt.cursorline = true -- Highlight the line the cursor is on. +vim.opt.expandtab = true -- Expand tabs into spaces +vim.opt.fileformat = 'unix' -- Explicitly state that files should use the unix style EOL characters. +vim.opt.fillchars = 'fold: ' -- Sets the character that fills in a fold line (removes the dots) +vim.opt.foldcolumn = '0' -- Disables the foldcolumn +vim.opt.foldexpr = 'v:lua.vim.treesitter.foldexpr()' -- Uses Treesitter to determine where code folding should occur +vim.opt.foldlevel = 10 -- Sets the initial level at which folds will be closed +vim.opt.foldlevelstart = 4 -- Sets the initial fold level +vim.opt.foldmethod = 'expr' -- Attempt to use the syntax of a file to set folds. +vim.opt.foldnestmax = 4 -- Maximum level of fold nesting +vim.opt.formatoptions = 'cqrto' -- Allow auto insertion of comment lines when using o or O on a comment. +vim.opt.ignorecase = true -- Case-insensitive searching +vim.opt.list = true -- Show the listchars +vim.opt.listchars = 'tab:|·,trail:¬,extends:»,precedes:«,nbsp:+' -- Characters to display when showing whitespace +vim.opt.mouse = 'a' -- Enable mouse mode +vim.opt.number = true -- Show the line number in the gutter. +vim.opt.pumheight = 15 -- Maximum height of the auto complete floating window +vim.opt.relativenumber = true -- Show the relative line numbers +vim.opt.sidescrolloff = 8 -- Side scrolling leadoff to keep the cursor a few characters from the screen edge instead of going all the way to it +vim.opt.shiftround = true -- Round indentation to shiftwidth +vim.opt.shiftwidth = 4 -- Number of spaces a tab counts for when converting tabs to spaces +vim.opt.shortmess = 'at' -- Abbreviations and truncation of cmd messages +vim.opt.showmatch = true -- Show matching bracket +vim.opt.signcolumn = 'yes' -- Always show the gutter +vim.opt.smartcase = true -- Keeps searches Case-insensitive until the search has an upper case character +vim.opt.smartindent = true -- Attempt to insert indentation to fit traditional languages. +vim.opt.softtabstop = 4 -- Number of spaces a tab counts for when converting tabs to spaces +vim.opt.splitbelow = true -- Split windows below when horizontal splitting +vim.opt.splitright = true -- Split windows right when vertical splitting +vim.opt.swapfile = false -- Disable the creation of swap files for open files +vim.opt.tabstop = 4 -- Setting the value of spaces per tab +vim.opt.termguicolors = true -- Enable the truecolor GUI colors in a terminal +vim.opt.undodir = os.getenv('HOME') .. '/.config/nvim/undodir' -- Set a specific undo file directory +vim.opt.undofile = true -- Enable undo files +vim.opt.updatetime = 300 -- Swapfile update time in milliseconds +vim.opt.wrap = false -- Do _not_ wrap lines -vim.g.netrw_banner = 0 -vim.g.netrw_liststyle = 3 -- Use the tree style display for netrw directory listings -vim.g.netrw_winsize = 25 -- Percentage based pane size for directory exploring +vim.g.netrw_banner = 0 -- Remove the banner +vim.g.netrw_liststyle = 3 -- Use the tree style display for netrw directory listings +vim.g.netrw_winsize = 25 -- Percentage based pane size for directory exploring From 7466b19fd09a551998259717a271a75ad917fc03 Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Tue, 21 Jul 2026 11:30:13 -0500 Subject: [PATCH 12/17] fix: Updating the tmux configuration for clipboard management, removal of the `tmux-sensible` plugin and cherry-picking of some settings from it. --- tmux.conf | 26 +++++++++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/tmux.conf b/tmux.conf index 3ce927d..37d2e5b 100644 --- a/tmux.conf +++ b/tmux.conf @@ -1,12 +1,33 @@ # True color support -set-option -g default-terminal 'tmux-256color' -set-option -ga terminal-overrides ',xterm-256color:Tc' +set-option -ga terminal-overrides ',xterm-*:Tc' # Set encoding to Unicode8 setw -gq utf8 on +set -g status-interval 5 +set -g display-time 4000 + +# Numbering changes +set -g base-index 1 +set -g pane-base-index 1 +set -g renumber-windows on + +# History lengthening from the default 2k +set -g history-limit 50000 + +setw -g mode-keys vi + +set -g focus-events on + +# Window resizing on host shell size changes TODO: needs testing with pair coding +set -g window-size latest +setw -g aggressive-resize on + +# set -g default-command 'reattach-to-user-namespace -l $SHELL' # TODO: Is this necessary for Mac still? + # Allow for external system clipboard set-option -g set-clipboard external +set-option -g allow-passthrough on # Allow mouse interactions set -g mouse on @@ -37,7 +58,6 @@ bind -n M-l next-window # Plugins set -g @plugin 'tmux-plugins/tpm' -set -g @plugin 'tmux-plugins/tmux-sensible' set -g @plugin 'tmux-plugins/tmux-yank' set -g @plugin 'egel/tmux-gruvbox' From 1b1777ecfec6ba405d34b0a51c83ade1f089e6dc Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Sun, 26 Jul 2026 20:29:45 -0500 Subject: [PATCH 13/17] fix: disabling the import-errors in pylint --- nvim/after/lsp/pylsp.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nvim/after/lsp/pylsp.lua b/nvim/after/lsp/pylsp.lua index fee203d..335d2f1 100644 --- a/nvim/after/lsp/pylsp.lua +++ b/nvim/after/lsp/pylsp.lua @@ -12,7 +12,7 @@ return { pylint = { enabled = true, args = { - '--disable=line-too-long', + '--disable=line-too-long,import-error', }, } } From e751cee7785563b524b27ba5887e53e035c9d995 Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Thu, 30 Jul 2026 05:41:44 -0500 Subject: [PATCH 14/17] feat: Removing the old web-devicons from lualine, disabling the snippet style auto-pair attempt (will continue on other branches), disabling passthrough in tmux as it is not seemingly necessary for clipboard usage (remote testing needed), disabling the old mouse cursor fix for X systems. Adding the wezterm shortcuts for actually using the Clipboard for pasting using the usual ctrl+shift+v combo. --- nvim/lua/plugins/lualine.lua | 1 - nvim/snippets/all.lua | 65 ++++++++++++++++++------------------ tmux.conf | 2 +- wezterm/wezterm.lua | 61 +++++++++++++++++---------------- 4 files changed, 67 insertions(+), 62 deletions(-) diff --git a/nvim/lua/plugins/lualine.lua b/nvim/lua/plugins/lualine.lua index 7778361..e50acc5 100644 --- a/nvim/lua/plugins/lualine.lua +++ b/nvim/lua/plugins/lualine.lua @@ -7,7 +7,6 @@ local function get_schema() end vim.pack.add({ - -- 'https://github.com/nvim-tree/nvim-web-devicons', 'https://github.com/nvim-lualine/lualine.nvim' }) diff --git a/nvim/snippets/all.lua b/nvim/snippets/all.lua index 8d4a7d9..5208611 100644 --- a/nvim/snippets/all.lua +++ b/nvim/snippets/all.lua @@ -1,36 +1,37 @@ -- require('luasnip.session.snippet_collection').clear_snippets('all') -local ls = require('luasnip') -local s = ls.snippet -local sn = ls.snippet_node -local i = ls.insert_node -local t = ls.text_node -local c = ls.choice_node -local r = ls.restore_node +-- local ls = require('luasnip') +-- local s = ls.snippet +-- local sn = ls.snippet_node +-- local i = ls.insert_node +-- local t = ls.text_node +-- local c = ls.choice_node +-- local r = ls.restore_node +-- +-- -- Replacement of autopairs +-- local function pair(pair_begin, pair_end) +-- -- Auto-pair using snippets +-- return s({ trig = pair_begin, wordTrig = false }, { +-- t({ pair_begin }), +-- c(1, { +-- r(1, "content", i(1)), +-- sn(nil, { t({"", "\t"}), r(1, "content", i(1)), t({ "", "" }) }), +-- }), +-- t({ pair_end }), +-- }) +-- end +-- +-- ls.add_snippets('all', { +-- pair('(', ')'), +-- pair('{', '}'), +-- pair('[', ']'), +-- pair('<', '>'), +-- pair("'", "'"), +-- pair('"', '"'), +-- pair('`', '`'), +-- }, { +-- -- type = 'autosnippets', +-- -- key = 'all_auto', +-- }) --- Replacement of autopairs -local function pair(pair_begin, pair_end) - -- Auto-pair using snippets - return s({ trig = pair_begin, wordTrig = false }, { - t({ pair_begin }), - c(1, { - r(1, "content", i(1)), - sn(nil, { t({"", "\t"}), r(1, "content", i(1)), t({ "", "" }) }), - }), - t({ pair_end }), - }) -end - -ls.add_snippets('all', { - pair('(', ')'), - pair('{', '}'), - pair('[', ']'), - pair('<', '>'), - pair("'", "'"), - pair('"', '"'), - pair('`', '`'), -}, { - -- type = 'autosnippets', - -- key = 'all_auto', -}) -- end autopairs diff --git a/tmux.conf b/tmux.conf index 37d2e5b..33344be 100644 --- a/tmux.conf +++ b/tmux.conf @@ -27,7 +27,7 @@ setw -g aggressive-resize on # Allow for external system clipboard set-option -g set-clipboard external -set-option -g allow-passthrough on +# set-option -g allow-passthrough on # Allow mouse interactions set -g mouse on diff --git a/wezterm/wezterm.lua b/wezterm/wezterm.lua index b063a81..605559e 100644 --- a/wezterm/wezterm.lua +++ b/wezterm/wezterm.lua @@ -1,10 +1,10 @@ local wezterm = require 'wezterm' +local act = wezterm.action local config = wezterm.config_builder() -- Visual options config.color_scheme = 's3r0 modified (terminal.sexy)' --- config.color_scheme = 'Mashup Colors (terminal.sexy)' config.font = wezterm.font 'Inconsolata Nerd Font Mono' config.font_size = 12 @@ -25,33 +25,33 @@ config.automatically_reload_config = true -- Linux specific fixes if wezterm.target_triple == 'x86_64-unknown-linux-gnu' then -- Fixing the cursor theme - local xcursor_size = nil - local xcursor_theme = nil - - local theme_success, stdout, _ = wezterm.run_child_process({ - "gsettings", - "get", - "org.gnome.desktop.interface", - "cursor-theme" - }) - - if theme_success then - xcursor_theme = stdout:gsub("'(.+)'\n", "%1") - end - - local cursor_success, _, _ = wezterm.run_child_process({ - "gsettings", - "get", - "org.gnome.desktop.interface", - "cursor-size" - }) - - if cursor_success then - xcursor_size = tonumber(stdout) - end - - config.xcursor_theme = xcursor_theme - config.xcursor_size = xcursor_size + -- local xcursor_size = nil + -- local xcursor_theme = nil + -- + -- local theme_success, stdout, _ = wezterm.run_child_process({ + -- "gsettings", + -- "get", + -- "org.gnome.desktop.interface", + -- "cursor-theme" + -- }) + -- + -- if theme_success then + -- xcursor_theme = stdout:gsub("'(.+)'\n", "%1") + -- end + -- + -- local cursor_success, _, _ = wezterm.run_child_process({ + -- "gsettings", + -- "get", + -- "org.gnome.desktop.interface", + -- "cursor-size" + -- }) + -- + -- if cursor_success then + -- xcursor_size = tonumber(stdout) + -- end + -- + -- config.xcursor_theme = xcursor_theme + -- config.xcursor_size = xcursor_size -- end cursor theme config.disable_default_key_bindings = true @@ -64,4 +64,9 @@ if local_config ~= nil then config = local_setup.setup(config) end +config.keys = { + {key = 'V', mods = 'CTRL', action = act.PasteFrom 'Clipboard'}, + {key = 'V', mods = 'CTRL', action = act.PasteFrom 'PrimarySelection'}, +} + return config From 0a4bf53aab8d4bc410e86a4edaa5c3fb58877b23 Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Fri, 31 Jul 2026 12:38:42 -0500 Subject: [PATCH 15/17] feat: Adding settings for git to use GPG signing --- README.md | 3 +++ gitconfig | 3 +++ zsh/zsh_exports | 1 + 3 files changed, 7 insertions(+) diff --git a/README.md b/README.md index 52e1055..427bf01 100644 --- a/README.md +++ b/README.md @@ -103,3 +103,6 @@ The config adds the following settings outside of oh-my-zsh: The gitconfig, centered on nvim integration, gives contains a selection of useful aliases and sets some basic defaults. It also includes a local override config hosted at `~/.config/git/local` for adding username and email as well as any other options needed for a local machine. + +> [!NOTE] +> For signing support put the `gpgsign` option in the local gitconfig diff --git a/gitconfig b/gitconfig index e6e2302..5b552ab 100644 --- a/gitconfig +++ b/gitconfig @@ -40,4 +40,7 @@ [include] path = ~/.config/git/local +[commit] + gpgsign = true + # vim: ft=gitconfig diff --git a/zsh/zsh_exports b/zsh/zsh_exports index 43a62cb..7ec34c8 100644 --- a/zsh/zsh_exports +++ b/zsh/zsh_exports @@ -1,3 +1,4 @@ export EDITOR=nvim export MANPAGER="less -R --use-color -Dd+r -Du+b" # Colored MAN pages export DOCKER_DEFAULT_PLATFORM=linux/amd64 +export GPG_TTY=$(tty) From 48235c005d81f61f77ba46d459ac89c9f4db7ee8 Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Thu, 6 Aug 2026 18:06:10 -0500 Subject: [PATCH 16/17] fix: moving the git signing settings to the local config, updating neovim to use the diagnostic.jump functions, and enabling the r_language_server LSP --- gitconfig | 3 --- nvim/after/ftplugin/r.lua | 1 + nvim/lua/plugins/language_support.lua | 5 +++-- nvim/lua/settings.lua | 1 - 4 files changed, 4 insertions(+), 6 deletions(-) create mode 100644 nvim/after/ftplugin/r.lua diff --git a/gitconfig b/gitconfig index 5b552ab..e6e2302 100644 --- a/gitconfig +++ b/gitconfig @@ -40,7 +40,4 @@ [include] path = ~/.config/git/local -[commit] - gpgsign = true - # vim: ft=gitconfig diff --git a/nvim/after/ftplugin/r.lua b/nvim/after/ftplugin/r.lua new file mode 100644 index 0000000..de73191 --- /dev/null +++ b/nvim/after/ftplugin/r.lua @@ -0,0 +1 @@ +vim.bo.shiftwidth=2 diff --git a/nvim/lua/plugins/language_support.lua b/nvim/lua/plugins/language_support.lua index 2f0c747..c577c33 100644 --- a/nvim/lua/plugins/language_support.lua +++ b/nvim/lua/plugins/language_support.lua @@ -57,8 +57,8 @@ vim.api.nvim_create_autocmd('LspAttach', { local bufnr = args.buf local bufopts = { noremap = true, silent = true, buffer = bufnr } - vim.keymap.set('n', '', vim.diagnostic.goto_prev, bufopts) - vim.keymap.set('n', '', vim.diagnostic.goto_next, bufopts) + vim.keymap.set('n', '', function() vim.diagnostic.jump({count=-1, float=true}) end, bufopts) + vim.keymap.set('n', '', function() vim.diagnostic.jump({count=1, float=true}) end, bufopts) vim.keymap.set('n', 'ga', vim.lsp.buf.code_action, bufopts) vim.keymap.set('n', 'gD', vim.lsp.buf.declaration, bufopts) vim.keymap.set('n', 'gd', vim.lsp.buf.definition, bufopts) @@ -76,3 +76,4 @@ vim.api.nvim_create_autocmd('LspAttach', { -- Enable LSP engines -- vim.lsp.enable('clangd') vim.lsp.enable('gdscript') +vim.lsp.enable('r_language_server') diff --git a/nvim/lua/settings.lua b/nvim/lua/settings.lua index 03ef825..c4e20ca 100644 --- a/nvim/lua/settings.lua +++ b/nvim/lua/settings.lua @@ -11,7 +11,6 @@ vim.opt.fileformat = 'unix' -- Explicitly s vim.opt.fillchars = 'fold: ' -- Sets the character that fills in a fold line (removes the dots) vim.opt.foldcolumn = '0' -- Disables the foldcolumn vim.opt.foldexpr = 'v:lua.vim.treesitter.foldexpr()' -- Uses Treesitter to determine where code folding should occur -vim.opt.foldlevel = 10 -- Sets the initial level at which folds will be closed vim.opt.foldlevelstart = 4 -- Sets the initial fold level vim.opt.foldmethod = 'expr' -- Attempt to use the syntax of a file to set folds. vim.opt.foldnestmax = 4 -- Maximum level of fold nesting From 6e035d1f4c5b7a813699866bb445a18d4e93ee5a Mon Sep 17 00:00:00 2001 From: FaultyBranches Date: Wed, 12 Aug 2026 09:46:56 -0500 Subject: [PATCH 17/17] fix: Cleaning up some aspects of the language support work to move into development and finish cleaning the main branch. --- nvim/after/lsp/arduino_language_server.lua | 9 --- nvim/after/lsp/bashls.lua | 9 ++- nvim/after/lsp/clangd.lua | 91 ++++++++++++++++++++++ nvim/after/lsp/gdscript.lua | 2 +- nvim/after/lsp/jinja-lsp.lua | 3 - nvim/after/lsp/jinja_lsp.lua | 15 ++++ nvim/after/lsp/pylsp.lua | 10 +++ nvim/lua/plugins.lua | 1 - nvim/lua/plugins/language_support.lua | 22 ++++-- wezterm/wezterm.lua | 30 ------- 10 files changed, 139 insertions(+), 53 deletions(-) delete mode 100644 nvim/after/lsp/arduino_language_server.lua create mode 100644 nvim/after/lsp/clangd.lua delete mode 100644 nvim/after/lsp/jinja-lsp.lua create mode 100644 nvim/after/lsp/jinja_lsp.lua diff --git a/nvim/after/lsp/arduino_language_server.lua b/nvim/after/lsp/arduino_language_server.lua deleted file mode 100644 index 321d14d..0000000 --- a/nvim/after/lsp/arduino_language_server.lua +++ /dev/null @@ -1,9 +0,0 @@ -return { - cmd = { - "arduino-language-server", - "-clangd", "/usr/lib/llvm/21/bin/clangd", - "-cli", "/usr/bin/arduino-cli", - "-cli-config", "~/.arduino15/arduino-cli.yaml", - "-fqbn", "esp32:esp32:adafruit_qtpy_esp32s3_nopsram" - } -} diff --git a/nvim/after/lsp/bashls.lua b/nvim/after/lsp/bashls.lua index c554369..04af992 100644 --- a/nvim/after/lsp/bashls.lua +++ b/nvim/after/lsp/bashls.lua @@ -1,3 +1,10 @@ return { - filetypes = { 'zsh', 'bash', 'sh' } + cmd = { 'bash-language-server', 'start' }, + settings = { + bashIde = { + globPattern = vim.env.GLOB_PATTERN or '*@(.sh|.inc|.bash|.command)', + }, + }, + filetypes = { 'zsh', 'bash', 'sh' }, + root_markers = { '.git' }, } diff --git a/nvim/after/lsp/clangd.lua b/nvim/after/lsp/clangd.lua new file mode 100644 index 0000000..596d811 --- /dev/null +++ b/nvim/after/lsp/clangd.lua @@ -0,0 +1,91 @@ +-- https://clangd.llvm.org/extensions.html#switch-between-sourceheader +local function switch_source_header(bufnr, client) + local method_name = 'textDocument/switchSourceHeader' + ---@diagnostic disable-next-line:param-type-mismatch + if not client or not client:supports_method(method_name) then + return vim.notify(('method %s is not supported by any servers active on the current buffer'):format(method_name)) + end + local params = vim.lsp.util.make_text_document_params(bufnr) + ---@diagnostic disable-next-line:param-type-mismatch + client:request(method_name, params, function(err, result) + if err then + error(tostring(err)) + end + if not result then + vim.notify('corresponding file cannot be determined') + return + end + vim.cmd.edit(vim.uri_to_fname(result)) + end, bufnr) +end + +local function symbol_info(bufnr, client) + local method_name = 'textDocument/symbolInfo' + ---@diagnostic disable-next-line:param-type-mismatch + if not client or not client:supports_method(method_name) then + return vim.notify('Clangd client not found', vim.log.levels.ERROR) + end + local win = vim.api.nvim_get_current_win() + local params = vim.lsp.util.make_position_params(win, client.offset_encoding) + ---@diagnostic disable-next-line:param-type-mismatch + client:request(method_name, params, function(err, res) + if err or #res == 0 then + -- Clangd always returns an error, there is no reason to parse it + return + end + local container = string.format('container: %s', res[1].containerName) ---@type string + local name = string.format('name: %s', res[1].name) ---@type string + vim.lsp.util.open_floating_preview({ name, container }, '', { + height = 2, + width = math.max(string.len(name), string.len(container)), + focusable = false, + focus = false, + title = 'Symbol Info', + }) + end, bufnr) +end + +---@class ClangdInitializeResult: lsp.InitializeResult +---@field offsetEncoding? string + +---@type vim.lsp.Config +return { + cmd = { 'clangd' }, + filetypes = { 'c', 'c.doxygen', 'cpp', 'cpp.doxygen', 'objc', 'objcpp', 'cuda' }, + root_markers = { + '.clangd', + '.clang-tidy', + '.clang-format', + 'compile_commands.json', + 'compile_flags.txt', + 'configure.ac', -- AutoTools + '.git', + }, + get_language_id = function(_, ftype) + local t = { objc = 'objective-c', objcpp = 'objective-cpp', cuda = 'cuda-cpp' } + return t[ftype] or ftype + end, + capabilities = { + textDocument = { + completion = { + editsNearCursor = true, + }, + }, + offsetEncoding = { 'utf-8', 'utf-16' }, + }, + ---@param init_result ClangdInitializeResult + on_init = function(client, init_result) + if init_result.offsetEncoding then + client.offset_encoding = init_result.offsetEncoding + end + end, + on_attach = function(client, bufnr) + vim.api.nvim_buf_create_user_command(bufnr, 'LspClangdSwitchSourceHeader', function() + switch_source_header(bufnr, client) + end, { desc = 'Switch between source/header' }) + + vim.api.nvim_buf_create_user_command(bufnr, 'LspClangdShowSymbolInfo', function() + symbol_info(bufnr, client) + end, { desc = 'Show symbol info' }) + end, +} diff --git a/nvim/after/lsp/gdscript.lua b/nvim/after/lsp/gdscript.lua index ccef542..2ddeef7 100644 --- a/nvim/after/lsp/gdscript.lua +++ b/nvim/after/lsp/gdscript.lua @@ -1,7 +1,7 @@ return { + cmd = vim.lsp.rpc.connect('127.0.0.1', 6005), filetypes = { 'gd', 'gdscript', 'gdscript3' }, root_markers = { 'project.godot', '.git' }, - cmd = vim.lsp.rpc.connect('127.0.0.1', 6005) } diff --git a/nvim/after/lsp/jinja-lsp.lua b/nvim/after/lsp/jinja-lsp.lua deleted file mode 100644 index ddb6bb1..0000000 --- a/nvim/after/lsp/jinja-lsp.lua +++ /dev/null @@ -1,3 +0,0 @@ -return { - template_extension = { 'html', 'jinja', 'j2', 'tera' } -} diff --git a/nvim/after/lsp/jinja_lsp.lua b/nvim/after/lsp/jinja_lsp.lua new file mode 100644 index 0000000..90dcd96 --- /dev/null +++ b/nvim/after/lsp/jinja_lsp.lua @@ -0,0 +1,15 @@ +vim.filetype.add { + extension = { + -- tera = 'jinja', + jinja = 'jinja', + jinja2 = 'jinja', + j2 = 'jinja', + } +} + +return { + name = 'jinja_lsp', + cmd = { 'jinja-lsp' }, + filetypes = { 'jinja', 'tera', 'html' }, + -- template_extension = { 'html', 'jinja', 'j2', 'tera' }, +} diff --git a/nvim/after/lsp/pylsp.lua b/nvim/after/lsp/pylsp.lua index 335d2f1..78a0e90 100644 --- a/nvim/after/lsp/pylsp.lua +++ b/nvim/after/lsp/pylsp.lua @@ -1,4 +1,14 @@ return { + cmd = { 'pylsp' }, + filetypes = { 'python' }, + root_markers = { + 'pyproject.toml', + 'setup.py', + 'setup.cfg', + 'requirements.txt', + 'Pipfile', + '.git', + }, settings = { pylsp = { plugins = { diff --git a/nvim/lua/plugins.lua b/nvim/lua/plugins.lua index 8484d25..448f847 100644 --- a/nvim/lua/plugins.lua +++ b/nvim/lua/plugins.lua @@ -28,5 +28,4 @@ vim.schedule(function() -- Experimental -- require('plugins.note_taking') -- In house note taking plugin (TODO: rename once the plugin name is solidified) - -- require('plugins.nvim-lint') -- Linter loader end) diff --git a/nvim/lua/plugins/language_support.lua b/nvim/lua/plugins/language_support.lua index c577c33..42b68f2 100644 --- a/nvim/lua/plugins/language_support.lua +++ b/nvim/lua/plugins/language_support.lua @@ -9,7 +9,6 @@ end -- Start treesitter parsing on the current buffer vim.api.nvim_create_autocmd("FileType", { callback = function(ev) - -- Use pcall to prevent blocking errors pcall(vim.treesitter.start, ev.buf) end }) @@ -53,12 +52,11 @@ vim.api.nvim_create_autocmd('LspAttach', { -- end, -- }) - -- Keyboard Mappings local bufnr = args.buf - local bufopts = { noremap = true, silent = true, buffer = bufnr } - vim.keymap.set('n', '', function() vim.diagnostic.jump({count=-1, float=true}) end, bufopts) - vim.keymap.set('n', '', function() vim.diagnostic.jump({count=1, float=true}) end, bufopts) + + vim.keymap.set('n', '', function() vim.diagnostic.jump({ count = -1, float = true }) end, bufopts) + vim.keymap.set('n', '', function() vim.diagnostic.jump({ count = 1, float = true }) end, bufopts) vim.keymap.set('n', 'ga', vim.lsp.buf.code_action, bufopts) vim.keymap.set('n', 'gD', vim.lsp.buf.declaration, bufopts) vim.keymap.set('n', 'gd', vim.lsp.buf.definition, bufopts) @@ -74,6 +72,14 @@ vim.api.nvim_create_autocmd('LspAttach', { }) -- Enable LSP engines --- vim.lsp.enable('clangd') -vim.lsp.enable('gdscript') -vim.lsp.enable('r_language_server') +local enabled_lsps = { + 'clangd', + 'gdscript', + 'jinja_lsp', + 'pylsp', + 'r_language_server', +} + +for _, lsp in pairs(enabled_lsps) do + vim.lsp.enable(lsp) +end diff --git a/wezterm/wezterm.lua b/wezterm/wezterm.lua index 605559e..a60937d 100644 --- a/wezterm/wezterm.lua +++ b/wezterm/wezterm.lua @@ -24,36 +24,6 @@ config.automatically_reload_config = true -- Linux specific fixes if wezterm.target_triple == 'x86_64-unknown-linux-gnu' then - -- Fixing the cursor theme - -- local xcursor_size = nil - -- local xcursor_theme = nil - -- - -- local theme_success, stdout, _ = wezterm.run_child_process({ - -- "gsettings", - -- "get", - -- "org.gnome.desktop.interface", - -- "cursor-theme" - -- }) - -- - -- if theme_success then - -- xcursor_theme = stdout:gsub("'(.+)'\n", "%1") - -- end - -- - -- local cursor_success, _, _ = wezterm.run_child_process({ - -- "gsettings", - -- "get", - -- "org.gnome.desktop.interface", - -- "cursor-size" - -- }) - -- - -- if cursor_success then - -- xcursor_size = tonumber(stdout) - -- end - -- - -- config.xcursor_theme = xcursor_theme - -- config.xcursor_size = xcursor_size - -- end cursor theme - config.disable_default_key_bindings = true end