mirror of
https://github.com/jarun/nnn.git
synced 2024-11-24 11:51:27 +00:00
Update docs
This commit is contained in:
parent
a900b2c4fa
commit
20280e182a
14
README.md
14
README.md
|
@ -305,9 +305,9 @@ colors: 0-black, 1-red, 2-green, 3-yellow, 4-blue (default), 5-magenta, 6-cyan,
|
||||||
|
|
||||||
#### Selection
|
#### Selection
|
||||||
|
|
||||||
Use <kbd>^K</kbd> to copy the absolute path of the file under the cursor.
|
Use <kbd>^K</kbd> to select the file under the cursor.
|
||||||
|
|
||||||
To copy multiple absolute file paths:
|
To select multiple files:
|
||||||
|
|
||||||
- press <kbd>^Y</kbd> to enter selection mode. In this mode it's possible to
|
- press <kbd>^Y</kbd> to enter selection mode. In this mode it's possible to
|
||||||
- cherry-pick individual files one by one by pressing <kbd>^K</kbd> on each entry (works across directories and contexts); or,
|
- cherry-pick individual files one by one by pressing <kbd>^K</kbd> on each entry (works across directories and contexts); or,
|
||||||
|
@ -316,13 +316,11 @@ To copy multiple absolute file paths:
|
||||||
|
|
||||||
_NOTE:_ If you are on BSD/macOS, please check the [BSD terminal issue](https://github.com/jarun/nnn#bsd-terminal-issue) with <kbd>^Y</kbd> for workaround.
|
_NOTE:_ If you are on BSD/macOS, please check the [BSD terminal issue](https://github.com/jarun/nnn#bsd-terminal-issue) with <kbd>^Y</kbd> for workaround.
|
||||||
|
|
||||||
Selected files are visually indicated by a `+`.
|
Selected files are visually indicated by a `+` before the entries.
|
||||||
|
|
||||||
The selection can now be listed, copied, moved, removed, archived or linked.
|
The selection can now be listed, copied, moved, removed, archived or linked.
|
||||||
|
|
||||||
File paths are copied to the temporary file `~/.config/nnn/.selection`.
|
Absolute paths of the selected files are copied to the temporary file `~/.config/nnn/.selection`. The path is shown in the help and configuration screen. If `$NNN_COPIER` is set the file paths are also copied to the system clipboard.
|
||||||
|
|
||||||
The path is shown in the help and configuration screen.
|
|
||||||
|
|
||||||
#### Filters
|
#### Filters
|
||||||
|
|
||||||
|
@ -419,7 +417,7 @@ To lookup keyboard shortcuts at runtime, press <kbd>?</kbd>.
|
||||||
|
|
||||||
#### PLUGINS
|
#### PLUGINS
|
||||||
|
|
||||||
`nnn` can invoke plugins in the current directory (`$PWD` for the plugin) with the currently selected file name as the argument.
|
To extend the capabilities of `nnn`, plugins are introduced. Plugins are scripts which `nnn` can communicate with and trigger. This mechanism fits perfectly with the fundamental design to keep the core file manager lean and fast, by delegating repetitive (but not necessarily file manager-specific) tasks to the plugins.
|
||||||
|
|
||||||
Copy the [plugins](https://github.com/jarun/nnn/tree/master/plugins) of your interest to `~/.config/nnn/plugins`.
|
Copy the [plugins](https://github.com/jarun/nnn/tree/master/plugins) of your interest to `~/.config/nnn/plugins`.
|
||||||
|
|
||||||
|
@ -437,7 +435,7 @@ If you have an interesting plugin feel free to raise a PR.
|
||||||
|
|
||||||
TLDR: Use the keybind <kbd>K</kbd> to toggle selection if you are having issues with <kbd>^Y</kbd>.
|
TLDR: Use the keybind <kbd>K</kbd> to toggle selection if you are having issues with <kbd>^Y</kbd>.
|
||||||
|
|
||||||
By default in OpenBSD & FreeBSD (and probably on macOS as well), `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.
|
By default in OpenBSD & FreeBSD (and probably on macOS as well), `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-selection 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
|
||||||
|
|
||||||
|
|
9
nnn.1
9
nnn.1
|
@ -120,9 +120,8 @@ allowing continuous navigation. Works best with the \fBarrow keys\fR.
|
||||||
When there's a unique match and it's a directory, `nnn` auto selects the directory and enters it in this mode.
|
When there's a unique match and it's a directory, `nnn` auto selects the directory and enters it in this mode.
|
||||||
.br
|
.br
|
||||||
The \fIwild load\fR option can be extremely handy for users who use the \fInavigate-as-you-type\fR mode constantly. The entries are unsorted when the directory loads. Applying filters sorts the entries (with directories on top). Directory color is disabled in this mode.
|
The \fIwild load\fR option can be extremely handy for users who use the \fInavigate-as-you-type\fR mode constantly. The entries are unsorted when the directory loads. Applying filters sorts the entries (with directories on top). Directory color is disabled in this mode.
|
||||||
.Sh SELECTION MODE
|
.Sh SELECTION
|
||||||
The absolute path of a single file can be copied to clipboard by pressing \fI^K\fR if
|
Use \fI^K\fR to select the file under the cursor.
|
||||||
NNN_COPIER is set (see ENVIRONMENT section below).
|
|
||||||
.Pp
|
.Pp
|
||||||
To select multiple files the selection mode should be enabled using \fI^Y\fR.
|
To select multiple files the selection mode should be enabled using \fI^Y\fR.
|
||||||
In this mode it's possible to
|
In this mode it's possible to
|
||||||
|
@ -133,9 +132,11 @@ In this mode it's possible to
|
||||||
.Pp
|
.Pp
|
||||||
Press \fI^Y\fR again to save the selection and exit selection mode.
|
Press \fI^Y\fR again to save the selection and exit selection mode.
|
||||||
.Pp
|
.Pp
|
||||||
Selected files are visually indicated by a \fB+\fR.
|
Selected files are visually indicated by a \fB+\fR before the entries.
|
||||||
.br
|
.br
|
||||||
The files in the list can now be listed, copied, moved, removed, archived or linked.
|
The files in the list can now be listed, copied, moved, removed, archived or linked.
|
||||||
|
.br
|
||||||
|
Absolute paths of the selected files are copied to the temporary file \fB~/.config/nnn/.selection\fR. The path is shown in the help and configuration screen. If \fB$NNN_COPIER\fR is set (see ENVIRONMENT section below) the file paths are also copied to the system clipboard.
|
||||||
.Sh ENVIRONMENT
|
.Sh ENVIRONMENT
|
||||||
The SHELL, EDITOR (VISUAL, if defined) and PAGER environment variables take precedence
|
The SHELL, EDITOR (VISUAL, if defined) and PAGER environment variables take precedence
|
||||||
when dealing with the !, e and p commands respectively. A single combination to arguments is supported for SHELL and PAGER.
|
when dealing with the !, e and p commands respectively. A single combination to arguments is supported for SHELL and PAGER.
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
|
|
||||||
Plugins can access:
|
Plugins can access:
|
||||||
- all files in the directory (`nnn` switches to the dir where the plugin is to be run so the dir is `$PWD` for the plugin)
|
- all files in the directory (`nnn` switches to the dir where the plugin is to be run so the dir is `$PWD` for the plugin)
|
||||||
- the currently highlighted file (the file name is passed as the argument to a plugin)
|
- the current file under the cursor (the file name is passed as the argument to a plugin)
|
||||||
- the current selection (by reading the file `~/.config/nnn/.selection`, see the plugin `ndiff`)
|
- the current selection (by reading the file `~/.config/nnn/.selection`, see the plugin `ndiff`)
|
||||||
|
|
||||||
Each script has a _Description_ section which provides more details on what the script does, if applicable.
|
Each script has a _Description_ section which provides more details on what the script does, if applicable.
|
||||||
|
|
Loading…
Reference in a new issue