From 3ff6d828befc66167d4df685de22eaca612a40e5 Mon Sep 17 00:00:00 2001 From: cmccay Date: Fri, 2 Dec 2022 13:54:41 -0600 Subject: [PATCH] lots more stuff --- alacritty/.config/alacritty/alacritty.yml | 2 +- nvim/.config/nvim/init.lua | 28 ++++++++ nvim/.config/nvim/lua/colorscheme.lua | 6 +- nvim/.config/nvim/lua/keybindings.lua | 16 +++++ nvim/.config/nvim/lua/plugins.lua | 64 +++++++++++------ nvim/.config/nvim/plugin/packer_compiled.lua | 75 +++++++++++++------- tmux/.config/tmux/statusline.conf | 2 +- 7 files changed, 142 insertions(+), 51 deletions(-) diff --git a/alacritty/.config/alacritty/alacritty.yml b/alacritty/.config/alacritty/alacritty.yml index d2a8348..9d1f388 100644 --- a/alacritty/.config/alacritty/alacritty.yml +++ b/alacritty/.config/alacritty/alacritty.yml @@ -1,5 +1,5 @@ window: - opacity: 0.8 + opacity: 0.95 font: size: 14 diff --git a/nvim/.config/nvim/init.lua b/nvim/.config/nvim/init.lua index 3aaa95f..df4020e 100644 --- a/nvim/.config/nvim/init.lua +++ b/nvim/.config/nvim/init.lua @@ -18,3 +18,31 @@ require("telescope").setup{ require("telescope").load_extension("fzf") require("telescope").load_extension("file_browser") +require("telescope").load_extension("neoclip") +require('Comment').setup() +require('nvim-treesitter').setup({ + -- enable syntax highlighting + highlight = { + enable = true, + }, + -- enable indentation + indent = { enable = true }, + -- enable autotagging (w/ nvim-ts-autotag plugin) + autotag = { enable = true }, + -- ensure these language parsers are installed + ensure_installed = { + "json", + "yaml", + "html", + "css", + "markdown", + "bash", + "lua", + "vim", + "dockerfile", + "gitignore", + "python", + }, + -- auto install above language parsers + auto_install = true, +}) diff --git a/nvim/.config/nvim/lua/colorscheme.lua b/nvim/.config/nvim/lua/colorscheme.lua index 6a89d7f..0d62ada 100644 --- a/nvim/.config/nvim/lua/colorscheme.lua +++ b/nvim/.config/nvim/lua/colorscheme.lua @@ -2,9 +2,11 @@ -- vim.cmd("colorscheme ayu") -- vim.cmd("let ayucolor='mirage'") -- vim.cmd("colorscheme gruvbox") --- vim.cmd("colorscheme tender") +vim.cmd("colorscheme tender") -- vim.cmd("colorscheme railscasts") -- vim.cmd("colorscheme desert-warm-256") -vim.cmd("colorscheme deus") +-- vim.cmd("colorscheme deus") + +-- Ignore background color for transparency vim.cmd("highlight Normal ctermbg=none") vim.cmd("highlight NonText ctermbg=none") diff --git a/nvim/.config/nvim/lua/keybindings.lua b/nvim/.config/nvim/lua/keybindings.lua index d1dee0d..c426010 100644 --- a/nvim/.config/nvim/lua/keybindings.lua +++ b/nvim/.config/nvim/lua/keybindings.lua @@ -5,6 +5,18 @@ local keymap = vim.api.nvim_set_keymap local default_ops = { noremap = true, silent = true } +-- Quick escape insert mode +keymap('i', 'jk', '', default_ops) + +-- Delete single character without copying into register +keymap("n", "x", '"_x', default_ops) + +-- Window management +keymap("n", "sv", "v", default_ops) +keymap("n", "sh", "s", default_ops) +keymap("n", "se", "=", default_ops) +keymap("n", "sx", ":close", default_ops) + -- Save, Save/Quit keymap('n', '', ':w', default_ops) keymap('n', '', ':wq', default_ops) @@ -29,3 +41,7 @@ keymap('n', 'ff', ':Telescope find_files hidden=true', default_ops) keymap('n', 'gf', ':Telescope git_files', default_ops) keymap('n', 'lg', ':Telescope live_grep', default_ops) keymap('n', 'd', ':Telescope diagnostics', default_ops) +keymap('n', 'h', ':Telescope neoclip', default_ops) + +-- Buffers +keymap('n', 'b', ':JABSOpen', default_ops) diff --git a/nvim/.config/nvim/lua/plugins.lua b/nvim/.config/nvim/lua/plugins.lua index 1f0997d..6329fb3 100644 --- a/nvim/.config/nvim/lua/plugins.lua +++ b/nvim/.config/nvim/lua/plugins.lua @@ -6,6 +6,12 @@ return require('packer').startup(function(use) -- LSP use('neovim/nvim-lspconfig') + use('hrsh7th/cmp-nvim-lsp') + use('hrsh7th/cmp-nvim-lua') + use('hrsh7th/cmp-buffer') + use('hrsh7th/cmp-path') + use('hrsh7th/nvim-cmp') + use('saadparwaiz1/cmp_luasnip') -- colorschemes use('ayu-theme/ayu-vim') @@ -30,37 +36,51 @@ return require('packer').startup(function(use) -- SuperTab use('ervandew/supertab') - - -- Auto-Complete --- use('ncm2/ncm2') --- use('roxma/nvim-yarp') --- -- enable ncm2 for all buffers --- -- autocmd BufEnter * call ncm2#enable_for_buffer() --- -- IMPORTANT: :help Ncm2PopupOpen for more information --- -- set completeopt=noinsert,menuone,noselect --- use('ncm2/ncm2-bufword') -- Basic completion --- use('ncm2/ncm2-path') -- Path completion --- use('ncm2/ncm2-jedi') -- Python completion - -- better auto complete maybe - use('hrsh7th/cmp-nvim-lsp') - use('hrsh7th/cmp-nvim-lua') - use('hrsh7th/cmp-buffer') - use('hrsh7th/cmp-path') - use('hrsh7th/nvim-cmp') - use('saadparwaiz1/cmp_luasnip') - -- Slime, for tmux repl-ing + -- Vim-surround + use('tpope/vim-surround') + + -- Slime, for tmux repl-ing use('jpalardy/vim-slime') -- Telescope, fuzzy finding use('nvim-lua/plenary.nvim') use('nvim-telescope/telescope.nvim') - use {'nvim-telescope/telescope-fzf-native.nvim', run = 'make' } + use{'nvim-telescope/telescope-fzf-native.nvim', run = 'make' } use( "nvim-telescope/telescope-file-browser.nvim") -- Treesitter - -- use('nvim-treesitter/nvim-treesitter') + use{'nvim-treesitter/nvim-treesitter', run = ':TSUpdate' } -- Devicons use('kyazdani42/nvim-web-devicons') -end) + + -- Registry history + use { + "AckslD/nvim-neoclip.lua", + requires = { + {'kkharji/sqlite.lua', module = 'sqlite'}, + {'nvim-telescope/telescope.nvim'}, + }, + config = function() + require('neoclip').setup({ + enable_persistent_history = true, + continuous_sync = true + } + ) + end, + } + + -- Buffers + use('matbme/JABS.nvim') + require("jabs").setup {} + + -- Comments + use { + 'numToStr/Comment.nvim', + config = function() + require('Comment').setup() + end +} + + end) diff --git a/nvim/.config/nvim/plugin/packer_compiled.lua b/nvim/.config/nvim/plugin/packer_compiled.lua index 4e107fa..475005f 100644 --- a/nvim/.config/nvim/plugin/packer_compiled.lua +++ b/nvim/.config/nvim/plugin/packer_compiled.lua @@ -79,6 +79,31 @@ _G.packer_plugins = { path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/ayu-vim", url = "https://github.com/ayu-theme/ayu-vim" }, + ["cmp-buffer"] = { + loaded = true, + path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/cmp-buffer", + url = "https://github.com/hrsh7th/cmp-buffer" + }, + ["cmp-nvim-lsp"] = { + loaded = true, + path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/cmp-nvim-lsp", + url = "https://github.com/hrsh7th/cmp-nvim-lsp" + }, + ["cmp-nvim-lua"] = { + loaded = true, + path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/cmp-nvim-lua", + url = "https://github.com/hrsh7th/cmp-nvim-lua" + }, + ["cmp-path"] = { + loaded = true, + path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/cmp-path", + url = "https://github.com/hrsh7th/cmp-path" + }, + cmp_luasnip = { + loaded = true, + path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/cmp_luasnip", + url = "https://github.com/saadparwaiz1/cmp_luasnip" + }, gruvbox = { loaded = true, path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/gruvbox", @@ -89,26 +114,6 @@ _G.packer_plugins = { path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/minimalist", url = "https://github.com/dikiaap/minimalist" }, - ncm2 = { - loaded = true, - path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/ncm2", - url = "https://github.com/ncm2/ncm2" - }, - ["ncm2-bufword"] = { - loaded = true, - path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/ncm2-bufword", - url = "https://github.com/ncm2/ncm2-bufword" - }, - ["ncm2-jedi"] = { - loaded = true, - path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/ncm2-jedi", - url = "https://github.com/ncm2/ncm2-jedi" - }, - ["ncm2-path"] = { - loaded = true, - path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/ncm2-path", - url = "https://github.com/ncm2/ncm2-path" - }, nerdtree = { loaded = true, path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/nerdtree", @@ -119,21 +124,27 @@ _G.packer_plugins = { path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/nerdtree-git-plugin", url = "https://github.com/Xuyuanp/nerdtree-git-plugin" }, + ["nvim-cmp"] = { + loaded = true, + path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/nvim-cmp", + url = "https://github.com/hrsh7th/nvim-cmp" + }, ["nvim-lspconfig"] = { loaded = true, path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/nvim-lspconfig", url = "https://github.com/neovim/nvim-lspconfig" }, + ["nvim-neoclip.lua"] = { + config = { "\27LJ\2\n5\0\0\3\0\3\0\0066\0\0\0'\2\1\0B\0\2\0029\0\2\0B\0\1\1K\0\1\0\nsetup\fneoclip\frequire\0" }, + loaded = true, + path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/nvim-neoclip.lua", + url = "https://github.com/AckslD/nvim-neoclip.lua" + }, ["nvim-web-devicons"] = { loaded = true, path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/nvim-web-devicons", url = "https://github.com/kyazdani42/nvim-web-devicons" }, - ["nvim-yarp"] = { - loaded = true, - path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/nvim-yarp", - url = "https://github.com/roxma/nvim-yarp" - }, ["packer.nvim"] = { loaded = true, path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/packer.nvim", @@ -174,6 +185,11 @@ _G.packer_plugins = { path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/vim-airline", url = "https://github.com/vim-airline/vim-airline" }, + ["vim-airline-themes"] = { + loaded = true, + path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/vim-airline-themes", + url = "https://github.com/vim-airline/vim-airline-themes" + }, ["vim-desert-warm-256"] = { loaded = true, path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/vim-desert-warm-256", @@ -189,6 +205,11 @@ _G.packer_plugins = { path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/vim-devicons", url = "https://github.com/ryanoasis/vim-devicons" }, + ["vim-fugitive"] = { + loaded = true, + path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/vim-fugitive", + url = "https://github.com/tpope/vim-fugitive" + }, ["vim-railscasts-theme"] = { loaded = true, path = "/Users/clintmccay/.local/share/nvim/site/pack/packer/start/vim-railscasts-theme", @@ -202,6 +223,10 @@ _G.packer_plugins = { } time([[Defining packer_plugins]], false) +-- Config for: nvim-neoclip.lua +time([[Config for nvim-neoclip.lua]], true) +try_loadstring("\27LJ\2\n5\0\0\3\0\3\0\0066\0\0\0'\2\1\0B\0\2\0029\0\2\0B\0\1\1K\0\1\0\nsetup\fneoclip\frequire\0", "config", "nvim-neoclip.lua") +time([[Config for nvim-neoclip.lua]], false) _G._packer.inside_compile = false if _G._packer.needs_bufread == true then diff --git a/tmux/.config/tmux/statusline.conf b/tmux/.config/tmux/statusline.conf index 66d457b..03acf66 100644 --- a/tmux/.config/tmux/statusline.conf +++ b/tmux/.config/tmux/statusline.conf @@ -3,7 +3,7 @@ set -g default-terminal "screen-256color" # left status -set-window-option -g status-left " (( #S )) " +set-window-option -g status-left " [ #S ] " set-window-option -g status-left-style "fg=blue bg=black" set-window-option -g status-left-length 30