summaryrefslogtreecommitdiff
path: root/.config/nvim/plug-config
diff options
context:
space:
mode:
authoraktersnurra <grydholm@kth.se>2021-02-13 23:11:25 +0100
committeraktersnurra <grydholm@kth.se>2021-02-13 23:11:25 +0100
commit8ae928dcb6fc49b805eff0aa0956cd18aa1c3f85 (patch)
treedc0087f4e9a3f6fb1e840546edea36b6d92cc384 /.config/nvim/plug-config
parent35fe0e5db892099cd1cc9f3a7ff298055f92bdc7 (diff)
added some vim plugins
Diffstat (limited to '.config/nvim/plug-config')
-rw-r--r--.config/nvim/plug-config/far.vim9
-rw-r--r--.config/nvim/plug-config/goyo.vim2
-rw-r--r--.config/nvim/plug-config/highlightedyank.vim1
-rw-r--r--.config/nvim/plug-config/quickscope.vim6
-rw-r--r--.config/nvim/plug-config/rust.vim5
-rw-r--r--.config/nvim/plug-config/vim-commentary.vim8
6 files changed, 31 insertions, 0 deletions
diff --git a/.config/nvim/plug-config/far.vim b/.config/nvim/plug-config/far.vim
new file mode 100644
index 0000000..cab863b
--- /dev/null
+++ b/.config/nvim/plug-config/far.vim
@@ -0,0 +1,9 @@
+let g:far#source='rgnvim'
+
+set lazyredraw " improve scrolling performance when navigating through large results
+
+let g:far#window_width=50
+" Use %:p with buffer option only
+let g:far#file_mask_favorites=['%:p', '**/*.*', '**/*.js', '**/*.py', '**/*.java', '**/*.css', '**/*.html', '**/*.vim', '**/*.cpp', '**/*.c', '**/*.h', ]
+let g:far#window_min_content_width=30
+let g:far#enable_undo=1
diff --git a/.config/nvim/plug-config/goyo.vim b/.config/nvim/plug-config/goyo.vim
new file mode 100644
index 0000000..cb894f7
--- /dev/null
+++ b/.config/nvim/plug-config/goyo.vim
@@ -0,0 +1,2 @@
+autocmd! User GoyoEnter lua require('galaxyline').disable_galaxyline()
+autocmd! User GoyoLeave lua require('galaxyline').galaxyline_augroup()
diff --git a/.config/nvim/plug-config/highlightedyank.vim b/.config/nvim/plug-config/highlightedyank.vim
new file mode 100644
index 0000000..9a4a4b0
--- /dev/null
+++ b/.config/nvim/plug-config/highlightedyank.vim
@@ -0,0 +1 @@
+let g:highlightedyank_highlight_duration = 500
diff --git a/.config/nvim/plug-config/quickscope.vim b/.config/nvim/plug-config/quickscope.vim
new file mode 100644
index 0000000..7950dc7
--- /dev/null
+++ b/.config/nvim/plug-config/quickscope.vim
@@ -0,0 +1,6 @@
+" Trigger a highlight in the appropriate direction when pressing these keys:
+let g:qs_highlight_on_keys = ['f', 'F', 't', 'T']
+
+highlight QuickScopePrimary guifg='#00C7DF' gui=underline ctermfg=155 cterm=underline
+highlight QuickScopeSecondary guifg='#eF5F70' gui=underline ctermfg=81 cterm=underline
+let g:qs_max_chars=150
diff --git a/.config/nvim/plug-config/rust.vim b/.config/nvim/plug-config/rust.vim
new file mode 100644
index 0000000..3b7519d
--- /dev/null
+++ b/.config/nvim/plug-config/rust.vim
@@ -0,0 +1,5 @@
+if has('macunix')
+ let g:rust_clip_command = 'pbcopy'
+else
+ let g:rust_clip_command = 'xclip -selection clipboard'
+endif
diff --git a/.config/nvim/plug-config/vim-commentary.vim b/.config/nvim/plug-config/vim-commentary.vim
new file mode 100644
index 0000000..b6758b3
--- /dev/null
+++ b/.config/nvim/plug-config/vim-commentary.vim
@@ -0,0 +1,8 @@
+function! Comment()
+ if (mode() == "n" )
+ execute "Commentary"
+ else
+ execute "'<,'>Commentary"
+ endif
+ endfunction
+vnoremap <silent> <space>/ :call Comment()