3 source ~/.config/vifm/icons
4 " set vicmd=elvis\ -G\ termcap
11 set timefmt=%m/%d\ %H:%M
28 set suggestoptions=normal,visual,view,otherpane,keys,marks,registers
30 set statusline=" Hint: %z%= %A %10u:%-7g %15s %20d "
36 " :mark mark /full/directory/path [filename]
40 " -----------------------------------------------------------------------------
41 " :com[mand][!] command_name action
42 " The following macros can be used in a command
43 " %a is replaced with the user arguments.
44 " %c the current file under the cursor.
45 " %C the current file under the cursor in the other directory.
46 " %f the current selected file, or files.
47 " %F the current selected file, or files in the other directory.
49 " %d the current directory name.
50 " %D the other window directory name.
51 " %m run the command in a menu window
53 command! df df -h %m 2> /dev/null
54 command! diff vim -d %f %F
55 command! unzip unzip %f
57 command! make !!make %a
58 command! mkcd :mkdir %a | cd %a
59 command! vgrep vim "+grep %a"
60 command! reload :write | restart
62 " -----------------------------------------------------------------------------
63 " Default Applications
64 " -----------------------------------------------------------------------------
66 filextype *.pdf mupdf %c %i &, apvlv %c, xpdf %c
67 "fileviewer *.pdf pdftotext -nopgbrk %c -
70 filextype *.ps,*.eps,*.ps.gz
80 filetype *.wav,*.mp3,*.flac,*.m4a,*.wma,*.ape,*.ac3,*.og[agx],*.spx,*.opus
82 fileviewer *.mp3 mp3info
83 fileviewer *.flac soxi
86 filextype *.avi,*.mp4,*.wmv,*.dat,*.3gp,*.ogv,*.mkv,*.mpg,*.mpeg,*.vob,
87 \*.fl[icv],*.m2v,*.mov,*.webm,*.ts,*.mts,*.m4v,*.r[am],*.qt,*.divx,
90 fileviewer *.avi,*.mp4,*.wmv,*.dat,*.3gp,*.ogv,*.mkv,*.mpg,*.mpeg,*.vob,
91 \*.fl[icv],*.m2v,*.mov,*.webm,*.ts,*.mts,*.m4v,*.r[am],*.qt,*.divx,
93 " \ ffprobe -pretty %c 2>&1
97 filextype *.html,*.htm
100 \uzbl-browser %f %i &,
101 filetype *.html,*.htm links, lynx
104 filetype *.o nm %f | less
107 filetype *.[1-8] man ./%c
108 fileviewer *.[1-8] man ./%c | col -b
111 filextype *.bmp,*.jpg,*.jpeg,*.png,*.gif,*.xpm
115 \ vifmimg pdfpreview %px %py %pw %ph %c
120 \ vifmimg epubpreview %px %py %pw %ph %c
124 fileviewer *.bmp,*.jpg,*.jpeg,*.png,*.xpm
125 \ vifmimg draw %px %py %pw %ph %c
130 \ vifmimg gifpreview %px %py %pw %ph %c
135 \ vifmimg magickpreview %px %py %pw %ph %c
157 \ sha256sum -c %f %S,
161 \ sha512sum -c %f %S,
168 filetype *.torrent ktorrent %f &
169 fileviewer *.torrent dumptorrent -v %c
172 filetype *.zip,*.jar,*.war,*.ear,*.oxt,*.apkg
173 \ FUSE_MOUNT|fuse-zip %SOURCE_FILE %DESTINATION_DIR,
176 fileviewer *.zip,*.jar,*.war,*.ear,*.oxt zip -sf %c
179 filetype *.tar,*.tar.bz2,*.tbz2,*.tgz,*.tar.gz,*.tar.xz,*.txz
180 \ FUSE_MOUNT|archivemount %SOURCE_FILE %DESTINATION_DIR,
181 fileviewer *.tgz,*.tar.gz tar -tzf %c
182 fileviewer *.tar.bz2,*.tbz2 tar -tjf %c
183 fileviewer *.tar.txz,*.txz xz --list %c
184 fileviewer *.tar tar -tf %c
186 " Rar2FsMount and rar archives
188 \ FUSE_MOUNT|rar2fs %SOURCE_FILE %DESTINATION_DIR,
189 fileviewer *.rar unrar v %c
193 \ FUSE_MOUNT|fuseiso %SOURCE_FILE %DESTINATION_DIR,
197 \ FUSE_MOUNT2|sshfs %PARAM %DESTINATION_DIR %FOREGROUND,
201 \ FUSE_MOUNT2|curlftpfs -o ftp_port=-,,disable_eprt %PARAM %DESTINATION_DIR %FOREGROUND,
203 " Fuse7z and 7z archives
205 \ FUSE_MOUNT|fuse-7z %SOURCE_FILE %DESTINATION_DIR,
206 fileviewer *.7z 7z l %c
209 filextype *.odt,*.doc,*.docx,*.xls,*.xlsx,*.odp,*.pptx libreoffice %f &
210 fileviewer *.doc catdoc %c
211 fileviewer *.docx docx2txt.pl %f -
214 filetype *.tudu tudu -f %c
217 filextype *.pro qtcreator %f &
223 " ------------------------------------------------------------------------------
225 " set vifminfo=options,filetypes,commands,bookmarks,dhistory,state,cs
226 set vifminfo=dhistory,savedirs,chistory,state,tui,shistory,
227 \phistory,fhistory,dirstack,registers,bookmarks,bmarks
229 "------------------------------------------------------------------------------
231 "------------------------------------------------------------------------------
232 nnoremap s :shell<cr> " Start shell in current directory
233 nnoremap S :sort<cr> " Display sorting dialog
234 nnoremap w :view<cr> " Toggle visibility of preview window
235 vnoremap w :view<cr>gv
236 nnoremap o :!vim %f<cr> " Open file in vim
237 nnoremap gb :file &<cr>l " Open file in the background using its default program
238 nnoremap yd :!echo %d | xclip %i<cr> " Yank current directory path into the clipboard
239 nnoremap yf :!echo %c:p | xclip %i<cr> " Yank current file path into the clipboard
240 nnoremap ,t :!st &<cr> " Open console in current directory
241 nnoremap n :!mpv --vf=sub,lavfi="negate" %f<cr> " mpv invert colors
243 " Mappings for faster renaming
249 " Open editor to edit vifmrc and apply settings after returning to vifm
250 nnoremap ,c :write | edit $MYVIFMRC | restart<cr>
252 " Example of standard two-panel file managers mappings
253 nnoremap <f3> :!less %f<cr>
254 nnoremap <f4> :edit<cr>
255 nnoremap <f5> :copy<cr>
256 nnoremap <f6> :move<cr>
257 nnoremap <f7> :mkdir<space>
258 nnoremap <f8> :delete<cr>