diff options
author | Arun Prakash Jana <engineerarun@gmail.com> | 2019-01-11 18:54:54 +0530 |
---|---|---|
committer | Arun Prakash Jana <engineerarun@gmail.com> | 2019-01-11 21:43:57 +0530 |
commit | 5df41255b293d20ea5f1a54ba1950ff483c66187 (patch) | |
tree | 277d3477d65685f63bde92ca0d27ca4dd8b3c7e4 /README.md | |
parent | 625f2f88309c86395f902cb7e6e73b41c6238813 (diff) | |
download | nnn-5df41255b293d20ea5f1a54ba1950ff483c66187.tar.gz |
Fix #187
It seems the behaviour of the default opener (xdg-open) varies across platforms
and environments. Details are documented in the issue. To prevent an empty file
from being accidentally opened leading to unexpected behaviour, we are adding a
guard with the message that the empty file should be opened using edit or open
option.
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -80,6 +80,7 @@ We need contributors. Please visit the [ToDo list](https://github.com/jarun/nnn/ - [tmux configuration](#tmux-configuration) - [BSD terminal issue](#bsd-terminal-issue) - [restrict file open](#restrict-file-open) + - [restrict 0-byte files](#restrict-0-byte-files) - [Why fork?](#why-fork) - [Mentions](#mentions) - [Developers](#developers) @@ -531,7 +532,7 @@ Enable volume management in your DE file manager and set removable drives or med By default in OpenBSD & FreeBSD, `stty` maps <kbd>^Y</kbd> to `DSUSP`. This means that typing <kbd>^Y</kbd> will suspend `nnn` as if you typed <kbd>^Z</kbd> (you can bring `nnn` back to the foreground by issuing `fg`) instead of entering multi-copy mode. You can check this with `stty -a`. If it includes the text `dsusp = ^Y`, issuing `stty dsusp undef` will disable this `DSUSP` and let `nnn` receive the <kbd>^Y</kbd> instead. -#### Restrict file open +#### restrict file open In order to disable opening files on accidental navigation key (<kbd>→</kbd> or <kbd>l</kbd>) press: @@ -539,6 +540,12 @@ In order to disable opening files on accidental navigation key (<kbd>→</kbd> o Use <kbd>Enter</kbd> to open files. +#### restrict 0-byte files + +Restrict opening 0-byte files due to [unexpected behaviour](https://github.com/jarun/nnn/issues/187); use _edit_ or _open with_ to open the file. + + export NNN_RESTRICT_0B=1 + #### WHY FORK? `nnn` was initially forked from [noice](http://git.2f30.org/noice/) but is significantly [different](https://github.com/jarun/nnn/wiki/nnn-vs.-noice) today. I chose to fork because: |