vim & zoxide

This commit is contained in:
foosinn 2022-01-03 16:07:36 +01:00
parent 135c93c226
commit 3c8239a55f
2 changed files with 17 additions and 6 deletions

View file

@ -1,8 +1,12 @@
with import <nixos-unstable> {};
neovim.override {
vimAlias = true;
configure = {
customRC = ''
source ${pkgs.fzf}/share/vim-plugins/fzf/plugin/fzf.vim
set hidden
" langserver
@ -11,7 +15,7 @@ neovim.override {
\ 'python': ['pyls'],
\ 'rust': ['rust-analyzer'],
\ }
" basic builtin
set background=dark
set shiftwidth=4
@ -65,7 +69,8 @@ neovim.override {
let g:which_key_map.f = { 'name': '+files' }
noremap <leader>ff :FZF<cr>
noremap <leader>fc :saveas
noremap <leader>fn :NnnPicker %:p:h<cr>
noremap <leader>fc :saveas %:p:h
let g:which_key_map.y = { 'name': '+yank' }
noremap <leader>yp :read !wl-paste<cr>
@ -79,7 +84,7 @@ neovim.override {
noremap <leader>bn :bn<cr>
noremap <leader>bp :bp<cr>
let g:which_key_map.b = { 'name': '+lang' }
let g:which_key_map.m = { 'name': '+lang' }
noremap <leader>md :call LanguageClient_textDocument_codeAction()<cr>
noremap <leader>mc :call LanguageClient#textDocument_references()<cr>
noremap <leader>mf :call LanguageClient#textDocument_formatting()<cr>
@ -88,6 +93,11 @@ neovim.override {
noremap <leader>mm :call LanguageClient#textDocument_hover()<cr>
noremap <leader>mr :call LanguageClient#textDocument_rename()<cr>
noremap <leader>ms :call LanguageClient#workspace_symbol()<cr>
noremap <leader>ma :fzf_lsp_action<cr>
noremap <leader>ml :fzf_lsp_layout<cr>
let g:which_key_map.g = { 'name': '+git' }
noremap <leader>gs :!lazygit
" lang specifics
let g:rustfmt_autosave = 1
@ -99,10 +109,11 @@ neovim.override {
airline
easymotion
editorconfig-vim
fugitive
fzf
fzf-lsp-nvim
LanguageClient-neovim
ncm2
nnn-vim
surround
syntastic
vim-addon-nix

View file

@ -37,7 +37,7 @@ in {
tmux
unzip
wget
z-lua
zoxide
(import ../packages/neovim.nix)
];
@ -76,7 +76,7 @@ in {
. "$(fzf-share)/key-bindings.bash"
. "$(fzf-share)/completion.bash"
. <(z --init bash)
. <(zoxide init bash)
. <(direnv hook bash)
. ${pkgs.bash-completion}/etc/profile.d/bash_completion.sh