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 50c6469988dcbc3de532ead3db679e8852023c45

Use {...} for descriptions in :file{,type,xtype}
This makes it consistent with the syntax of :filetype and makes
[present] mark and descriptions visually different.
Author: xaizek
Author date (UTC): 2025-06-07 16:10
Committer name: xaizek
Committer date (UTC): 2025-06-12 17:10
Parent(s): 365b2c4a11b10138a6e43a14cfd8a5478e6ea570
Signing key: 99DC5E4DB05F6BE2
Tree: 923bcd90cfa85e09d2f6eab8db9c4c36461a9d5e
File Lines added Lines deleted
ChangeLog 3 0
src/menus/filetypes_menu.c 1 1
tests/menus/filetypes.c 1 1
File ChangeLog changed (mode: 100644) (index 9843b0e0c..7188243b5)
34 34
35 35 Improved documentation on the use registers. Thanks to aleksejrs. Improved documentation on the use registers. Thanks to aleksejrs.
36 36
37 Display descriptions as "{...}" rather than "[...]" in :file and
38 :file[x]type menus.
39
37 40 Fixed 'trashdir' with "%r" on BSD-like systems (those with getmntinfo() Fixed 'trashdir' with "%r" on BSD-like systems (those with getmntinfo()
38 41 instead of getmntent() API). The regression was apparently introduced in instead of getmntent() API). The regression was apparently introduced in
39 42 v0.9.1-beta. Thanks to sublimal. v0.9.1-beta. Thanks to sublimal.
File src/menus/filetypes_menu.c changed (mode: 100644) (index 90adc5f0a..7872196b3)
... ... form_filetype_menu_entry(assoc_record_t prog, int descr_width)
131 131 } }
132 132 else else
133 133 { {
134 snprintf(format, sizeof(format), "[%%-%ds] ", descr_width);
134 snprintf(format, sizeof(format), "{%%-%ds} ", descr_width);
135 135 } }
136 136 snprintf(descr, sizeof(descr), format, prog.description); snprintf(descr, sizeof(descr), format, prog.description);
137 137 } }
File tests/menus/filetypes.c changed (mode: 100644) (index cea1d2430..316d0c7eb)
... ... TEST(pseudo_entry_is_always_present_for_directories)
121 121 assert_success(cmds_dispatch("filetype bla-dir/", &lwin, CIT_COMMAND)); assert_success(cmds_dispatch("filetype bla-dir/", &lwin, CIT_COMMAND));
122 122
123 123 assert_int_equal(2, menu_get_current()->len); assert_int_equal(2, menu_get_current()->len);
124 assert_string_equal("[present] [Enter directory] " VIFM_PSEUDO_CMD,
124 assert_string_equal("[present] {Enter directory} " VIFM_PSEUDO_CMD,
125 125 menu_get_current()->items[0]); menu_get_current()->items[0]);
126 126 assert_string_equal("[present] abc-run %c", assert_string_equal("[present] abc-run %c",
127 127 menu_get_current()->items[1]); menu_get_current()->items[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