diff options
author | Arun Prakash Jana <engineerarun@gmail.com> | 2020-01-11 21:46:37 +0530 |
---|---|---|
committer | Arun Prakash Jana <engineerarun@gmail.com> | 2020-01-11 21:49:35 +0530 |
commit | 99d15815f03c8fa19ee36fa7e9190d5f8be8ee7f (patch) | |
tree | 34d1ee549e837e53688b23bf9b6546b05cb7c02f /src | |
parent | 274c6120764f5956914e36baa115bbc3cca2e6ac (diff) | |
download | nnn-99d15815f03c8fa19ee36fa7e9190d5f8be8ee7f.tar.gz |
Use : for filter case
Diffstat (limited to 'src')
-rw-r--r-- | src/dbg.h | 2 | ||||
-rw-r--r-- | src/nnn.c | 5 |
2 files changed, 4 insertions, 3 deletions
@@ -79,7 +79,7 @@ static void disabledbg(void) #define STRINGIFY(x) #x #define TOSTRING(x) STRINGIFY(x) -#define DPRINTF_D(x) xprintf(DEBUG_FD, "ln " TOSTRING(__LINE__) ": " #x "=%d\n", x, __LINE__) +#define DPRINTF_D(x) xprintf(DEBUG_FD, "ln " TOSTRING(__LINE__) ": " #x "=%d\n", x) #define DPRINTF_U(x) xprintf(DEBUG_FD, "ln " TOSTRING(__LINE__) ": " #x "=%u\n", x) #define DPRINTF_S(x) xprintf(DEBUG_FD, "ln " TOSTRING(__LINE__) ": " #x "=%s\n", x) #define DPRINTF_P(x) xprintf(DEBUG_FD, "ln " TOSTRING(__LINE__) ": " #x "=%p\n", x) @@ -129,6 +129,7 @@ #define READLINE_MAX 128 #define FILTER '/' #define RFILTER '\\' +#define CASE ':' #define MSGWAIT '$' #define REGEX_MAX 48 #define BM_MAX 10 @@ -2011,7 +2012,7 @@ static void showfilterinfo(void) { char info[REGEX_MAX]; - snprintf(info, REGEX_MAX - 1, " %s [/\\], %s [|]", + snprintf(info, REGEX_MAX - 1, " %s [/\\], %s [:]", (cfg.regex ? "regex" : "str"), ((fnstrstr == &strcasestr) ? "ic" : "noic")); printinfoln(info); @@ -2167,7 +2168,7 @@ static int filterentries(char *path, char *lastname) } /* Toggle case-sensitivity */ - if (*ch == '|') { + if (*ch == CASE) { fnstrstr = (fnstrstr == &strcasestr) ? &strstr : &strcasestr; regflags ^= REG_ICASE; showfilter(ln); |