diff options
-rw-r--r-- | .config/nvim/README.md | 25 | ||||
-rw-r--r-- | .config/nvim/init.vim | 40 | ||||
-rw-r--r-- | .config/nvim/plug-config/barbar.vim | 5 | ||||
-rw-r--r-- | .config/nvim/plug-config/sneak.vim | 4 | ||||
-rw-r--r-- | .config/nvim/plug-config/telescope.vim | 14 | ||||
-rw-r--r-- | .config/nvim/vim-plug/plugins.vim | 24 |
6 files changed, 76 insertions, 36 deletions
diff --git a/.config/nvim/README.md b/.config/nvim/README.md index f67a747..b72af5d 100644 --- a/.config/nvim/README.md +++ b/.config/nvim/README.md @@ -6,29 +6,42 @@ Must have neovim >= 0.5 ## Installation ### Lazy git - +macOS: +``` brew install lazygit +``` +Ubuntu: +``` sudo add-apt-repository ppa:lazygit-team/release sudo apt-get update sudo apt-get install lazygit +``` +Arch: +``` https://aur.archlinux.org/packages/lazygit/ +``` ### Coc-explorer `:CocInstall coc-explorer` ### Ranger - +``` pip3 install ranger-fm pynvim +``` ### fzf -Depending on OS: +macOS: + +`brew install fzf` + +`sudo apt install fzf` -* brew install fzf +`sudo pacman -S fzf` -* sudo apt install fzf +### Treesitter -* sudo pacman -S fzf +`:TSInstall {language}` diff --git a/.config/nvim/init.vim b/.config/nvim/init.vim index c45e5f1..719705d 100644 --- a/.config/nvim/init.vim +++ b/.config/nvim/init.vim @@ -4,38 +4,38 @@ " _/ // / / / / /__| |/ / / / / / / / "/___/_/ /_/_/\__(_)___/_/_/ /_/ /_/ + +"Has to be called first. source $HOME/.config/nvim/plug-config/polyglot.vim + +"General Neovim settings. source $HOME/.config/nvim/vim-plug/plugins.vim source $HOME/.config/nvim/general/settings.vim +"Keybindings. source $HOME/.config/nvim/keys/mappings.vim source $HOME/.config/nvim/keys/which-key.vim - -source $HOME/.config/nvim/plug-config/rnvimr.vim -source $HOME/.config/nvim/plug-config/highlightedyank.vim +" Vim plugin configs. +source $HOME/.config/nvim/plug-config/barbar.vim +source $HOME/.config/nvim/plug-config/coc.vim source $HOME/.config/nvim/plug-config/far.vim -source $HOME/.config/nvim/plug-config/vim-commentary.vim -source $HOME/.config/nvim/plug-config/quickscope.vim -source $HOME/.config/nvim/plug-config/rust.vim +source $HOME/.config/nvim/plug-config/floaterm.vim +"source $HOME/.config/nvim/plug-config/fzf.vim source $HOME/.config/nvim/plug-config/goyo.vim +source $HOME/.config/nvim/plug-config/highlightedyank.vim +source $HOME/.config/nvim/plug-config/quickscope.vim source $HOME/.config/nvim/plug-config/ranger.vim -source $HOME/.config/nvim/plug-config/barbar.vim -source $HOME/.config/nvim/plug-config/floaterm.vim -source $HOME/.config/nvim/plug-config/fzf.vim -source $HOME/.config/nvim/plug-config/vim-rooter.vim - +source $HOME/.config/nvim/plug-config/rnvimr.vim +source $HOME/.config/nvim/plug-config/rust.vim +source $HOME/.config/nvim/plug-config/sneak.vim +source $HOME/.config/nvim/plug-config/start-screen.vim +source $HOME/.config/nvim/plug-config/telescope.vim +luafile $HOME/.config/nvim/lua/statusline.lua +source $HOME/.config/nvim/plug-config/vim-commentary.vim +"source $HOME/.config/nvim/plug-config/vim-rooter.vim " Theme -" source $HOME/.config/nvim/themes/githubsy.vim -" source $HOME/.config/nvim/themes/wal.vim source $HOME/.config/nvim/themes/nord.vim -" source $HOME/.config/nvim/themes/airline.vim -source $HOME/.config/nvim/plug-config/coc.vim - -" luafile $HOME/.config/nvim/lua/plug-colorizer.lua -luafile $HOME/.config/nvim/lua/statusline.lua -source $HOME/.config/nvim/plug-config/start-screen.vim -source $HOME/.config/nvim/plug-config/sneak.vim diff --git a/.config/nvim/plug-config/barbar.vim b/.config/nvim/plug-config/barbar.vim index 57ac470..16c574a 100644 --- a/.config/nvim/plug-config/barbar.vim +++ b/.config/nvim/plug-config/barbar.vim @@ -1,4 +1,5 @@ -let g:bufferline = { 'closable': v:false } +let bufferline = get(g:, 'bufferline', {}) +"let g:bufferline = { 'closable': v:false } " Show a shadow over the editor in buffer-pick mode let bufferline.shadow = v:true @@ -23,7 +24,7 @@ let bufferline.semantic_letters = v:true " optimal for the qwerty keyboard layout but might need adjustement " for other layouts. let bufferline.letters = - \ 'asdfjkl;ghnmxcbziowerutyqpASDFJKLGHNMXCBZIOWERUTYQP' +\ 'asdfjkl;ghnmxcbziowerutyqpASDFJKLGHNMXCBZIOWERUTYQP' let bg_current = get(nvim_get_hl_by_name('Normal', 1), 'background', '#000000') let bg_visible = get(nvim_get_hl_by_name('TabLineSel', 1), 'background', '#000000') diff --git a/.config/nvim/plug-config/sneak.vim b/.config/nvim/plug-config/sneak.vim index febad68..2641dc9 100644 --- a/.config/nvim/plug-config/sneak.vim +++ b/.config/nvim/plug-config/sneak.vim @@ -15,8 +15,8 @@ highlight Sneak guifg=black guibg=#00C7DF ctermfg=black ctermbg=cyan highlight SneakScope guifg=red guibg=yellow ctermfg=red ctermbg=yellow " Cool prompts -let g:sneak#prompt = '🕵️' -" let g:sneak#prompt = '🔎 ' +" let g:sneak#prompt = '🕵️' +let g:sneak#prompt = '🔎 ' " I like quickscope better for this since it keeps me in the scope of a single line " map f <Plug>Sneak_f diff --git a/.config/nvim/plug-config/telescope.vim b/.config/nvim/plug-config/telescope.vim new file mode 100644 index 0000000..26ae819 --- /dev/null +++ b/.config/nvim/plug-config/telescope.vim @@ -0,0 +1,14 @@ +" Find files using Telescope command-line sugar. +nnoremap <Leader>ff <cmd>Telescope find_files<cr> +nnoremap <Leader>fg <cmd>Telescope live_grep<cr> +nnoremap <Leader>fb <cmd>Telescope buffers<cr> +nnoremap <Leader>fh <cmd>Telescope help_tags<cr> + +" Theme +nnoremap <Leader>f :lua require'telescope.builtin'.find_files(require('telescope.themes').get_dropdown({}))<cr> + +" Using lua functions +"nnoremap <leader>ff <cmd>lua require('telescope.builtin').find_files()<cr> +"nnoremap <leader>fg <cmd>lua require('telescope.builtin').live_grep()<cr> +"nnoremap <leader>fb <cmd>lua require('telescope.builtin').buffers()<cr> +"nnoremap <leader>fh <cmd>lua require('telescope.builtin').help_tags()<cr> diff --git a/.config/nvim/vim-plug/plugins.vim b/.config/nvim/vim-plug/plugins.vim index 1d15601..593f88e 100644 --- a/.config/nvim/vim-plug/plugins.vim +++ b/.config/nvim/vim-plug/plugins.vim @@ -34,13 +34,23 @@ call plug#begin('~/.config/nvim/autoload/plugged') Plug 'ap/vim-css-color' " FZF - Plug 'junegunn/fzf', { 'do': { -> fzf#install() } } - Plug 'junegunn/fzf.vim' - Plug 'airblade/vim-rooter' + "Plug 'junegunn/fzf', { 'do': { -> fzf#install() } } + "Plug 'junegunn/fzf.vim' + + "Rooter changes the working directory to the project root when you open a file or directory. + "Plug 'airblade/vim-rooter' + + " Telescope a fuzzy finder + Plug 'nvim-lua/popup.nvim' + Plug 'nvim-lua/plenary.nvim' + Plug 'nvim-telescope/telescope.nvim' " Better tabline Plug 'romgrk/barbar.nvim' - + + " Better scrolling + Plug 'psliwka/vim-smoothie' + " Terminal Plug 'voldikss/vim-floaterm' @@ -54,8 +64,10 @@ call plug#begin('~/.config/nvim/autoload/plugged') " If you want icons use one of these: Plug 'kyazdani42/nvim-web-devicons' " lua Plug 'ryanoasis/vim-devicons' " vimscript - Plug 'kyazdani42/nvim-tree.lua' - + + " Treesitter + Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'} + " Stable version of coc Plug 'neoclide/coc.nvim', {'branch': 'release'} Plug 'honza/vim-snippets' |