Skip to content

Commit

Permalink
use filename completion if backslash is found
Browse files Browse the repository at this point in the history
  • Loading branch information
stsp committed Jan 21, 2025
1 parent 8ead048 commit 26c2294
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/command.c
Original file line number Diff line number Diff line change
Expand Up @@ -718,9 +718,13 @@ static void prompt_for_and_get_cmd(void)
cmdbuf_clreol(conbuf);
if (need_prn)
putchar('\n');
if ((p1 = strrchr(conbuf, ' ')))
{
p1 = strrchr(conbuf, ' ');
if (p1)
p1++;
else if (strchr(conbuf, '\\'))
p1 = conbuf;
if (p1)
{
rc = compl_fname(p1, got_tab, &l, p);
/* fixup for directories */
if (rc == 1)
Expand Down

0 comments on commit 26c2294

Please sign in to comment.