From f270a4cfc8fa9c0be06ac92e01254bc7d936a05d Mon Sep 17 00:00:00 2001 From: PowerUser64 Date: Tue, 19 Jul 2022 14:44:11 -0700 Subject: [PATCH 1/9] alacritty: change default font size down to 11.5 --- .config/alacritty/alacritty.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.config/alacritty/alacritty.yml b/.config/alacritty/alacritty.yml index f31299a..45abecf 100644 --- a/.config/alacritty/alacritty.yml +++ b/.config/alacritty/alacritty.yml @@ -73,7 +73,7 @@ font: family: Sauce Code Pro NF # sizes that work well for 1920 by 1080: 14 (large), 12 (wide), 11.5 (narrow) - size: 12 + size: 11.5 offset: x: 0 From c00ed5f5ffb387eeb75a8459827112d542e39983 Mon Sep 17 00:00:00 2001 From: PowerUser64 Date: Tue, 19 Jul 2022 14:44:54 -0700 Subject: [PATCH 2/9] aliases: comment and add sd for sudo (tentative) --- .config/shell/aliases | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.config/shell/aliases b/.config/shell/aliases index a8dd4ac..59e3a39 100644 --- a/.config/shell/aliases +++ b/.config/shell/aliases @@ -4,6 +4,8 @@ alias \ vimdiff='nvim -d' \ +alias sd=sudo + alias \ vv='$EDITOR' \ e='$EDITOR' \ @@ -31,7 +33,7 @@ alias \ # <<< ## Program improvements (ex: ls = ls -h) >>> -alias sudo='sudo VISUAL="$VISUAL" SYSTEMD_EDITOR="$SYSTEMD_EDITOR" ' # allow using aliases in sudo commands +alias sudo='sudo VISUAL="$VISUAL" SYSTEMD_EDITOR="$SYSTEMD_EDITOR" ' # allow using aliases in sudo commands and add some env vars alias df='df -h' # Human-readable sizes alias free='free -m' # Show sizes in MB alias bc='bc -ql' # Make bc usable for fast math From c10da0b928175c6f9a5653de4fe6f7e569703eb6 Mon Sep 17 00:00:00 2001 From: PowerUser64 Date: Sun, 24 Jul 2022 02:06:47 -0700 Subject: [PATCH 3/9] shell: add color output to `ip`, and better colors for `less` and `man` --- .config/shell/aliases | 1 + .config/shell/env | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/.config/shell/aliases b/.config/shell/aliases index 59e3a39..287322e 100644 --- a/.config/shell/aliases +++ b/.config/shell/aliases @@ -54,6 +54,7 @@ alias \ fgrep='fgrep --color=auto' \ diff='diff --color=auto' \ pacman='pacman --color=auto' \ + alias ip='ip -color=auto' \ # super duper paru alias # shellcheck disable=SC2139 diff --git a/.config/shell/env b/.config/shell/env index 28ccdaf..b8307a6 100644 --- a/.config/shell/env +++ b/.config/shell/env @@ -25,6 +25,11 @@ export PATH="$PATH:${XDG_DATA_HOME:-$HOME/.local}/bin:$SHELL_CONFIG_DIR/bin" # Basic default LS colors export LSCOLORS="Gxfxcxdxbxegedabagacad" +# `less` colors +# shellcheck disable=SC2016 +export LESS='-R --use-color -Dd+g$Du+b' +export MANPAGER="less -R --use-color -Dd+g -Du+b" + # Theme for zsh and nvim (soon™) COLOR_SCHEME=tokyonight From 289109c247e3aeb62788f7738a61dfb6dd44b6f6 Mon Sep 17 00:00:00 2001 From: PowerUser64 Date: Mon, 25 Jul 2022 21:48:45 -0700 Subject: [PATCH 4/9] nvim: disable indent_blankline context start --- .config/nvim/lua/blake/other.lua | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.config/nvim/lua/blake/other.lua b/.config/nvim/lua/blake/other.lua index b530d65..d64f436 100644 --- a/.config/nvim/lua/blake/other.lua +++ b/.config/nvim/lua/blake/other.lua @@ -165,9 +165,8 @@ M.indent_blankline = function() let g:indent_blankline_show_current_context = v:true ]] require("indent_blankline").setup { - -- for example, context is off by default, use this to turn it on show_current_context = true, - show_current_context_start = true, + show_current_context_start = false, } end -- <<< From 5ec4df6e75f79839a403509194c4b99c5bccc813 Mon Sep 17 00:00:00 2001 From: PowerUser64 Date: Tue, 26 Jul 2022 02:21:23 -0700 Subject: [PATCH 5/9] nvim: add lots of plugins --- .config/nvim/lua/blake/plugins.lua | 111 ++++++++++++++++++----------- 1 file changed, 70 insertions(+), 41 deletions(-) diff --git a/.config/nvim/lua/blake/plugins.lua b/.config/nvim/lua/blake/plugins.lua index 280dc30..e129ffe 100644 --- a/.config/nvim/lua/blake/plugins.lua +++ b/.config/nvim/lua/blake/plugins.lua @@ -14,7 +14,7 @@ return require('packer').startup({function() -- TODO: Find a better way to organize this -- impatient (needs to go early) - use { -- lewis6991: impatient: Make nvim load faster by caching them + use { -- lewis6991: impatient: Make nvim load faster by caching them - needs to load early 'lewis6991/impatient.nvim', config = function() require('impatient') @@ -22,7 +22,7 @@ return require('packer').startup({function() } -- Packer - use { -- packer + use { -- packer: plugin manager 'wbthomason/packer.nvim', config = function() -- Map :PS to :PackerSync @@ -37,7 +37,7 @@ return require('packer').startup({function() require('blake.lsp').treesitter() end, } - use { -- onedark theme + use { -- onedark.nvim: onedark theme 'navarasu/onedark.nvim', config = function() -- vim.g.onedark_transparent_background = true @@ -48,7 +48,7 @@ return require('packer').startup({function() ]] end } - use { -- tokyonight theme + use { -- tokyonight.nvim: tokyonight theme 'folke/tokyonight.nvim', config = function() -- vim.g.onedark_transparent_background = true @@ -71,14 +71,14 @@ return require('packer').startup({function() require('blake.other').lualine() end, } - use { -- nvim-tabline + use { -- nvim-tabline: batter looking tabline 'alvarosevilla95/luatab.nvim', requires = 'kyazdani42/nvim-web-devicons', config = function() require('luatab').setup() end } - use { -- css color tag highlighter (ex: #FFB13B) + use { -- nvim-colorizer: css color tag highlighter (ex- #FFB13B) 'norcalli/nvim-colorizer.lua', config = function() vim.cmd 'command! COL ColorizerToggle' @@ -87,9 +87,9 @@ return require('packer').startup({function() -- IDE features ---- LSP - use { -- lspinstall + lspconfig + use { -- lspinstall: language server installer, (lspconfig is here too) 'williamboman/nvim-lsp-installer', - { -- lspconfig + { -- lspconfig: default language server configurations 'neovim/nvim-lspconfig', config = function() require('blake.lsp').lspinstall() @@ -97,7 +97,7 @@ return require('packer').startup({function() end } } - use { -- commentstring based on context from treesitter + use { -- ts-context-commentstring: set commentstring based on context from treesitter (two langs in one file) 'JoosepAlviste/nvim-ts-context-commentstring', requires = 'nvim-treesitter/nvim-treesitter', config = function() @@ -109,7 +109,7 @@ return require('packer').startup({function() } end, } - use { -- compe + use { -- cmp: completion menu 'hrsh7th/nvim-cmp', config = function() require('blake.lsp').cmp() @@ -128,17 +128,23 @@ return require('packer').startup({function() 'hrsh7th/cmp-emoji', }, } - use { -- luasnip (snippits) + use { -- luasnip: snippits plugin 'L3MON4D3/LuaSnip', + config = function() + require("luasnip.loaders.from_vscode").lazy_load() + end } - use { -- function parameter previews + use { -- friendly-snippets: lots of good snippits + 'rafamadriz/friendly-snippets' + } + use { -- lsp_signature: function parameter previews 'ray-x/lsp_signature.nvim', after = 'nvim-lspconfig', config = function() require('blake.lsp').signature() end, } - use { -- symbols-outline: treesitter-based document outline (:SO) + use { -- symbols-outline: treesitter-based document outline (SO) 'simrat39/symbols-outline.nvim', config = function() vim.cmd 'command! SO SymbolsOutline' @@ -159,7 +165,7 @@ return require('packer').startup({function() require('blake.dap').nvim_dap() end } - -- use { -- DAP adapter installer + -- use { -- dap-buddy: DAP adapter installer -- 'Pocco81/dap-buddy.nvim', -- config = function() -- require('blake.dap').dap_buddy() @@ -171,7 +177,7 @@ return require('packer').startup({function() require("nvim-dap-virtual-text").setup() end } - use { -- a UI for nvim-dap (easy access to info) + use { -- nvim-dap-ui: a UI for nvim-dap 'rcarriga/nvim-dap-ui', config = function() require('blake.dap').dap_ui() @@ -186,7 +192,7 @@ return require('packer').startup({function() require('blake.other').telescope() end } - use { -- git integration + use { -- gitsigns: git integration 'lewis6991/gitsigns.nvim', requires = { 'nvim-lua/plenary.nvim' @@ -195,37 +201,37 @@ return require('packer').startup({function() require('blake.other').gitsigns() end, } - -- use { -- file manager + -- use { -- nvim-tree: file manager -- 'kyazdani42/nvim-tree.lua', -- requires = 'kyazdani42/nvim-web-devicons', -- config = function() -- require('blake.other').nvimtree() -- end -- } - use { -- terminal + use { -- toggleterm: terminal 'akinsho/toggleterm.nvim', tag = 'v1.*', config = function() require('blake.other').toggleterm() end } - use { -- Smooth Scrolling + use { -- neoscroll: Smooth Scrolling 'karb94/neoscroll.nvim', config = function() require('blake.other').neoscroll() end, } - use { -- automatic session management + use { -- auto-session: automatic session management 'rmagatti/auto-session', config = function() require('blake.other').autosession() end } - use { -- Markdown preview + use { -- glow: Markdown preview 'ellisonleao/glow.nvim', ft = { 'md', 'markdown', } } - use { -- Zen mode (:ZenMode or :ZM) + use { -- zen mode: (ZenMode or ZM) "folke/zen-mode.nvim", config = function() require('blake.other').zenmode() @@ -233,7 +239,7 @@ return require('packer').startup({function() vim.cmd 'inoremap ZenMode' end, } - -- use { -- dim text outside paragraph or function + -- use { -- twilight.nvim: dim text outside paragraph or function -- 'folke/twilight.nvim', -- config = function() -- vim.cmd 'command! TW Twilight' @@ -257,7 +263,7 @@ return require('packer').startup({function() -- } -- Conveniences - use { -- sort motion (gs) + use { -- sort motion: (gs) 'christoomey/vim-sort-motion', config = function() vim.cmd [[ @@ -267,19 +273,19 @@ return require('packer').startup({function() end, requires = 'navicore/vissort.vim', -- config requires } - use { -- Ghost: Web browser integration + use { -- ghost: Web browser integration 'raghur/vim-ghost', opt = true, cmd = {'GhostStart', 'GhostInstall', 'GhostStop', 'GhostSync', 'GhostToggleSync',}, } - use { -- Undo tree + use { -- undotree: visual undo tree 'mbbill/undotree', config = function() vim.cmd 'nnoremap UndotreeToggle' vim.api.nvim_set_keymap('n', '', 'UndotreeToggle', { noremap = true, silent = true, }) end } - -- use { -- Dim inactive window + -- use { -- shade.nvim: dim inactive window -- 'sunjon/shade.nvim', -- config = function() -- require'shade'.setup({ @@ -293,7 +299,7 @@ return require('packer').startup({function() -- }) -- end -- } - use { -- Quote pairing + use { -- nvim-autopairs: automatic quote pairing 'windwp/nvim-autopairs', config = function() -- If you want insert `(` after select function or method item @@ -317,7 +323,7 @@ return require('packer').startup({function() require('nvim-ts-autotag').setup() end } - use { -- endwise: auto add 'end' keyword + use { -- endwise: auto add 'end' keyword when typing loops in various languages 'RRethy/nvim-treesitter-endwise', config = function() require('nvim-treesitter.configs').setup { @@ -327,16 +333,13 @@ return require('packer').startup({function() } end } - use { -- accelerated jk movement - 'rhysd/accelerated-jk' - } use { -- cheat.sh integration 'dbeniamine/cheat.sh-vim', } use { -- nvim-align: Align text - 'RRethy/nvim-align' + 'RRethy/nvim-align', } - use { -- Comments (gb and gc) + use { -- comment.nvim: toggle comments - gb and gc 'numToStr/Comment.nvim', config = function() require('Comment').setup { @@ -362,10 +365,36 @@ return require('packer').startup({function() } end } + use { -- vim-illuminate: highlight other occurrences of the word under cursor + 'RRethy/vim-illuminate', + } + use { -- filetype.nvim: detect filetype a lot faster than stock neovim + 'nathom/filetype.nvim', + } + use { -- vim-rooter: cd to the root of a project when opening a file or folder + 'notjedi/nvim-rooter.lua', + } + use { -- splitjoin: switch between single line and multiline versions of code - gJ and gS + 'AndrewRadev/splitjoin.vim', + } + use { -- rhysd: clever-split: split calculation based on pane dimensions - CS or CleverSplit + 'rhysd/clever-split.vim', + config = function() + -- Map :CS to :CleverSplit + vim.cmd 'command! CS CleverSplit' + end + } + use { -- rhysd: textobj-anyblock: allow ab or ib instead of i( or a[ or any of the many other block selectors + 'rhysd/vim-textobj-anyblock', + requires = 'kana/vim-textobj-user', + } + -- use { -- rhysd: accelerated jk: make j and k move faster by pressing them a lot movement + -- 'rhysd/accelerated-jk', + -- } use { -- rhysd: committia: better commit editing window 'rhysd/committia.vim', } - use { -- rhysd: conflict-marker: mark git conflicts - [x ]x + use { -- rhysd: conflict-marker: mark git conflicts - [x, ]x, co, ct, cb, cB, cn 'rhysd/conflict-marker.vim', } use { -- lewis6991: spellsitter: Spell checking in treesitter files @@ -402,16 +431,16 @@ return require('packer').startup({function() -- ]] -- end, -- } - use { -- tpope: surround - 'tpope/vim-surround' + use { -- tpope: surround: surround text with quotes, parens, tags, and more - ys + 'tpope/vim-surround', } - use { -- tpope: git integration - 'tpope/vim-fugitive' + use { -- tpope: fugitive: git integration + 'tpope/vim-fugitive', } - use { -- tpope: Repeatability for various tpope plugins + use { -- tpope: repeat: Repeatability for various tpope plugins 'tpope/vim-repeat', } - use { -- tpope: automatically get info about files and apply it to vim (tabs vs spaces, etc) + use { -- tpope: sleuth: automatically get info about files and apply it to vim (tabs vs spaces, etc) 'tpope/vim-sleuth', } From 514e74698ce0c6375679e6b949e0e0320077f42c Mon Sep 17 00:00:00 2001 From: PowerUser64 Date: Tue, 26 Jul 2022 02:24:10 -0700 Subject: [PATCH 6/9] nvim: align plugin descriptions --- .config/nvim/lua/blake/plugins.lua | 123 +++++++++++++++-------------- 1 file changed, 62 insertions(+), 61 deletions(-) diff --git a/.config/nvim/lua/blake/plugins.lua b/.config/nvim/lua/blake/plugins.lua index e129ffe..ed72ac2 100644 --- a/.config/nvim/lua/blake/plugins.lua +++ b/.config/nvim/lua/blake/plugins.lua @@ -14,7 +14,7 @@ return require('packer').startup({function() -- TODO: Find a better way to organize this -- impatient (needs to go early) - use { -- lewis6991: impatient: Make nvim load faster by caching them - needs to load early + use { -- lewis6991: impatient: Make nvim load faster by caching them - needs to load early 'lewis6991/impatient.nvim', config = function() require('impatient') @@ -22,7 +22,7 @@ return require('packer').startup({function() } -- Packer - use { -- packer: plugin manager + use { -- packer: plugin manager 'wbthomason/packer.nvim', config = function() -- Map :PS to :PackerSync @@ -31,13 +31,13 @@ return require('packer').startup({function() } -- Colors (decorations) - use { -- treesitter: syntax highlighting and more + use { -- treesitter: syntax highlighting and more 'nvim-treesitter/nvim-treesitter', run = ':TSUpdate', config = function() require('blake.lsp').treesitter() end, } - use { -- onedark.nvim: onedark theme + use { -- onedark.nvim: onedark theme 'navarasu/onedark.nvim', config = function() -- vim.g.onedark_transparent_background = true @@ -48,7 +48,7 @@ return require('packer').startup({function() ]] end } - use { -- tokyonight.nvim: tokyonight theme + use { -- tokyonight.nvim: tokyonight theme 'folke/tokyonight.nvim', config = function() -- vim.g.onedark_transparent_background = true @@ -61,24 +61,24 @@ return require('packer').startup({function() vim.cmd 'colorscheme tokyonight' end, } - use { -- newspring: Good light theme for writing + use { -- newspring: Good light theme for writing 'NLKNguyen/papercolor-theme', } - use { -- statusline: lualine + use { -- statusline: lualine 'nvim-lualine/lualine.nvim', requires = {'kyazdani42/nvim-web-devicons', opt = true}, config = function() require('blake.other').lualine() end, } - use { -- nvim-tabline: batter looking tabline + use { -- nvim-tabline: batter looking tabline 'alvarosevilla95/luatab.nvim', requires = 'kyazdani42/nvim-web-devicons', config = function() require('luatab').setup() end } - use { -- nvim-colorizer: css color tag highlighter (ex- #FFB13B) + use { -- nvim-colorizer: css color tag highlighter (ex- #FFB13B) 'norcalli/nvim-colorizer.lua', config = function() vim.cmd 'command! COL ColorizerToggle' @@ -87,7 +87,7 @@ return require('packer').startup({function() -- IDE features ---- LSP - use { -- lspinstall: language server installer, (lspconfig is here too) + use { -- lspinstall: language server installer, (lspconfig is here too) 'williamboman/nvim-lsp-installer', { -- lspconfig: default language server configurations 'neovim/nvim-lspconfig', @@ -97,7 +97,7 @@ return require('packer').startup({function() end } } - use { -- ts-context-commentstring: set commentstring based on context from treesitter (two langs in one file) + use { -- ts-context-commentstring: set commentstring based on context from treesitter (two langs in one file) 'JoosepAlviste/nvim-ts-context-commentstring', requires = 'nvim-treesitter/nvim-treesitter', config = function() @@ -109,7 +109,7 @@ return require('packer').startup({function() } end, } - use { -- cmp: completion menu + use { -- cmp: completion menu 'hrsh7th/nvim-cmp', config = function() require('blake.lsp').cmp() @@ -128,30 +128,30 @@ return require('packer').startup({function() 'hrsh7th/cmp-emoji', }, } - use { -- luasnip: snippits plugin + use { -- luasnip: snippits plugin 'L3MON4D3/LuaSnip', config = function() require("luasnip.loaders.from_vscode").lazy_load() end } - use { -- friendly-snippets: lots of good snippits + use { -- friendly-snippets: lots of good snippits 'rafamadriz/friendly-snippets' } - use { -- lsp_signature: function parameter previews + use { -- lsp_signature: function parameter previews 'ray-x/lsp_signature.nvim', after = 'nvim-lspconfig', config = function() require('blake.lsp').signature() end, } - use { -- symbols-outline: treesitter-based document outline (SO) + use { -- symbols-outline: treesitter-based document outline (SO) 'simrat39/symbols-outline.nvim', config = function() vim.cmd 'command! SO SymbolsOutline' vim.cmd 'nnoremap so SymbolsOutline' end, } - -- use { -- ALE: Support for lots of linters, etc + -- use { -- ALE: Support for lots of linters, etc -- 'dense-analysis/ale', -- ft = {'sh', 'zsh', 'zshrc', 'bashrc', 'bash'}, -- config = function() @@ -159,25 +159,25 @@ return require('packer').startup({function() -- end -- } ---- DAP (Debug Adapter Protocol) - use { -- nvim-dap: DAP support + use { -- nvim-dap: DAP support 'mfussenegger/nvim-dap', config = function() require('blake.dap').nvim_dap() end } - -- use { -- dap-buddy: DAP adapter installer + -- use { -- dap-buddy: DAP adapter installer -- 'Pocco81/dap-buddy.nvim', -- config = function() -- require('blake.dap').dap_buddy() -- end -- } - use { -- virtual-text: Print Variable names while debugging + use { -- virtual-text: Print Variable names while debugging 'theHamsta/nvim-dap-virtual-text', config = function() require("nvim-dap-virtual-text").setup() end } - use { -- nvim-dap-ui: a UI for nvim-dap + use { -- nvim-dap-ui: a UI for nvim-dap 'rcarriga/nvim-dap-ui', config = function() require('blake.dap').dap_ui() @@ -185,14 +185,14 @@ return require('packer').startup({function() } ---- Other IDE features - use { -- telescope: fuzzy finder for finding fuzzy things + use { -- telescope: fuzzy finder for finding fuzzy things 'nvim-telescope/telescope.nvim', requires = { {'nvim-lua/plenary.nvim'} }, config = function() require('blake.other').telescope() end } - use { -- gitsigns: git integration + use { -- gitsigns: git integration 'lewis6991/gitsigns.nvim', requires = { 'nvim-lua/plenary.nvim' @@ -201,37 +201,37 @@ return require('packer').startup({function() require('blake.other').gitsigns() end, } - -- use { -- nvim-tree: file manager + -- use { -- nvim-tree: file manager -- 'kyazdani42/nvim-tree.lua', -- requires = 'kyazdani42/nvim-web-devicons', -- config = function() -- require('blake.other').nvimtree() -- end -- } - use { -- toggleterm: terminal + use { -- toggleterm: terminal 'akinsho/toggleterm.nvim', tag = 'v1.*', config = function() require('blake.other').toggleterm() end } - use { -- neoscroll: Smooth Scrolling + use { -- neoscroll: Smooth Scrolling 'karb94/neoscroll.nvim', config = function() require('blake.other').neoscroll() end, } - use { -- auto-session: automatic session management + use { -- auto-session: automatic session management 'rmagatti/auto-session', config = function() require('blake.other').autosession() end } - use { -- glow: Markdown preview + use { -- glow: Markdown preview 'ellisonleao/glow.nvim', ft = { 'md', 'markdown', } } - use { -- zen mode: (ZenMode or ZM) + use { -- zen mode: (ZenMode or ZM) "folke/zen-mode.nvim", config = function() require('blake.other').zenmode() @@ -239,31 +239,31 @@ return require('packer').startup({function() vim.cmd 'inoremap ZenMode' end, } - -- use { -- twilight.nvim: dim text outside paragraph or function + -- use { -- twilight.nvim: dim text outside paragraph or function -- 'folke/twilight.nvim', -- config = function() -- vim.cmd 'command! TW Twilight' -- require("twilight").setup() -- end, -- } - use { -- matchup: Use the percent (%) key for more things + use { -- matchup: Use the percent (%) key for more things 'andymass/vim-matchup', } - -- use { -- lightspeed: Jump around in files quickly + -- use { -- lightspeed: Jump around in files quickly -- 'ggandor/lightspeed.nvim', -- } - use { -- indentline: Line indent indicators + use { -- indentline: Line indent indicators 'lukas-reineke/indent-blankline.nvim', config = function() require('blake.other').indent_blankline() end } - -- use { -- targets.vim: fix ci' and other things to work right + -- use { -- targets.vim: fix ci' and other things to work right -- 'wellle/targets.vim', -- } -- Conveniences - use { -- sort motion: (gs) + use { -- sort motion: (gs) 'christoomey/vim-sort-motion', config = function() vim.cmd [[ @@ -273,19 +273,19 @@ return require('packer').startup({function() end, requires = 'navicore/vissort.vim', -- config requires } - use { -- ghost: Web browser integration + use { -- ghost: Web browser integration 'raghur/vim-ghost', opt = true, cmd = {'GhostStart', 'GhostInstall', 'GhostStop', 'GhostSync', 'GhostToggleSync',}, } - use { -- undotree: visual undo tree + use { -- undotree: visual undo tree 'mbbill/undotree', config = function() vim.cmd 'nnoremap UndotreeToggle' vim.api.nvim_set_keymap('n', '', 'UndotreeToggle', { noremap = true, silent = true, }) end } - -- use { -- shade.nvim: dim inactive window + -- use { -- shade.nvim: dim inactive window -- 'sunjon/shade.nvim', -- config = function() -- require'shade'.setup({ @@ -299,7 +299,7 @@ return require('packer').startup({function() -- }) -- end -- } - use { -- nvim-autopairs: automatic quote pairing + use { -- nvim-autopairs: automatic quote pairing 'windwp/nvim-autopairs', config = function() -- If you want insert `(` after select function or method item @@ -317,13 +317,13 @@ return require('packer').startup({function() end, requires = 'hrsh7th/nvim-cmp', -- config requires } - use { -- ts-autotag: automatically close html tags + use { -- ts-autotag: automatically close html tags 'windwp/nvim-ts-autotag', config = function() require('nvim-ts-autotag').setup() end } - use { -- endwise: auto add 'end' keyword when typing loops in various languages + use { -- endwise: auto add 'end' keyword when typing loops in various languages 'RRethy/nvim-treesitter-endwise', config = function() require('nvim-treesitter.configs').setup { @@ -336,10 +336,10 @@ return require('packer').startup({function() use { -- cheat.sh integration 'dbeniamine/cheat.sh-vim', } - use { -- nvim-align: Align text + use { -- nvim-align: Align text 'RRethy/nvim-align', } - use { -- comment.nvim: toggle comments - gb and gc + use { -- comment.nvim: toggle comments - gb and gc 'numToStr/Comment.nvim', config = function() require('Comment').setup { @@ -365,63 +365,63 @@ return require('packer').startup({function() } end } - use { -- vim-illuminate: highlight other occurrences of the word under cursor + use { -- vim-illuminate: highlight other occurrences of the word under cursor 'RRethy/vim-illuminate', } - use { -- filetype.nvim: detect filetype a lot faster than stock neovim + use { -- filetype.nvim: detect filetype a lot faster than stock neovim 'nathom/filetype.nvim', } - use { -- vim-rooter: cd to the root of a project when opening a file or folder + use { -- vim-rooter: cd to the root of a project when opening a file or folder 'notjedi/nvim-rooter.lua', } - use { -- splitjoin: switch between single line and multiline versions of code - gJ and gS + use { -- splitjoin: switch between single line and multiline versions of code - gJ and gS 'AndrewRadev/splitjoin.vim', } - use { -- rhysd: clever-split: split calculation based on pane dimensions - CS or CleverSplit + use { -- rhysd: clever-split: split calculation based on pane dimensions - CS or CleverSplit 'rhysd/clever-split.vim', config = function() -- Map :CS to :CleverSplit vim.cmd 'command! CS CleverSplit' end } - use { -- rhysd: textobj-anyblock: allow ab or ib instead of i( or a[ or any of the many other block selectors + use { -- rhysd: textobj-anyblock: allow ab or ib instead of i( or a[ or any of the many other block selectors 'rhysd/vim-textobj-anyblock', requires = 'kana/vim-textobj-user', } - -- use { -- rhysd: accelerated jk: make j and k move faster by pressing them a lot movement + -- use { -- rhysd: accelerated jk: make j and k move faster by pressing them a lot movement -- 'rhysd/accelerated-jk', -- } - use { -- rhysd: committia: better commit editing window + use { -- rhysd: committia: better commit editing window 'rhysd/committia.vim', } - use { -- rhysd: conflict-marker: mark git conflicts - [x, ]x, co, ct, cb, cB, cn + use { -- rhysd: conflict-marker: mark git conflicts - [x, ]x, co, ct, cb, cB, cn 'rhysd/conflict-marker.vim', } - use { -- lewis6991: spellsitter: Spell checking in treesitter files + use { -- lewis6991: spellsitter: Spell checking in treesitter files 'lewis6991/spellsitter.nvim', config = function() require('spellsitter').setup() end, } - use { -- lewis6991: spaceless: Strip trailing whitespace as you are editing + use { -- lewis6991: spaceless: Strip trailing whitespace as you are editing 'lewis6991/spaceless.nvim', config = function() require'spaceless'.setup() end, } - use { -- lewis6991: foldsigns: signcolumn signs on folded lines + use { -- lewis6991: foldsigns: signcolumn signs on folded lines 'lewis6991/foldsigns.nvim', config = function() require('foldsigns').setup() end, } - use { -- lewis6991: cleanfold: folds have never looked better + use { -- lewis6991: cleanfold: folds have never looked better 'lewis6991/cleanfold.nvim', config = function() require('cleanfold').setup() end, } - -- use { -- lewis6991: sattelite: small scroll bar + -- use { -- lewis6991: sattelite: small scroll bar -- 'lewis6991/satellite.nvim', -- config = function() -- require('satellite').setup() @@ -431,16 +431,16 @@ return require('packer').startup({function() -- ]] -- end, -- } - use { -- tpope: surround: surround text with quotes, parens, tags, and more - ys + use { -- tpope: surround: surround text with quotes, parens, tags, and more - ys 'tpope/vim-surround', } - use { -- tpope: fugitive: git integration + use { -- tpope: fugitive: git integration 'tpope/vim-fugitive', } - use { -- tpope: repeat: Repeatability for various tpope plugins + use { -- tpope: repeat: Repeatability for various tpope plugins 'tpope/vim-repeat', } - use { -- tpope: sleuth: automatically get info about files and apply it to vim (tabs vs spaces, etc) + use { -- tpope: sleuth: automatically get info about files and apply it to vim (tabs vs spaces, etc) 'tpope/vim-sleuth', } @@ -456,4 +456,5 @@ config = { compile_path = vim.fn.stdpath('config')..'/lua/packer_compiled.lua', }}) +-- vim command to align all plugin descriptions: select all plugins in visual line, :'<,'>Align \(.\+use { -- .\+: \+\)\@<=[^ ][^:]\+$ -- vim:fdm=marker:fmr={,}:fdl=1:expandtab:tabstop=3:sw=3 From d1925243250ca757e7806cadd774090c6100f0d4 Mon Sep 17 00:00:00 2001 From: PowerUser64 Date: Tue, 26 Jul 2022 02:24:48 -0700 Subject: [PATCH 7/9] shell: nvc is now a script rather than an alias --- .config/shell/aliases | 4 +++- .config/shell/bin/nvc | 6 ++++++ 2 files changed, 9 insertions(+), 1 deletion(-) create mode 100755 .config/shell/bin/nvc diff --git a/.config/shell/aliases b/.config/shell/aliases index 287322e..53050fd 100644 --- a/.config/shell/aliases +++ b/.config/shell/aliases @@ -89,9 +89,11 @@ alias ydotool='(sudo ydotoold &) && sleep 0.05 && sudo ydotool' # Update zinit and plugins alias zup='zinit self-update && zinit update --parallel' +# Run PackerSync in neovim with PS +alias PS='nvim --headless -c "autocmd User PackerComplete quitall" -c "PackerSync"' + # Edit config files alias \ - nvc='(cd ~/.config/nvim/lua/blake && nvim ../../init.lua)' \ zc='$EDITOR ~/.zshrc' \ sc='$EDITOR $SHELL_CONFIG_DIR/shrc' \ fstab='sudoedit /etc/fstab' \ diff --git a/.config/shell/bin/nvc b/.config/shell/bin/nvc new file mode 100755 index 0000000..d6869fb --- /dev/null +++ b/.config/shell/bin/nvc @@ -0,0 +1,6 @@ +#!/bin/sh +# Purpose: edit nvim configuration while being cd'd into the directory that +# most of the files live so they can easily be :e'd +# Usage: nvc +cd ~/.config/nvim/lua/blake \ + && nvim ../../init.lua From 650cd0a4c177ef420806497001b35758385eaec8 Mon Sep 17 00:00:00 2001 From: PowerUser64 Date: Tue, 26 Jul 2022 02:25:20 -0700 Subject: [PATCH 8/9] nvim: update cmp config --- .config/nvim/lua/blake/lsp.lua | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.config/nvim/lua/blake/lsp.lua b/.config/nvim/lua/blake/lsp.lua index acc89a5..52573b6 100644 --- a/.config/nvim/lua/blake/lsp.lua +++ b/.config/nvim/lua/blake/lsp.lua @@ -139,16 +139,16 @@ M.cmp = function() end, }, sources = { - { name = 'path' }, - { name = 'nvim_lua' }, { name = 'nvim_lsp' }, + { name = 'nvim_lua' }, { name = 'luasnip' }, { name = 'treesitter' }, { name = 'calc' }, -- { name = 'spell' }, - { name = 'buffer' }, { name = 'cmdline' }, { name = 'emoji' }, + { name = 'buffer' }, + { name = 'path' }, }, formatting = { format = function(entry, vim_item) @@ -178,6 +178,11 @@ M.cmp = function() return vim_item end, }, + window = { + documentation = { + border = { "╭", "─", "╮", "│", "╯", "─", "╰", "│" }, + }, + }, experimental = { ghost_text = true, } From 69238a80ef0a257fbf1b82d31065c5d288beaf54 Mon Sep 17 00:00:00 2001 From: PowerUser64 Date: Wed, 27 Jul 2022 02:20:33 -0700 Subject: [PATCH 9/9] nvim: fix nvim-cmp path (hopefully for good now?) --- .config/nvim/lua/blake/lsp.lua | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.config/nvim/lua/blake/lsp.lua b/.config/nvim/lua/blake/lsp.lua index 52573b6..5254821 100644 --- a/.config/nvim/lua/blake/lsp.lua +++ b/.config/nvim/lua/blake/lsp.lua @@ -153,7 +153,7 @@ M.cmp = function() formatting = { format = function(entry, vim_item) -- fancy icons and a name of kind - format = require('lspkind').cmp_format({ + require('lspkind').cmp_format({ mode = 'symbol', -- show only symbol annotations maxwidth = 50, -- prevent the popup from showing more than provided characters (e.g 50 will not show more than 50 characters) @@ -200,15 +200,15 @@ M.cmp = function() cmp.setup.cmdline('/', search_config) cmp.setup.cmdline('?', search_config) - -- Use cmdline & path source for ':' (if you enabled `native_menu`, this won't work anymore). - cmp.setup.cmdline(':', { + -- `:` cmdline setup. + cmp.setup.cmdline(':', { mapping = cmp.mapping.preset.cmdline(), sources = cmp.config.sources({ - { name = 'cmdline' } + { name = 'path' } }, { - { name = 'path' } + { name = 'cmdline' } }) - }) + }) end -- <<< -- lspconfig >>>