vifm: Add alt file opening, option cycling mappings
Added cycling through (command mode) options with C-p/C-n since I am used to doing this. Added a quick short mapping to `o` to show all file openers defined for the current file and be able to select one.
This commit is contained in:
parent
5941f6f77a
commit
80f2afb1cf
1 changed files with 17 additions and 5 deletions
|
@ -1,4 +1,4 @@
|
|||
" vim: filetype=vifm : set foldmethod=marker foldlevel=0 nomodeline:
|
||||
" vim: filetype=vim : set foldmethod=marker foldlevel=0 nomodeline:
|
||||
" Sample configuration file for vifm (last updated: 20 July, 2018)
|
||||
" You can edit this file by hand.
|
||||
" The " character at the beginning of a line comments out the line.
|
||||
|
@ -227,12 +227,15 @@ nmap Q :q<cr>
|
|||
" Sample mappings
|
||||
" for now they use space for my leader key - so we can't switch panels with
|
||||
" space, use tab for that
|
||||
"nnoremap <space> <nop>
|
||||
nnoremap <space><space> <space>
|
||||
nmap <space> <nop>
|
||||
nnoremap <space><space> <nop>
|
||||
|
||||
" switch pane with tab, like cpoption did
|
||||
nnoremap <tab> <c-w>w
|
||||
|
||||
" scroll through command-line options with C-p/C-n
|
||||
cnoremap <c-p> <s-tab>
|
||||
cnoremap <c-n> <tab>
|
||||
|
||||
" Start shell in current directory
|
||||
nnoremap s :shell<cr>
|
||||
|
@ -274,6 +277,9 @@ nnoremap cW cw
|
|||
" esc quits out of preview mode (it does in vim, why not here?)
|
||||
qnoremap <esc> q
|
||||
|
||||
" quickly show alternative file opening applications
|
||||
nnoremap o :file <tab>
|
||||
|
||||
" Select file and jump in the indicated direction
|
||||
nnoremap J tj
|
||||
nnoremap K tk
|
||||
|
@ -361,12 +367,13 @@ source $VIFM/favicons.vifm
|
|||
" program.
|
||||
|
||||
" Pdf
|
||||
filextype *.pdf
|
||||
filextype <application/pdf>,*.pdf
|
||||
\ { view as rich file }
|
||||
\ sioyek %c %i, zathura %c %i &, apvlv %c, xpdf %c,
|
||||
\ { edit text content }
|
||||
\ pdftotext -nopgbrk %c - | nvim
|
||||
fileviewer *.pdf pdftotext -nopgbrk %c -
|
||||
filextype <application/pdf>,*.pdf
|
||||
\ pdftotext -nopgbrk %c -
|
||||
|
||||
" PostScript
|
||||
filextype *.ps,*.eps,*.ps.gz
|
||||
|
@ -458,6 +465,11 @@ filextype *.ora
|
|||
\ {Edit in MyPaint}
|
||||
\ mypaint %f,
|
||||
|
||||
" OpenRaster
|
||||
filetype *.sqlite,*.db
|
||||
\ {Edit in sqlite3}
|
||||
\ sqlite3 %f,
|
||||
|
||||
" tabular data
|
||||
filextype *.csv
|
||||
\ {Open with visidata}
|
||||
|
|
Loading…
Reference in a new issue