2022-07-26 11:57:25 +01:00
|
|
|
" set runtimepath^=~/.vim runtimepath+=~/.vim/after
|
|
|
|
" let &packpath = &runtimepath
|
|
|
|
" source ~/.vimrc
|
|
|
|
|
|
|
|
call plug#begin()
|
|
|
|
" The default plugin directory will be as follows:
|
|
|
|
" - Vim (Linux/macOS): '~/.vim/plugged'
|
|
|
|
" - Vim (Windows): '~/vimfiles/plugged'
|
|
|
|
" - Neovim (Linux/macOS/Windows): stdpath('data') . '/plugged'
|
|
|
|
" You can specify a custom plugin directory by passing it as the argument
|
|
|
|
" - e.g. `call plug#begin('~/.vim/plugged')`
|
|
|
|
" - Avoid using standard Vim directory names like 'plugin'
|
|
|
|
|
|
|
|
" Make sure you use single quotes
|
|
|
|
|
2022-09-14 09:39:21 +01:00
|
|
|
Plug 'nvim-lua/plenary.nvim'
|
2022-07-26 11:57:25 +01:00
|
|
|
Plug 'neovim/nvim-lspconfig'
|
|
|
|
Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'}
|
2022-07-27 08:40:33 +01:00
|
|
|
Plug 'sonph/onehalf', {'rtp': 'vim/'}
|
2022-07-26 11:57:25 +01:00
|
|
|
Plug 'mileszs/ack.vim'
|
2022-08-15 15:20:15 +01:00
|
|
|
Plug 'stevearc/aerial.nvim'
|
2022-07-26 11:57:25 +01:00
|
|
|
Plug 'tpope/vim-unimpaired'
|
|
|
|
Plug 'tpope/vim-fugitive'
|
2022-07-26 16:36:14 +01:00
|
|
|
Plug 'tpope/vim-commentary'
|
2022-07-26 11:57:25 +01:00
|
|
|
Plug 'airblade/vim-gitgutter'
|
2022-08-15 15:20:15 +01:00
|
|
|
Plug 'nvim-lualine/lualine.nvim'
|
|
|
|
Plug 'kyazdani42/nvim-web-devicons'
|
2022-07-26 11:57:25 +01:00
|
|
|
Plug 'christoomey/vim-tmux-navigator'
|
2022-08-15 15:20:15 +01:00
|
|
|
Plug 'akinsho/toggleterm.nvim', {'tag' : 'v2.*'}
|
2022-08-09 15:16:37 +01:00
|
|
|
Plug 'hrsh7th/cmp-nvim-lsp'
|
|
|
|
Plug 'hrsh7th/cmp-buffer'
|
|
|
|
Plug 'hrsh7th/cmp-path'
|
|
|
|
Plug 'hrsh7th/cmp-cmdline'
|
|
|
|
Plug 'hrsh7th/nvim-cmp'
|
|
|
|
Plug 'hrsh7th/cmp-vsnip'
|
|
|
|
Plug 'hrsh7th/vim-vsnip'
|
2022-09-14 09:39:21 +01:00
|
|
|
Plug 'nvim-telescope/telescope.nvim', { 'tag': '0.1.0' }
|
|
|
|
Plug 'nvim-telescope/telescope-fzf-native.nvim', { 'do': 'cmake -S. -Bbuild -DCMAKE_BUILD_TYPE=Release && cmake --build build --config Release && cmake --install build --prefix build' }
|
|
|
|
Plug 'rcarriga/nvim-notify'
|
|
|
|
Plug 'michaelb/sniprun', {'do': 'bash install.sh'}
|
2022-07-26 11:57:25 +01:00
|
|
|
|
|
|
|
" Initialize plugin system
|
|
|
|
call plug#end()
|
|
|
|
|
2022-07-27 08:40:33 +01:00
|
|
|
set mouse=nv
|
2022-08-04 14:53:09 +01:00
|
|
|
let g:python3_host_prog = '~/.pyenv/versions/neovim3/bin/python'
|
2022-07-26 11:57:25 +01:00
|
|
|
|
2022-08-15 15:20:15 +01:00
|
|
|
luafile ~/.vim/init.lua
|
2022-08-04 15:16:20 +01:00
|
|
|
luafile ~/.vim/lsp_config.lua
|
2022-07-26 11:57:25 +01:00
|
|
|
|
|
|
|
if executable('ag')
|
|
|
|
let g:ackprg = 'ag --vimgrep'
|
|
|
|
endif
|
|
|
|
|
2022-09-06 14:51:41 +01:00
|
|
|
if exists('+termguicolors')
|
2022-07-26 11:57:25 +01:00
|
|
|
set termguicolors
|
|
|
|
endif
|
2022-07-27 08:40:33 +01:00
|
|
|
colorscheme onehalfdark
|
2022-07-26 11:57:25 +01:00
|
|
|
|
|
|
|
set cursorline
|
2022-09-16 10:24:57 +01:00
|
|
|
let mapleader="\\"
|
2022-07-26 11:57:25 +01:00
|
|
|
|
|
|
|
set number
|
|
|
|
set relativenumber
|
|
|
|
set listchars=trail:.,tab:>_
|
|
|
|
set list
|
|
|
|
set wrap
|
|
|
|
set linebreak
|
|
|
|
set autoread
|
|
|
|
|
|
|
|
au BufRead,BufNewFile *.ipynb setlocal filetype=json
|
|
|
|
au BufRead,BufNewFile *.md setlocal spell
|
|
|
|
au BufRead,BufNewFile *.code-workspace setlocal filetype=json
|
|
|
|
au BufRead,BufNewFile *.csv setlocal nowrap
|
|
|
|
au BufRead,BufNewFile *.service[a-zA-Z0-9]* setlocal filetype=systemd
|
|
|
|
au TermOpen * setlocal nonumber norelativenumber
|
|
|
|
syntax on
|
|
|
|
|
|
|
|
if &diff
|
|
|
|
highlight! link DiffText MatchParen
|
|
|
|
endif
|
|
|
|
au OptionSet diff highlight! link DiffText MatchParen
|
|
|
|
|
|
|
|
set expandtab
|
|
|
|
set autoindent
|
|
|
|
set smartindent
|
|
|
|
filetype plugin indent on
|
|
|
|
|
|
|
|
imap jk <Esc>
|
|
|
|
command Bd b# | bd #
|
|
|
|
command! BufOnly silent! execute "%bd|e#|bd#"
|
2022-09-14 10:07:41 +01:00
|
|
|
nnoremap <leader>a :Ack!<Space>
|
|
|
|
nnoremap <leader>sr :SnipRun<cr>
|
2022-09-16 09:47:48 +01:00
|
|
|
nnoremap <leader>; <cmd>Telescope builtin<cr>
|
2022-09-14 09:39:21 +01:00
|
|
|
nnoremap <leader>ff <cmd>Telescope find_files<cr>
|
2022-09-16 09:47:48 +01:00
|
|
|
nnoremap <leader>fr <cmd>Telescope resume<cr>
|
2022-09-14 09:39:21 +01:00
|
|
|
nnoremap <leader>fg <cmd>Telescope live_grep<cr>
|
|
|
|
nnoremap <leader>fb <cmd>Telescope buffers<cr>
|
|
|
|
nnoremap <leader>fh <cmd>Telescope help_tags<cr>
|
|
|
|
nnoremap <leader>fk <cmd>Telescope aerial<cr>
|
|
|
|
nnoremap <leader>fd <cmd>Telescope lsp_document_symbols<cr>
|
2022-09-14 09:49:04 +01:00
|
|
|
nnoremap <leader>fe <cmd>Telescope diagnostics<cr>
|
2022-09-15 10:08:51 +01:00
|
|
|
nnoremap <leader>fn <cmd>Telescope notify<cr>
|
2022-09-16 09:47:48 +01:00
|
|
|
nnoremap <leader>ft <cmd>Telescope treesitter<cr>
|
|
|
|
nnoremap <leader>fz <cmd>Telescope current_buffer_fuzzy_find<cr>
|
2022-07-26 11:57:25 +01:00
|
|
|
|
|
|
|
set splitbelow
|
|
|
|
set splitright
|
|
|
|
|
|
|
|
let g:netrw_list_hide= '\(^\|\s\s\)\zs\.\S\+'
|