cleanup some vim configs, highlight long parts of lines
This commit is contained in:
parent
82339f122b
commit
8600e668c5
3 changed files with 32 additions and 25 deletions
|
|
@ -1,15 +1,5 @@
|
|||
{ pkgs, ... }:
|
||||
let
|
||||
vim-goyo = pkgs.vimUtils.buildVimPlugin {
|
||||
name = "vim-goyo";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "junegunn";
|
||||
repo = "goyo.vim";
|
||||
rev = "6b6ed2734084fdbb6315357ddcaecf9c8e6f143d";
|
||||
sha256 = "1ywlz1hn54kxyp5q0angriaarimq7ys7m6sk6l4x8jr1g2yh0afz";
|
||||
};
|
||||
};
|
||||
|
||||
vim-nix = pkgs.vimUtils.buildVimPlugin {
|
||||
name = "vim-nix";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
|
|
@ -74,7 +64,6 @@ with builtins;
|
|||
vim-javascript
|
||||
vim-json
|
||||
vim-jsx-pretty
|
||||
vim-prisma
|
||||
|
||||
vim-commentary
|
||||
vim-airline
|
||||
|
|
@ -125,9 +114,25 @@ with builtins;
|
|||
EOF
|
||||
'';
|
||||
}
|
||||
undotree
|
||||
vim-goyo
|
||||
luasnip
|
||||
{
|
||||
plugin = undotree;
|
||||
config = ''
|
||||
nnoremap <leader>u :UndotreeToggle<CR>
|
||||
let g:undotree_SetFocusWhenToggle = 1
|
||||
if has("persistent_undo")
|
||||
let target_path = expand('~/.undodir')
|
||||
|
||||
" create the directory and any parent directories
|
||||
" if the location does not exist.
|
||||
if !isdirectory(target_path)
|
||||
call mkdir(target_path, "p", 0700)
|
||||
endif
|
||||
|
||||
let &undodir=target_path
|
||||
set undofile
|
||||
endif
|
||||
'';
|
||||
}
|
||||
cmp-nvim-lsp
|
||||
{
|
||||
plugin = nvim-lspconfig;
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ filetype plugin indent on
|
|||
let g:netrw_liststyle = 3
|
||||
set nobackup
|
||||
set noswapfile
|
||||
set pastetoggle=<F2>
|
||||
set pastetoggle=<F3>
|
||||
set nowrap
|
||||
|
||||
set background=dark
|
||||
|
|
@ -17,8 +17,10 @@ set number relativenumber
|
|||
set numberwidth=1
|
||||
set cursorline
|
||||
set cursorcolumn
|
||||
autocmd WinEnter * if !exists('w:overLengthMatchId') | let w:overLengthMatchId = matchadd('OverLength', '\%81v.\+\%<122v') | endif
|
||||
autocmd WinEnter * if !exists('w:reallyOverLengthMatchId') | let w:reallyOverLengthMatchId = matchadd('ReallyOverLength', '\%121v.\+') | endif
|
||||
highlight OverLength ctermbg=DarkRed ctermfg=white guibg=#352e10
|
||||
match OverLength /\%81v.\+/
|
||||
highlight ReallyOverLength ctermbg=Red ctermfg=white guibg=#330000
|
||||
set termguicolors
|
||||
set ruler
|
||||
set list
|
||||
|
|
|
|||
|
|
@ -1,15 +1,15 @@
|
|||
local cmp = require("cmp")
|
||||
|
||||
cmp.setup({
|
||||
snippet = {
|
||||
-- REQUIRED - you must specify a snippet engine
|
||||
expand = function(args)
|
||||
-- vim.fn["vsnip#anonymous"](args.body) -- For `vsnip` users.
|
||||
require('luasnip').lsp_expand(args.body) -- For `luasnip` users.
|
||||
-- require('snippy').expand_snippet(args.body) -- For `snippy` users.
|
||||
-- vim.fn["UltiSnips#Anon"](args.body) -- For `ultisnips` users.
|
||||
end,
|
||||
},
|
||||
-- snippet = {
|
||||
-- -- REQUIRED - you must specify a snippet engine
|
||||
-- expand = function(args)
|
||||
-- -- vim.fn["vsnip#anonymous"](args.body) -- For `vsnip` users.
|
||||
-- require('luasnip').lsp_expand(args.body) -- For `luasnip` users.
|
||||
-- -- require('snippy').expand_snippet(args.body) -- For `snippy` users.
|
||||
-- -- vim.fn["UltiSnips#Anon"](args.body) -- For `ultisnips` users.
|
||||
-- end,
|
||||
-- },
|
||||
window = {
|
||||
completion = cmp.config.window.bordered(),
|
||||
documentation = cmp.config.window.bordered(),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue