From: Arun Prakash Jana Date: Thu, 19 Dec 2019 21:21:25 +0000 (+0530) Subject: Revert "Prefer NNN_USE_EDITOR over opener (option )" X-Git-Tag: v2.9~143 X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=7d171368ad1059e9112d2542c70de0405fb2e6f1;p=nnn.git Revert "Prefer NNN_USE_EDITOR over opener (option )" This reverts commit 7f3d2c10aaabee34cfda435c199335f023215fba. --- diff --git a/src/nnn.c b/src/nnn.c index 8f2d53fb..cf2826fd 100644 --- a/src/nnn.c +++ b/src/nnn.c @@ -5814,8 +5814,8 @@ int main(int argc, char *argv[]) } } - /* Edit text in "editor" if opted (gets preference over option `-c`) */ - if (xgetenv_set(env_cfg[NNN_USE_EDITOR])) + /* Edit text in EDITOR if opted (and opener is not all-CLI) */ + if (!cfg.cliopener && xgetenv_set(env_cfg[NNN_USE_EDITOR])) cfg.useeditor = 1; /* Get VISUAL/EDITOR */