Added tmux; Updated Neo-Tree configs

This commit is contained in:
mattr
2024-10-02 18:44:02 -05:00
parent 53985af163
commit 922fdb0cba
7 changed files with 181 additions and 44 deletions

View File

@@ -55,6 +55,10 @@ vim.opt.inccommand = 'split'
-- Show which line your cursor is on
vim.opt.cursorline = true
-- Tabulation Stuffs
vim.opt.shiftwidth = 4
vim.opt.expandtab = true
-- Minimal number of screen lines to keep above and below the cursor.
vim.opt.scrolloff = 10
@@ -110,7 +114,7 @@ vim.opt.rtp:prepend(lazypath)
-- [[ Configure and install plugins ]]
require('lazy').setup({
'tpope/vim-sleuth', -- Detect tabstop and shiftwidth automatically
'tpope/vim-sleuth', -- Detect tabstop and shiftwidth automatically
-- See `:help gitsigns` to understand what the configuration keys do
{ -- Adds git related signs to the gutter, as well as utilities for managing changes
@@ -500,12 +504,16 @@ require('lazy').setup({
local cmp = require 'cmp'
local luasnip = require 'luasnip'
luasnip.config.setup {}
cmp.setup {
snippet = {
expand = function(args)
luasnip.lsp_expand(args.body)
end,
window = {
documentation = cmp.config.window.bordered({
winhighlight = "Normal:Pmenu,FloatBorder:Pmenu,CursorLine:PmenuSel,Search:None",
}),
},
},
completion = { completeopt = 'menu,menuone,noinsert' },
@@ -668,12 +676,31 @@ require('lazy').setup({
-- require 'kickstart.plugins.debug',
-- require 'kickstart.plugins.indent_line',
-- require 'kickstart.plugins.lint',
-- require 'kickstart.plugins.autopairs',
require 'plugins.autopairs',
require 'plugins.neo-tree',
require 'plugins.gitsigns', -- adds gitsigns recommend keymaps
require 'plugins.barbar',
require 'plugins.terminal',
require 'plugins.commander',
require 'plugins.venn',
{
"lukas-reineke/indent-blankline.nvim",
main = "ibl",
---@module "ibl"
---@type ibl.config
opts = {},
},
{
'VonHeikemen/fine-cmdline.nvim',
dependencies = {
{'MunifTanjim/nui.nvim'}
},
cmdline = {
smart_history = true
},
config = function()
vim.api.nvim_set_keymap('n', ':', '<cmd>FineCmdline<CR>', {noremap = true})
end
},
}, {
ui = {
-- If you are using a Nerd Font: set icons to an empty table which will use the
@@ -696,5 +723,5 @@ require('lazy').setup({
},
})
-- The line beneath this is called `modeline`. See `:help modeline`
--The line beneath this is called `modeline`. See `:help modeline`
-- vim: ts=2 sts=2 sw=2 et

View File

@@ -1,11 +1,14 @@
{
"FTerm.nvim": { "branch": "master", "commit": "d1320892cc2ebab472935242d9d992a2c9570180" },
"LuaSnip": { "branch": "master", "commit": "e808bee352d1a6fcf902ca1a71cee76e60e24071" },
"barbar.nvim": { "branch": "master", "commit": "53b5a2f34b68875898f0531032fbf090e3952ad7" },
"cmp-nvim-lsp": { "branch": "main", "commit": "39e2eda76828d88b773cc27a3f61d2ad782c922d" },
"cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" },
"cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" },
"conform.nvim": { "branch": "master", "commit": "1a99fdc1d3aa9ccdf3021e67982a679a8c5c740c" },
"fidget.nvim": { "branch": "main", "commit": "d855eed8a06531a7e8fd0684889b2943f373c469" },
"fine-cmdline.nvim": { "branch": "main", "commit": "aec9efebf6f4606a5204d49ffa3ce2eeb7e08a3e" },
"gitsigns.nvim": { "branch": "main", "commit": "863903631e676b33e8be2acb17512fdc1b80b4fb" },
"indent-blankline.nvim": { "branch": "master", "commit": "18603eb949eba08300799f64027af11ef922283f" },
"lazy.nvim": { "branch": "main", "commit": "077102c5bfc578693f12377846d427f49bc50076" },
"lazydev.nvim": { "branch": "main", "commit": "491452cf1ca6f029e90ad0d0368848fac717c6d2" },
"luvit-meta": { "branch": "main", "commit": "ce76f6f6cdc9201523a5875a4471dcfe0186eb60" },
@@ -13,16 +16,20 @@
"mason-tool-installer.nvim": { "branch": "main", "commit": "c5e07b8ff54187716334d585db34282e46fa2932" },
"mason.nvim": { "branch": "main", "commit": "e2f7f9044ec30067bc11800a9e266664b88cda22" },
"mini.nvim": { "branch": "main", "commit": "848c5e8f428faf843051768e0d56104cd02aea1f" },
"neo-tree.nvim": { "branch": "main", "commit": "a77af2e764c5ed4038d27d1c463fa49cd4794e07" },
"nui.nvim": { "branch": "main", "commit": "b58e2bfda5cea347c9d58b7f11cf3012c7b3953f" },
"nvim-autopairs": { "branch": "master", "commit": "ee297f215e95a60b01fde33275cc3c820eddeebe" },
"nvim-cmp": { "branch": "main", "commit": "ae644feb7b67bf1ce4260c231d1d4300b19c6f30" },
"nvim-lspconfig": { "branch": "master", "commit": "0678aa439b82965daf03679cd146e84f10e299c3" },
"nvim-treesitter": { "branch": "master", "commit": "707e352df6d737e545e1a7204f7395ba82e6d2d3" },
"nvim-lspconfig": { "branch": "master", "commit": "38cd54b7063c4c45fb37c73ebfbd776939d0cfde" },
"nvim-treesitter": { "branch": "master", "commit": "98a33cc524c85a78a1ff5a707998629b24cbf8c2" },
"nvim-web-devicons": { "branch": "master", "commit": "6b53401918a9033a41159d012160c5fb5eb249ae" },
"plenary.nvim": { "branch": "master", "commit": "2d9b06177a975543726ce5c73fca176cedbffe9d" },
"telescope-fzf-native.nvim": { "branch": "main", "commit": "cf48d4dfce44e0b9a2e19a008d6ec6ea6f01a83b" },
"telescope-ui-select.nvim": { "branch": "master", "commit": "6e51d7da30bd139a6950adf2a47fda6df9fa06d2" },
"telescope.nvim": { "branch": "0.1.x", "commit": "a0bbec21143c7bc5f8bb02e0005fa0b982edc026" },
"todo-comments.nvim": { "branch": "main", "commit": "ae0a2afb47cf7395dc400e5dc4e05274bf4fb9e0" },
"tokyonight.nvim": { "branch": "main", "commit": "817bb6ffff1b9ce72cdd45d9fcfa8c9cd1ad3839" },
"tokyonight.nvim": { "branch": "main", "commit": "efd1417aa01af618426fe1cf507c5458090458f2" },
"venn.nvim": { "branch": "main", "commit": "b09c2f36ddf70b498281845109bedcf08a7e0de0" },
"vim-sleuth": { "branch": "master", "commit": "be69bff86754b1aa5adcbb527d7fcd1635a84080" },
"which-key.nvim": { "branch": "main", "commit": "fb070344402cfc662299d9914f5546d840a22126" }
"which-key.nvim": { "branch": "main", "commit": "8badb359f7ab8711e2575ef75dfe6fbbd87e4821" }
}

View File

@@ -1,34 +0,0 @@
return {
"FeiyouG/commander.nvim",
dependencies = {
"nvim-telescope/telescope.nvim",
},
keys = {
-- { "<leader>fv", "<CMD>Telescope commander<CR>", mode = "n" },
{ "<leader>fc", "<CMD>Telescope commander<CR>", mode = "n" }
},
config = function()
require("commander").setup({
components = {
"DESC",
"KEYS",
"CAT",
},
sort_by = {
"DESC",
"KEYS",
"CAT",
"CMD"
},
integration = {
telescope = {
enable = true,
},
lazy = {
enable = true,
set_plugin_name_as_cat = true
}
}
})
end,
}

View File

@@ -17,6 +17,14 @@ return {
keys = {
{ '<leader>e', ':Neotree reveal action=focus toggle=true<CR>', silent=true }
},
init = function()
if vim.fn.argc(-1) == 1 then
local stat = vim.loop.fs_stat(vim.fn.argv(0))
if stat and stat.type == "directory" then
require("neo-tree")
end
end
end,
opts = {
filesystem = {
window = {

27
nvim/lua/plugins/venn.lua Normal file
View File

@@ -0,0 +1,27 @@
function _G.Toggle_venn()
local venn_enabled = vim.inspect(vim.b.venn_enabled)
if venn_enabled == "nil" then
vim.b.venn_enabled = true
vim.cmd[[setlocal ve=all]]
-- draw a line on HJKL keystokes
vim.api.nvim_buf_set_keymap(0, "n", "J", "<C-v>j:VBox<CR>", {noremap = true})
vim.api.nvim_buf_set_keymap(0, "n", "K", "<C-v>k:VBox<CR>", {noremap = true})
vim.api.nvim_buf_set_keymap(0, "n", "L", "<C-v>l:VBox<CR>", {noremap = true})
vim.api.nvim_buf_set_keymap(0, "n", "H", "<C-v>h:VBox<CR>", {noremap = true})
-- draw a box by pressing "f" with visual selection
vim.api.nvim_buf_set_keymap(0, "v", "f", ":VBox<CR>", {noremap = true})
else
vim.cmd[[setlocal ve=]]
vim.api.nvim_buf_del_keymap(0, "n", "J")
vim.api.nvim_buf_del_keymap(0, "n", "K")
vim.api.nvim_buf_del_keymap(0, "n", "L")
vim.api.nvim_buf_del_keymap(0, "n", "H")
vim.api.nvim_buf_del_keymap(0, "v", "f")
vim.b.venn_enabled = nil
end
end
-- toggle keymappings for venn using <leader>v
vim.api.nvim_set_keymap('n', '<leader>v', ":lua Toggle_venn()<CR>", { noremap = true, desc="Enable Venn Diagram Drawing"})
return {'jbyuki/venn.nvim'}

98
tmux/tmux.conf Normal file
View File

@@ -0,0 +1,98 @@
set-option -sa terminal-overrides ",xterm*:Tc"
set -g mouse on
set -sg escape-time 10
unbind C-b
set -g prefix C-Space
bind C-Space send-prefix
# Vim style pane selection
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# Start windows and panes at 1, not 0
set -g base-index 1
set -g pane-base-index 1
set-window-option -g pane-base-index 1
set-option -g renumber-windows on
# Use Alt-arrow keys without prefix key to switch panes
bind -n M-Left select-pane -L
bind -n M-Right select-pane -R
bind -n M-Up select-pane -U
bind -n M-Down select-pane -D
# Shift arrow to switch windows
bind -n S-Left previous-window
bind -n S-Right next-window
# Shift Alt vim keys to switch windows
bind -n M-H previous-window
bind -n M-L next-window
set -g @catppuccin_flavour 'mocha'
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'christoomey/vim-tmux-navigator'
set -g @plugin 'dreamsofcode-io/catppuccin-tmux'
set -g @plugin 'tmux-plugins/tmux-yank'
run '~/.tmux/plugins/tpm/tpm'
# set vi-mode
set-window-option -g mode-keys vi
# keybindings
bind-key -T copy-mode-vi v send-keys -X begin-selection
bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle
bind-key -T copy-mode-vi y send-keys -X copy-selection-and-cancel
bind '"' split-window -v -c "#{pane_current_path}"
bind % split-window -h -c "#{pane_current_path}"
# DESIGN TWEAKS
# don't do anything when a 'bell' rings
set -g visual-activity off
set -g visual-bell off
set -g visual-silence off
setw -g monitor-activity off
set -g bell-action none
# clock mode
setw -g clock-mode-colour yellow
# copy mode
setw -g mode-style 'fg=black bg=red bold'
# panes
set -g pane-border-style 'fg=red'
set -g pane-active-border-style 'fg=yellow'
# statusbar
set -g status-position bottom
set -g status-justify left
set -g status-style 'fg=red'
set -g status-left ''
set -g status-left-length 10
set -g status-right-style 'fg=black bg=yellow'
set -g status-right '%Y-%m-%d %H:%M '
set -g status-right-length 50
setw -g window-status-current-style 'fg=black bg=red'
setw -g window-status-current-format ' #I #W #F '
setw -g window-status-style 'fg=red bg=black'
setw -g window-status-format ' #I #[fg=white]#W #[fg=yellow]#F '
setw -g window-status-bell-style 'fg=yellow bg=red bold'
# messages
set -g message-style 'fg=yellow bg=red bold'

View File

@@ -191,6 +191,7 @@ alias ll='eza -lh'
alias py='python3'
# Gui Interaction
alias open='xdg-open'
# xclip is for x11
@@ -199,6 +200,9 @@ alias v='wl-paste'
alias codium='flatpak run com.vscodium.codium'
# Tmux Aliases
alias tclasses='tmux attach -t classes'
###############################################################################
# Custom Functions