summaryrefslogtreecommitdiff
path: root/vim
diff options
context:
space:
mode:
authorZofia Szweda <sophies@disroot.org>2026-09-05 10:54:53 +0200
committerZofia Szweda <sophies@disroot.org>2026-09-05 10:54:53 +0200
commit1d078c2035636a390cad86e5bb279ce24d5e39e5 (patch)
treefdeef582b4207b1dae0cbb2542ef2382e7573e8a /vim
parent9cdf96247221df026f5df0374403636a95917718 (diff)
vim: add vim-commentary and smarttab
Diffstat (limited to 'vim')
-rw-r--r--vim/.vimrc24
1 files changed, 18 insertions, 6 deletions
diff --git a/vim/.vimrc b/vim/.vimrc
index 6f625c4..fb5c55e 100644
--- a/vim/.vimrc
+++ b/vim/.vimrc
@@ -16,11 +16,15 @@ Plug 'prabirshrestha/asyncomplete-lsp.vim'
Plug 'tpope/vim-vinegar'
Plug 'ap/vim-buftabline'
Plug 'sheerun/vim-polyglot'
+Plug 'tpope/vim-commentary'
Plug 'kalbasit/vim-colemak'
call plug#end()
+syntax on
+"filetype
filetype on
filetype indent on
filetype plugin on
+"set
set nocompatible
set fileformat=unix
set encoding=UTF-8
@@ -29,8 +33,8 @@ set rnu
set expandtab
set tabstop=4
set shiftwidth=4
+set smarttab
set smartindent
-syntax on
set noswapfile
set incsearch
set ignorecase
@@ -47,23 +51,25 @@ set undofile
set undodir=~/.vim/undodir
set signcolumn=yes
set shortmess+=c
+" etc
colorscheme flatwhite
-let mapleader = "\<Space>"
nnoremap <Space> <Nop>
nnoremap <silent> <leader> :WhichKey '<Space>'<CR>
inoremap <silent> <Esc> <Esc>l
+autocmd FileType html,css EmmetInstall
+"let
+let mapleader = "\<Space>"
let g:buftabline_show = 2
let g:buftabline_numbers = 1
let g:user_emmet_leader_key='<Space>'
let g:user_emmet_mode='n'
let g:user_emmet_install_global = 0
-autocmd FileType html,css EmmetInstall
let g:lightline = {
\ 'colorscheme': 'one',
\ 'background': 'light',
\ }
-let g:loaded_newtrw = 1
-let g:loaded_newtrwPlugin = 1
+let g:loaded_netrw = 1
+let g:loaded_netrwPlugin = 1
let g:which_key_map = {}
let g:which_key_map.f = ['Files', 'file buffer']
let g:which_key_map.b = {
@@ -82,7 +88,13 @@ if executable('pylsp')
\ 'allowlist': ['python'],
\ })
endif
-
+if executable('pylsp')
+ au User lsp_setup call lsp#register_server({
+ \ 'name': 'clangd',
+ \ 'cmd': {server_info->['clangd']},
+ \ 'allowlist': ['c' 'cpp'],
+ \})
+endif
function! s:on_lsp_buffer_enabled() abort
setlocal omnifunc=lsp#complete
setlocal signcolumn=yes