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 b0f15ecec20af464a6185f1ad8ebfac6389f62ce

Fix ' & " not escaped on option value completion
That is via `opt=<tab>` when current value is inserted.
Author: xaizek
Author date (UTC): 2025-01-29 13:02
Committer name: xaizek
Committer date (UTC): 2025-02-01 11:36
Parent(s): e601d15ceb07fa89484fe10f55b709415dc8c2e0
Signing key: 99DC5E4DB05F6BE2
Tree: a2900019ff0182d560c3560b1cbbe0152a81d3d2
File Lines added Lines deleted
ChangeLog 3 0
src/engine/options.c 1 1
tests/options/opt_completion.c 9 0
File ChangeLog changed (mode: 100644) (index c85f7191f..082c0dc4c)
11 11 Fixed single quotes escaping for completion of option values via Fixed single quotes escaping for completion of option values via
12 12 `opt='<tab>` (related to a change in 0.14-beta). `opt='<tab>` (related to a change in 0.14-beta).
13 13
14 Fixed quotes not being escaped on completion of option values via
15 `opt=<tab>`.
16
14 17 0.13 to 0.14-beta (2025-01-19) 0.13 to 0.14-beta (2025-01-19)
15 18
16 19 Changed --with-gtk flag to --with-glib (old name is still available). GTK Changed --with-gtk flag to --with-glib (old name is still available). GTK
File src/engine/options.c changed (mode: 100644) (index d83615761..2bac0bf0e)
... ... vle_opts_complete(const char args[], const char **start, OPT_SCOPE scope)
1406 1406
1407 1407 if(*p == '\0') if(*p == '\0')
1408 1408 { {
1409 vle_compl_put_match(escape_chars(str_val, " |\\"), "");
1409 vle_compl_put_match(escape_chars(str_val, " |\\'\""), "");
1410 1410 } }
1411 1411 else if(strcmp(p, "'") == 0) else if(strcmp(p, "'") == 0)
1412 1412 { {
File tests/options/opt_completion.c changed (mode: 100644) (index a54540b01..fae861fdf)
... ... TEST(after_equal_sign_completion_corner_cases)
229 229 val.str_val = "'''"; val.str_val = "'''";
230 230 vle_opts_assign("fusehome", val, OPT_GLOBAL); vle_opts_assign("fusehome", val, OPT_GLOBAL);
231 231 vle_compl_reset(); vle_compl_reset();
232 vle_opts_complete("fusehome=", &start, OPT_GLOBAL);
233 ASSERT_NEXT_MATCH("\\'\\'\\'");
234 vle_compl_reset();
232 235 vle_opts_complete("fusehome='", &start, OPT_GLOBAL); vle_opts_complete("fusehome='", &start, OPT_GLOBAL);
233 236 ASSERT_NEXT_MATCH("\\'\\'\\'"); ASSERT_NEXT_MATCH("\\'\\'\\'");
234 237
238 val.str_val = "\"";
239 vle_opts_assign("fusehome", val, OPT_GLOBAL);
240 vle_compl_reset();
241 vle_opts_complete("fusehome=", &start, OPT_GLOBAL);
242 ASSERT_NEXT_MATCH("\\\"");
243
235 244 val.str_val = ""; val.str_val = "";
236 245 vle_opts_assign("fusehome", val, OPT_GLOBAL); vle_opts_assign("fusehome", val, OPT_GLOBAL);
237 246 vle_compl_reset(); vle_compl_reset();
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