nvim: add satellite.nvim, and new bind for nohlsearch (<C-l>)
TODO: find a way to detect satellite.nvim and make a default bind in settings.lua
This commit is contained in:
parent
dc771d203e
commit
ee46d57ac0
2 changed files with 67 additions and 56 deletions
|
@ -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
|
||||
'lewis6991/impatient.nvim',
|
||||
config = function()
|
||||
require('impatient')
|
||||
|
@ -22,7 +22,7 @@ return require('packer').startup({function()
|
|||
}
|
||||
|
||||
-- Packer
|
||||
use { -- packer
|
||||
use { -- packer
|
||||
'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 theme
|
||||
use { -- onedark theme
|
||||
'navarasu/onedark.nvim',
|
||||
config = function()
|
||||
-- vim.g.onedark_transparent_background = true
|
||||
|
@ -48,20 +48,20 @@ return require('packer').startup({function()
|
|||
]]
|
||||
end
|
||||
}
|
||||
use { -- tokyonight theme
|
||||
use { -- tokyonight theme
|
||||
'folke/tokyonight.nvim',
|
||||
}
|
||||
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
|
||||
use { -- nvim-tabline
|
||||
'seblj/nvim-tabline',
|
||||
requires = 'kyazdani42/nvim-web-devicons',
|
||||
config = function()
|
||||
|
@ -72,7 +72,7 @@ return require('packer').startup({function()
|
|||
}
|
||||
end
|
||||
}
|
||||
use { -- css color tag highlighter (ex: #FFB13B)
|
||||
use { -- css color tag highlighter (ex: #FFB13B)
|
||||
'norcalli/nvim-colorizer.lua',
|
||||
config = function()
|
||||
vim.cmd 'command! COL ColorizerToggle'
|
||||
|
@ -81,9 +81,9 @@ return require('packer').startup({function()
|
|||
|
||||
-- IDE features
|
||||
---- LSP
|
||||
use { -- lspinstall + lspconfig
|
||||
use { -- lspinstall + lspconfig
|
||||
'williamboman/nvim-lsp-installer',
|
||||
{ -- lspconfig
|
||||
{ -- lspconfig
|
||||
'neovim/nvim-lspconfig',
|
||||
config = function()
|
||||
require('blake.lsp').lspinstall()
|
||||
|
@ -91,7 +91,7 @@ return require('packer').startup({function()
|
|||
end
|
||||
}
|
||||
}
|
||||
use { -- commentstring based on context from treesitter
|
||||
use { -- commentstring based on context from treesitter
|
||||
'JoosepAlviste/nvim-ts-context-commentstring',
|
||||
requires = 'nvim-treesitter/nvim-treesitter',
|
||||
config = function()
|
||||
|
@ -103,7 +103,7 @@ return require('packer').startup({function()
|
|||
}
|
||||
end,
|
||||
}
|
||||
use { -- compe
|
||||
use { -- compe
|
||||
'hrsh7th/nvim-cmp',
|
||||
config = function()
|
||||
require('blake.lsp').cmp()
|
||||
|
@ -122,24 +122,24 @@ return require('packer').startup({function()
|
|||
'hrsh7th/cmp-emoji',
|
||||
},
|
||||
}
|
||||
use { -- luasnip (snippits)
|
||||
use { -- luasnip (snippits)
|
||||
'L3MON4D3/LuaSnip',
|
||||
}
|
||||
use { -- function parameter previews
|
||||
use { -- 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 <Leader>so <cmd>SymbolsOutline<CR>'
|
||||
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()
|
||||
|
@ -147,25 +147,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 adapter installer
|
||||
-- use { -- 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 { -- a UI for nvim-dap (easy access to info)
|
||||
use { -- a UI for nvim-dap (easy access to info)
|
||||
'rcarriga/nvim-dap-ui',
|
||||
config = function()
|
||||
require('blake.dap').dap_ui()
|
||||
|
@ -173,14 +173,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 { -- git integration
|
||||
use { -- git integration
|
||||
'lewis6991/gitsigns.nvim',
|
||||
requires = {
|
||||
'nvim-lua/plenary.nvim'
|
||||
|
@ -189,37 +189,37 @@ return require('packer').startup({function()
|
|||
require('blake.other').gitsigns()
|
||||
end,
|
||||
}
|
||||
-- use { -- file manager
|
||||
-- use { -- file manager
|
||||
-- 'kyazdani42/nvim-tree.lua',
|
||||
-- requires = 'kyazdani42/nvim-web-devicons',
|
||||
-- config = function()
|
||||
-- require('blake.other').nvimtree()
|
||||
-- end
|
||||
-- }
|
||||
use { -- terminal
|
||||
use { -- terminal
|
||||
'akinsho/toggleterm.nvim',
|
||||
tag = 'v1.*',
|
||||
config = function()
|
||||
require('blake.other').toggleterm()
|
||||
end
|
||||
}
|
||||
use { -- Smooth Scrolling
|
||||
use { -- Smooth Scrolling
|
||||
'karb94/neoscroll.nvim',
|
||||
config = function()
|
||||
require('blake.other').neoscroll()
|
||||
end,
|
||||
}
|
||||
use { -- automatic session management
|
||||
use { -- automatic session management
|
||||
'rmagatti/auto-session',
|
||||
config = function()
|
||||
require('blake.other').autosession()
|
||||
end
|
||||
}
|
||||
use { -- Markdown preview
|
||||
use { -- 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()
|
||||
|
@ -227,43 +227,43 @@ return require('packer').startup({function()
|
|||
vim.cmd 'inoremap <F10> <cmd>ZenMode<CR>'
|
||||
end,
|
||||
}
|
||||
-- use { -- dim text outside paragraph or function
|
||||
-- use { -- 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 { -- Ghost: Web browser integration
|
||||
use { -- Ghost: Web browser integration
|
||||
'raghur/vim-ghost',
|
||||
opt = true,
|
||||
cmd = {'GhostStart', 'GhostInstall', 'GhostStop', 'GhostSync', 'GhostToggleSync',},
|
||||
}
|
||||
use { -- Undo tree
|
||||
use { -- Undo tree
|
||||
'mbbill/undotree',
|
||||
config = function()
|
||||
vim.cmd 'nnoremap <F5> <cmd>UndotreeToggle<CR>'
|
||||
vim.api.nvim_set_keymap('n', '<F5>', '<cmd>UndotreeToggle<CR>', { noremap = true, silent = true, })
|
||||
end
|
||||
}
|
||||
-- use { -- Dim inactive window
|
||||
-- use { -- Dim inactive window
|
||||
-- 'sunjon/shade.nvim',
|
||||
-- config = function()
|
||||
-- require'shade'.setup({
|
||||
|
@ -277,22 +277,22 @@ return require('packer').startup({function()
|
|||
-- })
|
||||
-- end
|
||||
-- }
|
||||
use { -- Quote pairing
|
||||
use { -- Quote pairing
|
||||
'windwp/nvim-autopairs',
|
||||
config = function()
|
||||
require('nvim-autopairs').setup()
|
||||
end
|
||||
}
|
||||
use { -- accelerated jk movement
|
||||
use { -- accelerated jk movement
|
||||
'rhysd/accelerated-jk'
|
||||
}
|
||||
use { -- cheat.sh integration
|
||||
use { -- cheat.sh integration
|
||||
'dbeniamine/cheat.sh-vim',
|
||||
}
|
||||
use { -- nvim-align: Align text
|
||||
use { -- nvim-align: Align text
|
||||
'RRethy/nvim-align'
|
||||
}
|
||||
use { -- Comments (gb and gc)
|
||||
use { -- Comments (gb and gc)
|
||||
'numToStr/Comment.nvim',
|
||||
config = function()
|
||||
require('Comment').setup {
|
||||
|
@ -318,40 +318,56 @@ return require('packer').startup({function()
|
|||
}
|
||||
end
|
||||
}
|
||||
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
|
||||
use { -- rhysd: conflict-marker: mark git conflicts - [x ]x
|
||||
'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 { -- tpope: surround
|
||||
use { -- lewis6991: cleanfold: folds have never looked better
|
||||
'lewis6991/cleanfold.nvim',
|
||||
config = function()
|
||||
require('cleanfold').setup()
|
||||
end,
|
||||
}
|
||||
use { -- lewis6991: sattelite: small scroll bar
|
||||
'lewis6991/satellite.nvim',
|
||||
config = function()
|
||||
require('satellite').setup()
|
||||
vim.cmd [[
|
||||
nnoremap <C-l> <cmd>nohlsearch\|diffupdate\|SatelliteRefresh<CR>
|
||||
inoremap <C-l> <cmd>nohlsearch\|diffupdate\|SatelliteRefresh<CR>
|
||||
]]
|
||||
end,
|
||||
}
|
||||
use { -- tpope: surround
|
||||
'tpope/vim-surround'
|
||||
}
|
||||
use { -- tpope: git integration
|
||||
use { -- tpope: git integration
|
||||
'tpope/vim-fugitive'
|
||||
}
|
||||
use { -- tpope: Repeatability for various tpope plugins
|
||||
use { -- tpope: 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: automatically get info about files and apply it to vim (tabs vs spaces, etc)
|
||||
'tpope/vim-sleuth',
|
||||
}
|
||||
|
||||
|
|
|
@ -72,10 +72,6 @@ vim.cmd 'command! MakeTags !ctags -R .'
|
|||
-- Write buffer as root
|
||||
vim.cmd 'cmap w!! w !sudo tee > /dev/null %'
|
||||
|
||||
-- Press Alt h to toggle highlighting on/off, and show current value.
|
||||
vim.cmd 'nnoremap <M-h> <cmd>noh<CR>'
|
||||
vim.cmd 'inoremap <M-h> <cmd>noh<CR>'
|
||||
|
||||
-- Toggle spell check with alt S
|
||||
vim.cmd 'nnoremap <M-S> <cmd>set spell! spell?<CR>'
|
||||
|
||||
|
@ -102,7 +98,6 @@ vim.cmd 'nnoremap <silent> <Leader>- :exe "resize " . (winheight(0) * 2/3)<CR>'
|
|||
vim.cmd 'nnoremap <C-h> <C-w>h'
|
||||
vim.cmd 'nnoremap <C-j> <C-w>j'
|
||||
vim.cmd 'nnoremap <C-k> <C-w>k'
|
||||
vim.cmd 'nnoremap <C-l> <C-w>l'
|
||||
|
||||
-- Spell correct with Q, rather than z=
|
||||
vim.cmd 'nnoremap Q z='
|
||||
|
|
Loading…
Add table
Reference in a new issue