xaizek / vifm (License: GPLv2+) (since 2018-12-07)
Vifm is a file manager with curses interface, which provides Vi[m]-like environment for managing objects within file systems, extended with some useful ideas from mutt.
Commit 84f1840c8f273c24a3dd1c6a874d7eda31dcb7d6

Version 0.7.0
Author: xaizek
Author date (UTC): 2011-09-28 20:13
Committer name: xaizek
Committer date (UTC): 2011-09-29 11:07
Parent(s): cf5b6a33f8e353efe79ca5bce71fb32dc1f55e42
Signing key:
Tree: 00324d3babf125e2bae14fc00c6928e9666f93c0
File Lines added Lines deleted
ChangeLog 1 1
INSTALL 6 2
configure 1 1
configure.in 1 1
src/Makefile.win 1 1
src/commands.c 2 0
src/filelist.c 42 20
src/fileops.c 1 1
src/utils.c 17 13
src/vifm-help.txt 172 150
File ChangeLog changed (mode: 100644) (index 79fda32ec..c191e365d)
1 0.6.3 to current
1 0.6.3 to 0.7.0
2 2
3 3 Removed :cmdhistory command. Use :history cmd or :history :. Removed :cmdhistory command. Use :history cmd or :history :.
4 4
File INSTALL changed (mode: 100644) (index d6b145f09..abd1e1b9b)
... ... Windows Installation:
36 36 make -f Makefile.win make -f Makefile.win
37 37
38 38 Copy vifm.exe, vifmrc-converter.exe and win_helper.exe to where you Copy vifm.exe, vifmrc-converter.exe and win_helper.exe to where you
39 want to run them. You will also need to copy vifm help files and
40 vifmrc file to %HOME%/.vifm/ of %APPDATA%/Vifm/.
39 want to run them (but they all should be in the same directory). You will
40 also need to copy vifm help files and vifmrc file to %HOME%/.vifm/ or
41 %APPDATA%/Vifm/.
42
43 In case you want to be able to create symbolic links, you should set a
44 "Run as Administrator" attribute for the win_helper.exe.
41 45
42 46 Vim Specific Options: Vim Specific Options:
43 47
File configure changed (mode: 100755) (index 109006ecc..495c1fd40)
... ... fi
2705 2705
2706 2706 # Define the identity of the package. # Define the identity of the package.
2707 2707 PACKAGE=vifm PACKAGE=vifm
2708 VERSION=0.6.3
2708 VERSION=0.7.0
2709 2709
2710 2710
2711 2711 cat >>confdefs.h <<_ACEOF cat >>confdefs.h <<_ACEOF
File configure.in changed (mode: 100644) (index c282bb5f8..9beb3d98e)
1 1 dnl Process this file with autoconf to produce a configure script. dnl Process this file with autoconf to produce a configure script.
2 2
3 3 AC_INIT(configure.in) AC_INIT(configure.in)
4 AM_INIT_AUTOMAKE(vifm, 0.6.3)
4 AM_INIT_AUTOMAKE(vifm, 0.7.0)
5 5 AM_CONFIG_HEADER(config.h) AM_CONFIG_HEADER(config.h)
6 6
7 7
File src/Makefile.win changed (mode: 100644) (index 42ae0685b..dc6d3aaf4)
... ... $(win_helper_EXECUTABLE): $(win_helper_OBJECTS)
39 39
40 40 config: config:
41 41 if [ ! -f ../config.h ] ; then \ if [ ! -f ../config.h ] ; then \
42 echo '#define VERSION "0.6.3"' > ../config.h; \
42 echo '#define VERSION "0.7.0"' > ../config.h; \
43 43 echo '#define ENABLE_EXTENDED_KEYS' >> ../config.h; \ echo '#define ENABLE_EXTENDED_KEYS' >> ../config.h; \
44 44 # echo '#define ENABLE_COMPATIBILITY_MODE' >> ../config.h; \ # echo '#define ENABLE_COMPATIBILITY_MODE' >> ../config.h; \
45 45 # echo '#define HAVE_FILE_PROG' >> ../config.h; \ # echo '#define HAVE_FILE_PROG' >> ../config.h; \
File src/commands.c changed (mode: 100644) (index 3dd4622fb..358227424)
... ... cd(FileView *view, const char *path)
2560 2560 #else #else
2561 2561 if(is_path_absolute(arg) && *arg != '/') if(is_path_absolute(arg) && *arg != '/')
2562 2562 snprintf(dir, sizeof(dir), "%s", arg); snprintf(dir, sizeof(dir), "%s", arg);
2563 else if(*arg == '/' && is_unc_root(arg))
2564 snprintf(dir, sizeof(dir), "%s", arg);
2563 2565 else if(*arg == '/' && is_unc_root(view->curr_dir)) else if(*arg == '/' && is_unc_root(view->curr_dir))
2564 2566 snprintf(dir, sizeof(dir), "%s", view->curr_dir); snprintf(dir, sizeof(dir), "%s", view->curr_dir);
2565 2567 else if(*arg == '/' && is_unc_path(view->curr_dir)) else if(*arg == '/' && is_unc_path(view->curr_dir))
File src/filelist.c changed (mode: 100644) (index 67cb019b0..6969477dd)
... ... find_file_pos_in_list(FileView *view, const char *file)
603 603 int x; int x;
604 604 for(x = 0; x < view->list_rows; x++) for(x = 0; x < view->list_rows; x++)
605 605 { {
606 #ifndef _WIN32
606 607 if(strcmp(view->dir_entry[x].name, file) == 0) if(strcmp(view->dir_entry[x].name, file) == 0)
608 #else
609 if(strcasecmp(view->dir_entry[x].name, file) == 0)
610 #endif
607 611 return x; return x;
608 612 } }
609 613 return -1; return -1;
 
... ... check_view_dir_history(FileView *view)
1060 1064 { {
1061 1065 int x; int x;
1062 1066 int found = 0; int found = 0;
1063 /* -1 is to skip current position, that should be equal to view->curr_dir */
1064 1067 x = view->history_pos; x = view->history_pos;
1065 if(!strcmp(view->history[x].dir, view->curr_dir) &&
1066 !strcmp(view->history[x].file, ""))
1068 if(strcmp(view->history[x].dir, view->curr_dir) == 0 &&
1069 strcmp(view->history[x].file, "") == 0)
1067 1070 x--; x--;
1068 1071 for(; x >= 0; x--) for(; x >= 0; x--)
1069 1072 { {
1070 1073 if(strlen(view->history[x].dir) < 1) if(strlen(view->history[x].dir) < 1)
1071 1074 break; break;
1072 if(!strcmp(view->history[x].dir, view->curr_dir))
1075 if(strcmp(view->history[x].dir, view->curr_dir) == 0)
1073 1076 { {
1074 1077 found = 1; found = 1;
1075 1078 break; break;
 
... ... check_view_dir_history(FileView *view)
1080 1083 pos = find_file_pos_in_list(view, view->history[x].file); pos = find_file_pos_in_list(view, view->history[x].file);
1081 1084 rel_pos = view->history[x].rel_pos; rel_pos = view->history[x].rel_pos;
1082 1085 } }
1086 else if(path_starts_with(view->last_dir, view->curr_dir) &&
1087 strcmp(view->last_dir, view->curr_dir) != 0 &&
1088 strchr(view->last_dir + strlen(view->curr_dir) + 1, '/') == NULL)
1089 {
1090 char buf[NAME_MAX];
1091 strcpy(buf, view->last_dir + strlen(view->curr_dir));
1092 strcat(buf, "/");
1093
1094 pos = find_file_pos_in_list(view, buf);
1095 rel_pos = -1;
1096 }
1083 1097 else else
1084 1098 { {
1085 1099 view->list_pos = 0; view->list_pos = 0;
 
... ... handle_mount_points(const char *path)
1364 1378 HANDLE hfile; HANDLE hfile;
1365 1379 char rdb[2048]; char rdb[2048];
1366 1380 char *t; char *t;
1381 REPARSE_DATA_BUFFER *rdbp;
1367 1382
1368 1383 attr = GetFileAttributes(path); attr = GetFileAttributes(path);
1369 1384 if(attr == INVALID_FILE_ATTRIBUTES) if(attr == INVALID_FILE_ATTRIBUTES)
 
... ... handle_mount_points(const char *path)
1397 1412 } }
1398 1413 CloseHandle(hfile); CloseHandle(hfile);
1399 1414
1400 t = to_multibyte(
1401 ((REPARSE_DATA_BUFFER *)rdb)->MountPointReparseBuffer.PathBuffer);
1415 rdbp = (REPARSE_DATA_BUFFER *)rdb;
1416 t = to_multibyte(rdbp->MountPointReparseBuffer.PathBuffer);
1402 1417 if(strncmp(t, "\\??\\", 4) == 0) if(strncmp(t, "\\??\\", 4) == 0)
1403 1418 strcpy(buf, t + 4); strcpy(buf, t + 4);
1404 1419 else else
 
... ... static void
1698 1713 fill_with_shared(FileView *view) fill_with_shared(FileView *view)
1699 1714 { {
1700 1715 NET_API_STATUS res; NET_API_STATUS res;
1716 wchar_t *wserver;
1717
1718 wserver = to_wide(view->curr_dir + 2);
1719 if(wserver == NULL)
1720 {
1721 (void)show_error_msg("Memory Error", "Unable to allocate enough memory");
1722 return;
1723 }
1701 1724
1702 1725 view->list_rows = 0; view->list_rows = 0;
1703 1726 do do
1704 1727 { {
1705 PSHARE_INFO_502 buf_ptr;
1728 PSHARE_INFO_0 buf_ptr;
1706 1729 DWORD er = 0, tr = 0, resume = 0; DWORD er = 0, tr = 0, resume = 0;
1707 wchar_t *wserver = to_wide(view->curr_dir + 2);
1708 1730
1709 if(wserver == NULL)
1710 {
1711 (void)show_error_msg("Memory Error", "Unable to allocate enough memory");
1712 return;
1713 }
1714
1715 res = NetShareEnum(wserver, 502, (LPBYTE *)&buf_ptr, -1, &er, &tr, &resume);
1716 free(wserver);
1731 res = NetShareEnum(wserver, 0, (LPBYTE *)&buf_ptr, -1, &er, &tr, &resume);
1717 1732 if(res == ERROR_SUCCESS || res == ERROR_MORE_DATA) if(res == ERROR_SUCCESS || res == ERROR_MORE_DATA)
1718 1733 { {
1719 PSHARE_INFO_502 p;
1734 PSHARE_INFO_0 p;
1720 1735 DWORD i; DWORD i;
1721 1736
1722 1737 p = buf_ptr; p = buf_ptr;
1723 1738 for(i = 1; i <= er; i++) for(i = 1; i <= er; i++)
1724 1739 { {
1725 1740 char buf[512]; char buf[512];
1726 WideCharToMultiByte(CP_ACP, 0, (LPCWSTR)p->shi502_netname, -1, buf,
1741 WideCharToMultiByte(CP_ACP, 0, (LPCWSTR)p->shi0_netname, -1, buf,
1727 1742 sizeof(buf), NULL, NULL); sizeof(buf), NULL, NULL);
1728 1743 if(!ends_with(buf, "$")) if(!ends_with(buf, "$"))
1729 1744 { {
 
... ... fill_with_shared(FileView *view)
1773 1788 } }
1774 1789 } }
1775 1790 while(res == ERROR_MORE_DATA); while(res == ERROR_MORE_DATA);
1791
1792 free(wserver);
1776 1793 } }
1777 1794 #endif #endif
1778 1795
 
... ... is_win_symlink(DWORD attr, DWORD tag)
1790 1807 static int static int
1791 1808 fill_dir_list(FileView *view) fill_dir_list(FileView *view)
1792 1809 { {
1810 view->matches = 0;
1811
1793 1812 #ifndef _WIN32 #ifndef _WIN32
1794 1813 DIR *dir; DIR *dir;
1795 1814 struct dirent *d; struct dirent *d;
 
... ... fill_dir_list(FileView *view)
1932 1951 if(is_unc_root(view->curr_dir)) if(is_unc_root(view->curr_dir))
1933 1952 { {
1934 1953 fill_with_shared(view); fill_with_shared(view);
1935 return 0;
1954 if(view->list_rows > 0)
1955 return 0;
1956 else
1957 return -1;
1936 1958 } }
1937 1959
1938 1960 snprintf(buf, sizeof(buf), "%s/*", view->curr_dir); snprintf(buf, sizeof(buf), "%s/*", view->curr_dir);
 
... ... load_dir_list(FileView *view, int reload)
2086 2108
2087 2109 if(fill_dir_list(view) != 0) if(fill_dir_list(view) != 0)
2088 2110 { {
2089 /* we don't have read access, only execute */
2111 /* we don't have read access, only execute, or there are other problems */
2090 2112 load_parent_dir_only(view); load_parent_dir_only(view);
2091 2113 } }
2092 2114
File src/fileops.c changed (mode: 100644) (index cc4066eb7..d7fe18389)
... ... calc_dirsize(const char *path, int force_update)
2390 2390 else if(strcmp(dentry->d_name, "..") == 0) else if(strcmp(dentry->d_name, "..") == 0)
2391 2391 continue; continue;
2392 2392
2393 snprintf(buf, sizeof (buf), "%s%s%s", path, slash, dentry->d_name);
2393 snprintf(buf, sizeof(buf), "%s%s%s", path, slash, dentry->d_name);
2394 2394 #ifndef _WIN32 #ifndef _WIN32
2395 2395 if(dentry->d_type == DT_DIR) if(dentry->d_type == DT_DIR)
2396 2396 #else #else
File src/utils.c changed (mode: 100644) (index 50802d37f..62ff50d81)
... ... path_starts_with(const char *path, const char *begin)
570 570 if(len > 0 && begin[len - 1] == '/') if(len > 0 && begin[len - 1] == '/')
571 571 len--; len--;
572 572
573 #ifndef _WIN32
573 574 if(strncmp(path, begin, len) != 0) if(strncmp(path, begin, len) != 0)
575 #else
576 if(strncasecmp(path, begin, len) != 0)
577 #endif
574 578 return 0; return 0;
575 579
576 580 return (path[len] == '\0' || path[len] == '/'); return (path[len] == '\0' || path[len] == '/');
 
... ... replace_home_part(const char *directory)
953 957 char * char *
954 958 expand_tilde(char *path) expand_tilde(char *path)
955 959 { {
960 #ifndef _WIN32
956 961 char name[NAME_MAX]; char name[NAME_MAX];
957 962 char *p, *result; char *p, *result;
958 #ifndef _WIN32
959 963 struct passwd *pw; struct passwd *pw;
960 964 #endif #endif
961 965
 
... ... readlink(const char *path, char *buf, size_t len)
1341 1345 char * char *
1342 1346 realpath(const char *path, char *buf) realpath(const char *path, char *buf)
1343 1347 { {
1344 if(get_link_target(path, buf, PATH_MAX) != 0)
1348 if(get_link_target(path, buf, PATH_MAX) == 0)
1349 return buf;
1350
1351 buf[0] = '\0';
1352 if(!is_path_absolute(path) && GetCurrentDirectory(PATH_MAX, buf) > 0)
1345 1353 { {
1346 1354 int i; int i;
1347 1355
1348 buf[0] = '\0';
1349 if(GetCurrentDirectory(PATH_MAX, buf) > 0)
1356 for(i = 0; buf[i] != '\0'; i++)
1350 1357 { {
1351 for(i = 0; buf[i] != '\0'; i++)
1352 {
1353 if(buf[i] == '\\')
1354 buf[i] = '/';
1355 }
1356
1357 chosp(buf);
1358 strcat(buf, "/");
1358 if(buf[i] == '\\')
1359 buf[i] = '/';
1359 1360 } }
1360 1361
1361 strcat(buf, path);
1362 chosp(buf);
1363 strcat(buf, "/");
1362 1364 } }
1365
1366 strcat(buf, path);
1363 1367 return buf; return buf;
1364 1368 } }
1365 1369
File src/vifm-help.txt changed (mode: 100644) (index 0f5e42c3d..1eedc695e)
... ... Other Normal Mode Keys
228 228 gf find link destination (like l with 'followlinks' off, but also gf find link destination (like l with 'followlinks' off, but also
229 229 finds directories). finds directories).
230 230
231 gl only for MS-Windows
232 same as l key, but tries to run program with administrative
233 privileges.
234
231 235 gv go to visual mode restoring last selection. gv go to visual mode restoring last selection.
232 236
233 237 gs restore last t selection, like gv for visual mode selection. gs restore last t selection, like gv for visual mode selection.
 
... ... Other Normal Mode Keys
264 268 [count]dd or d[count]selector if compatibility mode is off [count]dd or d[count]selector if compatibility mode is off
265 269
266 270 [count]dd if compatibility mode is on [count]dd if compatibility mode is on
267 moves the selected files to the trash directory (if option
271 moves the selected files to the trash directory (if option
268 272 'trash' is set otherwise delete) 'trash' is set otherwise delete)
269 273
270 274 [count]DD or D[count]selector [count]DD or D[count]selector
 
... ... Other Normal Mode Keys
277 281
278 282 Y same as yy. Y same as yy.
279 283
280 p will copy the yanked files to the current directory or move the
281 files to the current directory if they were deleted with dd or
284 p will copy the yanked files to the current directory or move the
285 files to the current directory if they were deleted with dd or
282 286 :d[elete] or if the files were yanked from the Trash directory. :d[elete] or if the files were yanked from the Trash directory.
283 287
284 P moves the last yanked files. The advantage of using P instead
285 of d followed by p is that P moves files only once. This isn't
286 important in case you're moving files in the same file system
287 where your home directory is, but using P to move files on some
288 other file system (or file systems, in case you want to move
289 files from fs1 to fs2 and your home is on fs3) can save your
288 P moves the last yanked files. The advantage of using P instead
289 of d followed by p is that P moves files only once. This isn't
290 important in case you're moving files in the same file system
291 where your home directory is, but using P to move files on some
292 other file system (or file systems, in case you want to move
293 files from fs1 to fs2 and your home is on fs3) can save your
290 294 time. time.
291 295
292 296 al puts symbolic links with absolute paths. al puts symbolic links with absolute paths.
 
... ... Using Count
318 322 Or you can use count with motions passed to y, d or D. Or you can use count with motions passed to y, d or D.
319 323
320 324 d[count]j d[count]j
321 delete (count + 1) files starting from current cursor position
325 delete (count + 1) files starting from current cursor position
322 326 upward. upward.
323 327
324 328 Registers Registers
325 vifm supports multiple registers for temporary storing list of yanked
329 vifm supports multiple registers for temporary storing list of yanked
326 330 or deleted files. or deleted files.
327 331
328 332 Registers should be specified with hitting double quite key followed by Registers should be specified with hitting double quite key followed by
329 a register name. Count is specified after register name. By default
333 a register name. Count is specified after register name. By default
330 334 commands use unnamed register, which has double quote as its name. commands use unnamed register, which has double quote as its name.
331 335
332 Though all commands accept registers, most of commands ignores them
333 (for example H or Ctrl-U). Other commands can fill register or append
336 Though all commands accept registers, most of commands ignores them
337 (for example H or Ctrl-U). Other commands can fill register or append
334 338 new files to it. new files to it.
335 339
336 340 Presently vifm supports ", _, a-z and A-Z characters as register names. Presently vifm supports ", _, a-z and A-Z characters as register names.
337 341
338 342 As mentioned above " is unnamed register and has special meaning of the As mentioned above " is unnamed register and has special meaning of the
339 default register. Every time when you use named registers (a-z and A-
340 Z) unnamed register is updated to contain same list of files as the
343 default register. Every time when you use named registers (a-z and A-
344 Z) unnamed register is updated to contain same list of files as the
341 345 last used register. last used register.
342 346
343 _ is black hole register. It can be used for writing, but its list is
347 _ is black hole register. It can be used for writing, but its list is
344 348 always empty. always empty.
345 349
346 350 Registers with names from a to z and from A to Z are named ones. Low‐ Registers with names from a to z and from A to Z are named ones. Low‐
347 ercase registers are cleared before adding new files, while uppercase
351 ercase registers are cleared before adding new files, while uppercase
348 352 aren't and should be used to append new files to the existing file list aren't and should be used to append new files to the existing file list
349 353 of appropriate lowercase register (A for a, B for b, ...). of appropriate lowercase register (A for a, B for b, ...).
350 354
351 Registers can be changed on :empty command if they contain files under
355 Registers can be changed on :empty command if they contain files under
352 356 Trash directory. Trash directory.
353 357
354 358 Registers do not contain one file more than once. Registers do not contain one file more than once.
355 359
356 360 Example: Example:
357 361 "a2yy "a2yy
358 will put names of two files to register a (and to the unnamed regis‐
362 will put names of two files to register a (and to the unnamed regis‐
359 363 ter). ter).
360 364 "Ad "Ad
361 will remove one file and append its name to register a (and to the
365 will remove one file and append its name to register a (and to the
362 366 unnamed register). unnamed register).
363 367 p or "ap or "Ap p or "ap or "Ap
364 368 will insert previously yanked and deleted files into current directory. will insert previously yanked and deleted files into current directory.
 
... ... Registers
366 370 Selectors Selectors
367 371 y and d commands accept selectors. You can combine them with every of y and d commands accept selectors. You can combine them with every of
368 372 selectors below to quickly remove or yank several files. selectors below to quickly remove or yank several files.
369 Most of selectors are like vi motions: j, k, gg, G, H, L, M, %,
373 Most of selectors are like vi motions: j, k, gg, G, H, L, M, %,
370 374 f, F, ;, comma and '. But there are some additional ones. f, F, ;, comma and '. But there are some additional ones.
371 375
372 376 a all files in current view. a all files in current view.
 
... ... Visual Mode
387 391
388 392 V leave visual mode. V leave visual mode.
389 393
390 : enter command line mode. When you leave it selection will be
394 : enter command line mode. When you leave it selection will be
391 395 cleared. cleared.
392 396
393 397 o switch active selection bound. o switch active selection bound.
 
... ... Visual Mode
399 403 gU, U make names of selected files uppercase. gU, U make names of selected files uppercase.
400 404
401 405 Command line Mode Command line Mode
402 This keys apply to all submodes of the command line mode: command,
406 This keys apply to all submodes of the command line mode: command,
403 407 prompt and search. prompt and search.
404 408
405 Down, Up, Left, Right, Home, End and Delete are extended keys and they
406 are not available if vifm is compiled with --disable-extended-keys
409 Down, Up, Left, Right, Home, End and Delete are extended keys and they
410 are not available if vifm is compiled with --disable-extended-keys
407 411 option option
408 412
409 413 Esc, Ctrl-C Esc, Ctrl-C
 
... ... Command line Mode
422 426
423 427 Ctrl-K remove characters from cursor position till the end of line. Ctrl-K remove characters from cursor position till the end of line.
424 428
425 Ctrl-U remove characters from cursor position till the beginning of
429 Ctrl-U remove characters from cursor position till the beginning of
426 430 line. line.
427 431
428 432 Ctrl-H, Backspace Ctrl-H, Backspace
 
... ... Command line Mode
447 451
448 452 Alt-F go to the end of next word. Alt-F go to the end of next word.
449 453
450 Ctrl-W remove characters from cursor position till the beginning of
454 Ctrl-W remove characters from cursor position till the beginning of
451 455 previous word. previous word.
452 456
453 Alt-D remove characters from cursor position till the beginning of
457 Alt-D remove characters from cursor position till the beginning of
454 458 next word. next word.
455 459
456 460 Ctrl-N recall more recent command-line from history. Ctrl-N recall more recent command-line from history.
 
... ... Command line Mode
460 464 Up recall more recent command-line from history, that begins as the Up recall more recent command-line from history, that begins as the
461 465 current command-line. current command-line.
462 466
463 Down recall older command-line from history, that begins as the cur‐
467 Down recall older command-line from history, that begins as the cur‐
464 468 rent command-line. rent command-line.
465 469
466 470 Commands Commands
467 471 Commands are executed with :command_name<Return> Commands are executed with :command_name<Return>
468 472
469 473 ´|' can be used to separate commands, so you can give multiple commands ´|' can be used to separate commands, so you can give multiple commands
470 in one line. If you want to use '|' in an argument, precede it with
474 in one line. If you want to use '|' in an argument, precede it with
471 475 '\'. '\'.
472 476
473 Commented out lines should start with the double quote symbol, which
477 Commented out lines should start with the double quote symbol, which
474 478 may be preceded by whitespace characters. may be preceded by whitespace characters.
475 479
476 480 :[count] :[count]
 
... ... Commands
482 486 :$ move to the bottom of the list. :$ move to the bottom of the list.
483 487
484 488 :[count]command :[count]command
485 The only builtin :[count]command are :[count]d[elete] and
489 The only builtin :[count]command are :[count]d[elete] and
486 490 :[count]y[ank]. :[count]y[ank].
487 491
488 :d3 would delete three files starting at the current file position
492 :d3 would delete three files starting at the current file position
489 493 moving down. moving down.
490 494
491 495 :3d would delete one file at the third line in the list. :3d would delete one file at the third line in the list.
 
... ... Commands
499 503
500 504 will run the process in the background using vifm's means. will run the process in the background using vifm's means.
501 505
502 Programs that write to stdout like ls will create an error message
506 Programs that write to stdout like ls will create an error message
503 507 showing partial output of the command. showing partial output of the command.
504 508
505 509 Take note of the space before ampersand symbol, if you omit it, command Take note of the space before ampersand symbol, if you omit it, command
 
... ... Commands
508 512 Accepts macros. Accepts macros.
509 513
510 514 :[range]!! <program> :[range]!! <program>
511 is the same as :! but will pause the screen before returning to
515 is the same as :! but will pause the screen before returning to
512 516 Vifm. Vifm.
513 517
514 518 :!! will execute the last command. :!! will execute the last command.
515 519
516 520 :[range]alink[!?] :[range]alink[!?]
517 creates absolute symbolic links of files in directory of other
518 view. With "?" vifm will open vi to edit filenames. "!"
521 creates absolute symbolic links of files in directory of other
522 view. With "?" vifm will open vi to edit filenames. "!"
519 523 forces overwrite. forces overwrite.
520 524
521 525 :[range]alink[!] path :[range]alink[!] path
522 creates absolute symbolic links of files in directory specified
526 creates absolute symbolic links of files in directory specified
523 527 with the path (absolute or relative to directory of other view). with the path (absolute or relative to directory of other view).
524 528 "!" forces overwrite. "!" forces overwrite.
525 529
526 530 :[range]alink[!] name1 name2... :[range]alink[!] name1 name2...
527 creates absolute symbolic links of files in directory of other
528 view giving each next link a corresponding name from the argu‐
531 creates absolute symbolic links of files in directory of other
532 view giving each next link a corresponding name from the argu‐
529 533 ment list. "!" forces overwrite. ment list. "!" forces overwrite.
530 534
531 535 :apropos manpage :apropos manpage
532 will create a menu of items returned by the apropos command.
533 Selecting an item in the menu will open the corresponding man‐
536 will create a menu of items returned by the apropos command.
537 Selecting an item in the menu will open the corresponding man‐
534 538 page. page.
535 539
536 540 :apropos :apropos
 
... ... Commands
544 548 change directory to ~/dir. change directory to ~/dir.
545 549
546 550 :cd /curr/dir /other/dir :cd /curr/dir /other/dir
547 change directory of the current pane to /curr/dir and directory
551 change directory of the current pane to /curr/dir and directory
548 552 of the other pane to /other/dir. When using relative paths vifm of the other pane to /other/dir. When using relative paths vifm
549 assumes that both of them are relative to current directory of
550 current view. Command will not fail if one of directories is
553 assumes that both of them are relative to current directory of
554 current view. Command will not fail if one of directories is
551 555 invalid. Accepts macros. invalid. Accepts macros.
552 556
553 557 :cd! /dir :cd! /dir
 
... ... Commands
562 566
563 567 :[range]chmod[!] arg... :[range]chmod[!] arg...
564 568 only for *nix only for *nix
565 changes permissions for files. See 'man chmod' for arg format.
569 changes permissions for files. See 'man chmod' for arg format.
566 570 "!" means set permissions recursively. "!" means set permissions recursively.
567 571
568 572 :[range]chown :[range]chown
 
... ... Commands
571 575
572 576 :[range]chown [user][:][group] :[range]chown [user][:][group]
573 577 only for *nix only for *nix
574 changes owner and/or group of files. Operates on directories
578 changes owner and/or group of files. Operates on directories
575 579 recursively. recursively.
576 580
577 581 :[range]clone[!?] :[range]clone[!?]
578 clones files in current directory. With "?" vifm will open vi
582 clones files in current directory. With "?" vifm will open vi
579 583 to edit filenames. "!" forces overwrite. to edit filenames. "!" forces overwrite.
580 584
581 585 :[range]clone[!] path :[range]clone[!] path
582 clones files to directory specified with the path (absolute or
586 clones files to directory specified with the path (absolute or
583 587 relative to current directory). "!" forces overwrite. relative to current directory). "!" forces overwrite.
584 588
585 589 :[range]clone[!] name1 name2... :[range]clone[!] name1 name2...
586 clones files in current directory giving each next clone a cor‐
590 clones files in current directory giving each next clone a cor‐
587 591 responding name from the argument list. "!" forces overwrite. responding name from the argument list. "!" forces overwrite.
588 592
589 593 :colo[rscheme]? :colo[rscheme]?
590 594 prints current color scheme name in the status bar. prints current color scheme name in the status bar.
591 595
592 596 :colo[rscheme] :colo[rscheme]
593 gives a menu with a list of available color schemes. You can
594 choose default color scheme here. It will be used for view if
595 no DIRECTORY in colorscheme file fits current path. It's also
596 used to set border color (except view titles) and colors in the
597 gives a menu with a list of available color schemes. You can
598 choose default color scheme here. It will be used for view if
599 no DIRECTORY in colorscheme file fits current path. It's also
600 used to set border color (except view titles) and colors in the
597 601 menus and dialogs. menus and dialogs.
598 602
599 603 :colo[rscheme] color_scheme_name :colo[rscheme] color_scheme_name
 
... ... Commands
613 617
614 618 :com[mand] name action :com[mand] name action
615 619 sets a new user command. sets a new user command.
616 Trying to use a reserved command name will result in an error
620 Trying to use a reserved command name will result in an error
617 621 message. message.
618 622 Use :com[mand]! to overwrite a previously set command. Use :com[mand]! to overwrite a previously set command.
619 Unlike vim user commands do not have to start with a capital
620 letter. User commands are run in a shell by default. To run a
621 command in the background you must set it as a background com‐
623 Unlike vim user commands do not have to start with a capital
624 letter. User commands are run in a shell by default. To run a
625 command in the background you must set it as a background com‐
622 626 mand with & at the end of the commands action (:com rm rm %f &). mand with & at the end of the commands action (:com rm rm %f &).
623 627
624 628 :com[mand] backup /pattern :com[mand] backup /pattern
 
... ... Commands
628 632 will set file name filter. will set file name filter.
629 633
630 634 :[range]co[py][!?] :[range]co[py][!?]
631 copies files to directory of other view. With "?" vifm will
635 copies files to directory of other view. With "?" vifm will
632 636 open vi to edit filenames. "!" forces overwrite. open vi to edit filenames. "!" forces overwrite.
633 637
634 638 :[range]co[py][!] path :[range]co[py][!] path
635 copies files to directory specified with the path (absolute or
639 copies files to directory specified with the path (absolute or
636 640 relative to directory of other view). "!" forces overwrite. relative to directory of other view). "!" forces overwrite.
637 641
638 642 :[range]co[py][!] name1 name2... :[range]co[py][!] name1 name2...
639 copies files to directory of other view giving each next file a
640 corresponding name from the argument list. "!" forces over‐
643 copies files to directory of other view giving each next file a
644 corresponding name from the argument list. "!" forces over‐
641 645 write. write.
642 646
643 647 :[range]d[elete] :[range]d[elete]
 
... ... Commands
653 657 will delete all marks. will delete all marks.
654 658
655 659 :delm[arks] marks ... :delm[arks] marks ...
656 will delete specified marks, each argument is treated as a set
660 will delete specified marks, each argument is treated as a set
657 661 of marks. of marks.
658 662
659 663 :di[splay] :di[splay]
660 664 popup menu with registers content. popup menu with registers content.
661 665
662 666 :di[splay] list ... :di[splay] list ...
663 display the contents of the numbered and named registers that
664 are mentioned in list (for example "az to display "", "a and "z
667 display the contents of the numbered and named registers that
668 are mentioned in list (for example "az to display "", "a and "z
665 669 content). content).
666 670
667 671 :dirs display directory stack. :dirs display directory stack.
 
... ... Commands
671 675 macros. macros.
672 676
673 677 :empty will permanently remove 'rm -fr' files from the Trash directory. :empty will permanently remove 'rm -fr' files from the Trash directory.
674 It will also remove all operations from undolist that have no
675 sense after :empty and remove all records about files in the
678 It will also remove all operations from undolist that have no
679 sense after :empty and remove all records about files in the
676 680 Trash directory from all registers. Trash directory from all registers.
677 681
678 682 :exi[t] :exi[t]
679 683 same as :quit. same as :quit.
680 684
681 685 :f[ile] :f[ile]
682 popup menu of programs set for the file type of the current
683 file. Add ' &' at the end of command to run program in back‐
686 popup menu of programs set for the file type of the current
687 file. Add ' &' at the end of command to run program in back‐
684 688 ground. ground.
685 689
686 690 :filet[ype] pat1,pat2,... def_program,program2,... :filet[ype] pat1,pat2,... def_program,program2,...
687 691 will associate given program list to each of the patterns. Cur‐ will associate given program list to each of the patterns. Cur‐
688 rently only * and ? are treated as special symbols in the pat‐
689 tern. If you need to insert comma into command just double it
692 rently only * and ? are treated as special symbols in the pat‐
693 tern. If you need to insert comma into command just double it
690 694 (",,"). (",,").
691 695
692 696 :filex[type] pat1,pat2,... def_program,program2,... :filex[type] pat1,pat2,... def_program,program2,...
 
... ... Commands
694 698 running in X. In X :filextype is equal to :filetype. running in X. In X :filextype is equal to :filetype.
695 699
696 700 :filev[iewer] pat1,pat2,... command :filev[iewer] pat1,pat2,... command
697 will associate given command as a viewer to each of the pat‐
701 will associate given command as a viewer to each of the pat‐
698 702 terns. Currently only * and ? are treated as special symbols in terns. Currently only * and ? are treated as special symbols in
699 703 the pattern. the pattern.
700 704
701 705 :filter regular_expression_pattern :filter regular_expression_pattern
702 :filter /regular_expression_pattern/ will filter all the files
703 out of the directory listing that match the regular expression.
706 :filter /regular_expression_pattern/ will filter all the files
707 out of the directory listing that match the regular expression.
704 708 Using second variant you can use | symbol without escaping. Add Using second variant you can use | symbol without escaping. Add
705 :filter /.o$ would filter all files ending in .o from the
709 :filter /.o$ would filter all files ending in .o from the
706 710 filelist. filelist.
707 711 Note: vifm uses extended regular expressions. Note: vifm uses extended regular expressions.
708 712
 
... ... Commands
716 720 show current filter value. show current filter value.
717 721
718 722 :[range]fin[d] pattern :[range]fin[d] pattern
719 will show results of find command in the menu. Searches among
723 will show results of find command in the menu. Searches among
720 724 selected files if any. Accepts macros. selected files if any. Accepts macros.
721 725
722 726 :[range]fin[d] -opt... :[range]fin[d] -opt...
723 same as :find above, but user defines all find arguments.
727 same as :find above, but user defines all find arguments.
724 728 Searches among selected files if any. Searches among selected files if any.
725 729
726 730 :[range]fin[d] path -opt... :[range]fin[d] path -opt...
727 same as :find above, but user defines all find arguments.
731 same as :find above, but user defines all find arguments.
728 732 Ignores selection and range. Ignores selection and range.
729 733
730 734 :[range]fin[d] :[range]fin[d]
731 735 repeats last :find command. repeats last :find command.
732 736
733 737 :[range]gr[ep][!] pattern :[range]gr[ep][!] pattern
734 will show results of grep command in the menu. Add "!" to
738 will show results of grep command in the menu. Add "!" to
735 739 search lines that do not match pattern. Searches among selected search lines that do not match pattern. Searches among selected
736 740 files if any and no range given. Ignores binary files. files if any and no range given. Ignores binary files.
737 741
738 742 :[range]gr[ep][!] -opt... :[range]gr[ep][!] -opt...
739 same as :grep above, but user defines all find arguments, which
743 same as :grep above, but user defines all find arguments, which
740 744 are not escaped. Searches among selected files if any. are not escaped. Searches among selected files if any.
741 745
742 746 :[range]gr[ep][!] :[range]gr[ep][!]
743 repeats last :grep command. "!" of this command inverts "!" in
747 repeats last :grep command. "!" of this command inverts "!" in
744 748 repeated command. repeated command.
745 749
746 750 :h[elp] :h[elp]
 
... ... Commands
751 755 to get help on vifm (tab completion works). to get help on vifm (tab completion works).
752 756
753 757 :hi[ghlight] :hi[ghlight]
754 will show information about all highlight groups in the current
758 will show information about all highlight groups in the current
755 759 directory. directory.
756 760
757 761 :hi[ghlight] group-name :hi[ghlight] group-name
758 will show information on given highlight group of the default
762 will show information on given highlight group of the default
759 763 color scheme. color scheme.
760 764
761 765 :hi[ghlight] group-name cterm=style | ctermfg=color | ctermbg=color :hi[ghlight] group-name cterm=style | ctermfg=color | ctermbg=color
762 766 sets style (cterm), foreground (ctermfg) or/and background sets style (cterm), foreground (ctermfg) or/and background
763 (ctermbg) parameters of highlight group of the current default
767 (ctermbg) parameters of highlight group of the current default
764 768 color scheme. color scheme.
765 769
766 770 Available style values (some of them can be combined): Available style values (some of them can be combined):
 
... ... Commands
800 804 - cyan - cyan
801 805 - white - white
802 806
803 Here is the hierarchy of the highlight group, which you need to know
807 Here is the hierarchy of the highlight group, which you need to know
804 808 for using transparency: for using transparency:
805 809 StatusLine StatusLine
806 810 WildMenu WildMenu
 
... ... Commands
820 824 TopLine TopLine
821 825 TopLineSel TopLineSel
822 826
823 "none" means default terminal color for highlight groups at the first
827 "none" means default terminal color for highlight groups at the first
824 828 level of the hierarchy and transparency for all others. level of the hierarchy and transparency for all others.
825 829
826 830 :his[tory] :his[tory]
 
... ... Commands
832 836 i[nput] or @ show prompt history (e.g. on one file renaming). i[nput] or @ show prompt history (e.g. on one file renaming).
833 837 s[earch] or / show search history and search forward on l key. s[earch] or / show search history and search forward on l key.
834 838 f[search] or / show search history and search forward on l key. f[search] or / show search history and search forward on l key.
835 b[search] or ? show search history and search backward on l
839 b[search] or ? show search history and search backward on l
836 840 key. key.
837 841 c[md] or : show command line history. c[md] or : show command line history.
838 842
 
... ... Commands
845 849 :jobs shows menu of current backgrounded processes. :jobs shows menu of current backgrounded processes.
846 850
847 851 :locate filename :locate filename
848 uses the locate command to create a menu of filenames Selecting
849 a file from the menu will reload the current file list in vifm
852 uses the locate command to create a menu of filenames Selecting
853 a file from the menu will reload the current file list in vifm
850 854 to show the selected file. to show the selected file.
851 855
852 856 :locate :locate
853 857 repeats last :locate command. repeats last :locate command.
854 858
855 859 :[range]ma[rk]x[/full/path][filename] :[range]ma[rk]x[/full/path][filename]
856 Set mark x at /full/path and filename. By default current
857 directory is being used. If no filename was given and
858 /full/path is current directory then last file in [range] is
860 Set mark x at /full/path and filename. By default current
861 directory is being used. If no filename was given and
862 /full/path is current directory then last file in [range] is
859 863 used. Using macros is allowed. used. Using macros is allowed.
860 864
861 865 :marks create a popup menu of bookmarks. :marks create a popup menu of bookmarks.
 
... ... Commands
863 867 :marks list ... :marks list ...
864 868 display the contents of the marks that are mentioned in list. display the contents of the marks that are mentioned in list.
865 869
870 :mes[sages]
871 shows previously given messages (up to 50).
872
866 873 :mkdir[!] dir ... :mkdir[!] dir ...
867 creates directories with given names. "!" means make parent
874 creates directories with given names. "!" means make parent
868 875 directories as needed. directories as needed.
869 876
870 877 :[range]m[ove][!?] :[range]m[ove][!?]
 
... ... Commands
872 879 vi to edit filenames. "!" forces overwrite. vi to edit filenames. "!" forces overwrite.
873 880
874 881 :[range]m[ove][!] path :[range]m[ove][!] path
875 moves files to directory specified with the path (absolute or
882 moves files to directory specified with the path (absolute or
876 883 relative to directory of other view). "!" forces overwrite. relative to directory of other view). "!" forces overwrite.
877 884
878 885 :[range]m[ove][!] name1 name2... :[range]m[ove][!] name1 name2...
879 moves files to directory of other view giving each next file a
880 corresponding name from the argument list. "!" forces over‐
886 moves files to directory of other view giving each next file a
887 corresponding name from the argument list. "!" forces over‐
881 888 write. write.
882 889
883 890 :noh[lsearch] :noh[lsearch]
 
... ... Commands
889 896 :popd remove pane directories from stack. :popd remove pane directories from stack.
890 897
891 898 :pushd[!] /curr/dir [/other/dir] :pushd[!] /curr/dir [/other/dir]
892 add pane directories to stack and process arguments like :cd
899 add pane directories to stack and process arguments like :cd
893 900 command. command.
894 901
895 902 :pushd exchanges the top two items of the directory stack. :pushd exchanges the top two items of the directory stack.
 
... ... Commands
908 915 popup menu with registers content. popup menu with registers content.
909 916
910 917 :reg[isters] list ... :reg[isters] list ...
911 display the contents of the numbered and named registers that
912 are mentioned in list (for example "az to display "", "a and "z
918 display the contents of the numbered and named registers that
919 are mentioned in list (for example "az to display "", "a and "z
913 920 content). content).
914 921
915 922 :[range]rename :[range]rename
 
... ... Commands
926 933 will restore file from Trash. Works in trash directory only. will restore file from Trash. Works in trash directory only.
927 934
928 935 :[range]rlink[!?] :[range]rlink[!?]
929 creates relative symbolic links of files in directory of other
930 view. With "?" vifm will open vi to edit filenames. "!"
936 creates relative symbolic links of files in directory of other
937 view. With "?" vifm will open vi to edit filenames. "!"
931 938 forces overwrite. forces overwrite.
932 939
933 940 :[range]rlink[!] path :[range]rlink[!] path
934 creates relative symbolic links of files in directory specified
941 creates relative symbolic links of files in directory specified
935 942 with the path (absolute or relative to directory of other view). with the path (absolute or relative to directory of other view).
936 943 "!" forces overwrite. "!" forces overwrite.
937 944
938 945 :[range]rlink[!] name1 name2... :[range]rlink[!] name1 name2...
939 creates relative symbolic links of files in directory of other
940 view giving each next link a corresponding name from the argu‐
946 creates relative symbolic links of files in directory of other
947 view giving each next link a corresponding name from the argu‐
941 948 ment list. "!" forces overwrite. ment list. "!" forces overwrite.
942 949
943 950 :screen :screen
944 951 toggles whether or not to use the screen program. toggles whether or not to use the screen program.
945 952 The default configuration has the screen option turned off. The The default configuration has the screen option turned off. The
946 screen program uses pseudo terminals to allow multiple windows
947 to be used in the console or in a single xterm. Starting vifm
948 from screen with the screen option turned on will cause vifm to
949 open a new screen window for each new file edited or program
953 screen program uses pseudo terminals to allow multiple windows
954 to be used in the console or in a single xterm. Starting vifm
955 from screen with the screen option turned on will cause vifm to
956 open a new screen window for each new file edited or program
950 957 launched from vifm. launched from vifm.
951 This requires screen version 3.9.9 or newer for the screen -X
958 This requires screen version 3.9.9 or newer for the screen -X
952 959 argument. argument.
953 960
954 961 :screen? :screen?
955 962 shows whether screen program is used. shows whether screen program is used.
956 963
964 :se[t] shows all options that differ from their default value.
965
966 :se[t] all
967 shows all options.
968
957 969 :se[t] opt1=val1 opt2='val2' opt3="val3" ... :se[t] opt1=val1 opt2='val2' opt3="val3" ...
958 970 will set options to given values. will set options to given values.
959 971 You can use following syntax: You can use following syntax:
 
... ... Commands
975 987 - option& - reset option to its default value - option& - reset option to its default value
976 988 - option=x or option:x - set option to x - option=x or option:x - set option to x
977 989 - option+=x - add x to option - option+=x - add x to option
978 - option-=x - remove (or subtract) x from option :sh[ell] will
990 - option-=x - remove (or subtract) x from option :sh[ell] will
979 991 start a shell. start a shell.
980 992
981 993 :sor[t] :sor[t]
 
... ... Commands
985 997 splits the window to show both file directories. splits the window to show both file directories.
986 998
987 999 :sp[lit] path :sp[lit] path
988 splits the window to show both file directories. And changes
1000 splits the window to show both file directories. And changes
989 1001 other pane to path. other pane to path.
990 1002
991 1003 :[range]s[ubstitite]/pattern/string/[flags] :[range]s[ubstitite]/pattern/string/[flags]
992 1004 for each file in range replace a match of pattern with string. for each file in range replace a match of pattern with string.
993 1005
994 String can contain ...9 to link to capture groups (0 - all match, 1 -
1006 String can contain ...9 to link to capture groups (0 - all match, 1 -
995 1007 first group, etc.). first group, etc.).
996 1008
997 1009 Available flags: Available flags:
998 1010
999 - i - ignore case (the 'ignorecase' and 'smartcase' options are not
1011 - i - ignore case (the 'ignorecase' and 'smartcase' options are not
1000 1012 used) used)
1001 1013
1002 - I - don't ignore case (the 'ignorecase' and 'smartcase' options are
1014 - I - don't ignore case (the 'ignorecase' and 'smartcase' options are
1003 1015 not used) not used)
1004 1016
1005 1017 - g - substitute all matches in each file name (each g toggles this) - g - substitute all matches in each file name (each g toggles this)
 
... ... Commands
1008 1020 change the other panel to the current panel directory. change the other panel to the current panel directory.
1009 1021
1010 1022 :touch file... :touch file...
1011 will create files. Aborts on errors and won't update time of exist‐
1023 will create files. Aborts on errors and won't update time of exist‐
1012 1024 ing files. ing files.
1013 1025
1014 1026 :[range]tr/pattern/string/ :[range]tr/pattern/string/
1015 for each file in range transliterate the characters which appear in
1016 pattern to the corresponding character in string. When string is
1027 for each file in range transliterate the characters which appear in
1028 pattern to the corresponding character in string. When string is
1017 1029 shorter than pattern, it's padded with its last character. shorter than pattern, it's padded with its last character.
1018 1030
1019 String can contain ...9 to link to capture groups (0 - all match, 1 -
1031 String can contain ...9 to link to capture groups (0 - all match, 1 -
1020 1032 first group, etc.). first group, etc.).
1021 1033
1022 1034 :undol[ist] :undol[ist]
 
... ... Commands
1036 1048 open appropriate volume in the current pane. open appropriate volume in the current pane.
1037 1049
1038 1050 :w[rite] :w[rite]
1039 write vifminfo file (add ! to force write even if settings
1051 write vifminfo file (add ! to force write even if settings
1040 1052 weren't changed). weren't changed).
1041 1053
1042 1054 :wq same as :quit. :wq same as :quit.
 
... ... Commands
1062 1074
1063 1075
1064 1076 :no[remap] lhs rhs :no[remap] lhs rhs
1065 map the key sequence lhs to {rhs} for normal and visual modes,
1077 map the key sequence lhs to {rhs} for normal and visual modes,
1066 1078 but disallow mapping of rhs. but disallow mapping of rhs.
1067 1079
1068 1080 :no[remap]! lhs rhs :no[remap]! lhs rhs
1069 map the key sequence lhs to {rhs} for command line mode, but
1081 map the key sequence lhs to {rhs} for command line mode, but
1070 1082 disallow mapping of rhs. disallow mapping of rhs.
1071 1083
1072 1084
1073 1085 :cno[remap] lhs rhs :cno[remap] lhs rhs
1074 map the key sequence lhs to {rhs} for command line mode, but
1086 map the key sequence lhs to {rhs} for command line mode, but
1075 1087 disallow mapping of rhs. disallow mapping of rhs.
1076 1088
1077 1089 :nn[oremap] lhs rhs :nn[oremap] lhs rhs
1078 map the key sequence lhs to {rhs} for normal mode, but disallow
1090 map the key sequence lhs to {rhs} for normal mode, but disallow
1079 1091 mapping of rhs. mapping of rhs.
1080 1092
1081 1093 :vn[oremap] lhs rhs :vn[oremap] lhs rhs
1082 map the key sequence lhs to {rhs} for visual mode, but disallow
1094 map the key sequence lhs to {rhs} for visual mode, but disallow
1083 1095 mapping of rhs. mapping of rhs.
1084 1096
1085 1097
 
... ... Ranges
1109 1121
1110 1122 :%delete would delete all files in the directory. :%delete would delete all files in the directory.
1111 1123 :2,4delete would delete the files in the list positions 2 through 4. :2,4delete would delete the files in the list positions 2 through 4.
1112 :.,$delete would delete the files from the current position to the
1124 :.,$delete would delete the files from the current position to the
1113 1125 end end
1114 1126 of the filelist. of the filelist.
1115 1127 :3delete4 would delete the files in the list positions 3, 4, 5, 6. :3delete4 would delete the files in the list positions 3, 4, 5, 6.
 
... ... Command macros
1149 1161
1150 1162 Use %% if you need to put a percent sign in your command. Use %% if you need to put a percent sign in your command.
1151 1163
1152 You can use filename modifiers after %c, %C, %f, %F, %b, %d and %D
1164 You can use filename modifiers after %c, %C, %f, %F, %b, %d and %D
1153 1165 macros. Supported modifiers are: macros. Supported modifiers are:
1154 1166
1155 1167 - :p - full path - :p - full path
 
... ... Command macros
1166 1178
1167 1179 - :e - extension of the filename (last one) - :e - extension of the filename (last one)
1168 1180
1169 - :s?pat?sub? - substitute the first occurrence of pat with sub. You
1181 - :s?pat?sub? - substitute the first occurrence of pat with sub. You
1170 1182 can use any character for '?', but it must not occur in. can use any character for '?', but it must not occur in.
1171 1183
1172 - :gs?pat?sub? - like :s, but substitutes all occurrences of pat with
1184 - :gs?pat?sub? - like :s, but substitutes all occurrences of pat with
1173 1185 sub. sub.
1174 1186
1175 See ':h filename-modifiers' in Vim's documentation for the detailed
1187 See ':h filename-modifiers' in Vim's documentation for the detailed
1176 1188 description. description.
1177 1189
1178 Using %x means expand corresponding macro escaping all characters
1179 that have special meaning. And %"x means using of double quotes and
1190 Using %x means expand corresponding macro escaping all characters
1191 that have special meaning. And %"x means using of double quotes and
1180 1192 escape only backslash and double quote characters, which is more use‐ escape only backslash and double quote characters, which is more use‐
1181 1193 ful on Windows systems. ful on Windows systems.
1182 1194
1183 1195 Position and quantity (if there is any) of %m, %M, %S or %s macros in Position and quantity (if there is any) of %m, %M, %S or %s macros in
1184 the command is unimportant. All their occurrences will be removed
1196 the command is unimportant. All their occurrences will be removed
1185 1197 from the resulting command. from the resulting command.
1186 1198
1187 %c and %f macros are expanded to file names only, when %C and %F are
1199 %c and %f macros are expanded to file names only, when %C and %F are
1188 1200 expanded to full paths. %f and %F follow this in %b too. expanded to full paths. %f and %F follow this in %b too.
1189 1201
1190 1202 :com move mv %f %D :com move mv %f %D
1191 would set the :move command to move all of the files selected in the
1203 would set the :move command to move all of the files selected in the
1192 1204 current directory to the other directory. current directory to the other directory.
1193 1205
1194 The %a macro will substitute any arguments given in a command into the
1206 The %a macro will substitute any arguments given in a command into the
1195 1207 command. All arguments are considered optional. ":com lsl !!ls -l %a" command. All arguments are considered optional. ":com lsl !!ls -l %a"
1196 1208 will set the lsl command to execute ls -l with or without an argument. will set the lsl command to execute ls -l with or without an argument.
1197 1209
 
... ... Command macros
1201 1213 :lsl filename<Return> :lsl filename<Return>
1202 1214 will list only the given filename. will list only the given filename.
1203 1215
1204 The macros can also be used in directly executing commands. ":!mv %f
1216 The macros can also be used in directly executing commands. ":!mv %f
1205 1217 %D" would move the current directory selected files to the other direc‐ %D" would move the current directory selected files to the other direc‐
1206 1218 tory. tory.
1207 1219
 
... ... Command macros
1214 1226 type: boolean type: boolean
1215 1227 default: true default: true
1216 1228 When disabled vifm will set cursor to the first line in the view When disabled vifm will set cursor to the first line in the view
1217 after :cd and :pushd commands instead of saved cursor position.
1218 Disabling this will also make vifm clear information about cur‐
1229 after :cd and :pushd commands instead of saved cursor position.
1230 Disabling this will also make vifm clear information about cur‐
1219 1231 sor position in the view history on :cd and :pushd commands (and sor position in the view history on :cd and :pushd commands (and
1220 on startup if autochpos is disabled in the vifmrc). l key in
1232 on startup if autochpos is disabled in the vifmrc). l key in
1221 1233 the :history . menu is treated like :cd command. the :history . menu is treated like :cd command.
1222 1234
1223 1235 confirm cf confirm cf
1224 1236 type: boolean type: boolean
1225 1237 default: true default: true
1226 Ask about permanent deletion of files (on D command or on
1238 Ask about permanent deletion of files (on D command or on
1227 1239 undo/redo operation). undo/redo operation).
1228 1240
1229 1241 fastrun fastrun
1230 1242 type: boolean type: boolean
1231 1243 default: false default: false
1232 With this option turned on you can run partially entered com‐
1233 mands with unambiguous beginning using :! (e.g. :!Te instead of
1244 With this option turned on you can run partially entered com‐
1245 mands with unambiguous beginning using :! (e.g. :!Te instead of
1234 1246 :!Terminal or :!Te<tab>). :!Terminal or :!Te<tab>).
1235 1247
1236 1248 followlinks followlinks
 
... ... Command macros
1241 1253 fusehome fusehome
1242 1254 type: string type: string
1243 1255 default: "/tmp/vifm_FUSE/" default: "/tmp/vifm_FUSE/"
1244 Directory to be used as a root dir for FUSE mounts. If you
1245 change this option, vifm won't remount anything. It affects
1256 Directory to be used as a root dir for FUSE mounts. If you
1257 change this option, vifm won't remount anything. It affects
1246 1258 future mounts only. future mounts only.
1247 1259
1248 1260 gdefault gd gdefault gd
 
... ... Command macros
1253 1265 history hi history hi
1254 1266 type: integer type: integer
1255 1267 default: 15 default: 15
1256 Maximum number of directories in the view history and lines in
1268 Maximum number of directories in the view history and lines in
1257 1269 the prompt, command line and search histories. the prompt, command line and search histories.
1258 1270
1259 1271 hlsearch hls hlsearch hls
 
... ... Command macros
1268 1280 ignorecase ic ignorecase ic
1269 1281 type: boolean type: boolean
1270 1282 default: false default: false
1271 Ignore case in search patterns (:substiute, / and ? commands).
1283 Ignore case in search patterns (:substiute, / and ? commands).
1272 1284 It doesn't affect file filtering. It doesn't affect file filtering.
1273 1285
1274 1286 runexec runexec
 
... ... Command macros
1279 1291 scrolloff so scrolloff so
1280 1292 type: int type: int
1281 1293 default: 0 default: 0
1282 Minimal number of screen lines to keep above and below the cur‐
1283 sor. If you want cursor line to always be in the middle of the
1294 Minimal number of screen lines to keep above and below the cur‐
1295 sor. If you want cursor line to always be in the middle of the
1284 1296 view (except at the beginning or end of the file list), set this view (except at the beginning or end of the file list), set this
1285 1297 option to some large value (e.g. 999). option to some large value (e.g. 999).
1286 1298
 
... ... Command macros
1289 1301 default: $SHELL or "sh" or "cmd" (on MS-Windows) default: $SHELL or "sh" or "cmd" (on MS-Windows)
1290 1302 Full path to the shell to use to run external commands. Full path to the shell to use to run external commands.
1291 1303
1304 slowfs type: string list
1305 default: ""
1306 only for *nix
1307 A list of mounter fs name beginnings (first column in /etc/mtab
1308 or /proc/mounts) that work too slow for you. This option can be
1309 used to stop vifm from making some requests to particular kinds
1310 of file systems that can slow down file browsing. Currently
1311 this means don't check if directory has changed and do not check
1312 if target of symbolic links exists.
1313
1292 1314 smartcase scs smartcase scs
1293 1315 type: boolean type: boolean
1294 1316 default: false default: false
 
... ... AUTHOR
1575 1597
1576 1598
1577 1599
1578 September 17, 2011 vifm(1)
1600 September 25, 2011 vifm(1)
Hints

Before first commit, do not forget to setup your git environment:
git config --global user.name "your_name_here"
git config --global user.email "your@email_here"

Clone this repository using HTTP(S):
git clone https://code.reversed.top/user/xaizek/vifm

Clone this repository using ssh (do not forget to upload a key first):
git clone ssh://rocketgit@code.reversed.top/user/xaizek/vifm

You are allowed to anonymously push to this repository.
This means that your pushed commits will automatically be transformed into a pull request:
... clone the repository ...
... make some changes and some commits ...
git push origin master