mirror of
https://github.com/jarun/nnn.git
synced 2024-11-24 11:51:27 +00:00
Key \ only works in empty prompt
This commit is contained in:
parent
a3d6b81d9f
commit
6582855412
|
@ -2074,13 +2074,12 @@ static int filterentries(char *path)
|
||||||
if (r == OK) {
|
if (r == OK) {
|
||||||
/* Handle all control chars in main loop */
|
/* Handle all control chars in main loop */
|
||||||
if ((*ch < ASCII_MAX && keyname(*ch)[0] == '^' && *ch != '^')
|
if ((*ch < ASCII_MAX && keyname(*ch)[0] == '^' && *ch != '^')
|
||||||
|| (*ch == '\\')) {
|
|| (*ch == '\\' && len == 1)) {
|
||||||
DPRINTF_D(*ch);
|
DPRINTF_D(*ch);
|
||||||
DPRINTF_S(keyname(*ch));
|
DPRINTF_S(keyname(*ch));
|
||||||
|
|
||||||
/* If there's a filter, try a command on ^P */
|
/* If there's a filter, try a command on ^P */
|
||||||
if (cfg.filtercmd && (*ch == CONTROL('P') || *ch == '\\')
|
if (cfg.filtercmd && *ch == CONTROL('P') && len > 1) {
|
||||||
&& len > 1) {
|
|
||||||
prompt_run(pln, (ndents ? dents[cur].name : ""), path);
|
prompt_run(pln, (ndents ? dents[cur].name : ""), path);
|
||||||
|
|
||||||
/* Clear the prompt */
|
/* Clear the prompt */
|
||||||
|
|
Loading…
Reference in a new issue