mirror of
https://github.com/jarun/nnn.git
synced 2024-11-28 13:51:31 +00:00
158 lines
4.3 KiB
Groff
158 lines
4.3 KiB
Groff
.Dd August 21, 2016
|
|
.Dt NNN 1
|
|
.Os
|
|
.Sh NAME
|
|
.Nm nnn
|
|
.Nd free, fast, friendly file browser
|
|
.Sh SYNOPSIS
|
|
.Nm nnn
|
|
.Op Ar -d
|
|
.Op Ar dir
|
|
.Sh DESCRIPTION
|
|
.Nm
|
|
(Noice is Not Noice) is a fork of the noice terminal file browser with improved desktop integration, file associations and navigation. It remains a simple and efficient file browser that stays out of your way.
|
|
.Pp
|
|
.Nm
|
|
defaults to the current directory if
|
|
.Ar dir
|
|
is not specified.
|
|
.Pp
|
|
.Nm
|
|
supports both vi-like and emacs-like key bindings in the default
|
|
configuration. The default key bindings are listed below.
|
|
.Pp
|
|
.Bl -tag -width "l, [Right], [Return] or C-mXXXX" -offset indent -compact
|
|
.It Ic [Up], k, ^P
|
|
Move to previous entry
|
|
.It Ic [Down], j, ^N
|
|
Move to next entry
|
|
.It Ic [PgUp], ^U
|
|
Scroll up half a page
|
|
.It Ic [PgDn], ^D
|
|
Scroll down half a page
|
|
.It Ic [Home], ^, ^A
|
|
Move to the first entry
|
|
.It Ic [End], $, ^E
|
|
Move to the last entry
|
|
.It Ic [Right], [Enter], l, ^M
|
|
Open file or enter directory
|
|
.It Ic [Left], [Backspace], h, ^H
|
|
Back up one directory level
|
|
.It Ic ~
|
|
Change to the HOME directory
|
|
.It Ic /, &
|
|
Change filter (more information below)
|
|
.It Ic c
|
|
Change into the given directory
|
|
.It Ic d
|
|
Toggle detail view
|
|
.It Ic D
|
|
Show details of selected file
|
|
.It Ic \&.
|
|
Toggle hide .dot files
|
|
.It Ic s
|
|
Toggle sort by file size
|
|
.It Ic t
|
|
Toggle sort by time modified
|
|
.It Ic \&!
|
|
Spawn SHELL in PWD (fallback sh)
|
|
.It Ic z
|
|
Run the system top utility.
|
|
.It Ic e
|
|
Open current entry in EDITOR (fallback vi)
|
|
.It Ic p
|
|
Open current entry in PAGER (fallback less)
|
|
.It Ic ^K
|
|
Invoke file name copier
|
|
.It Ic ^L
|
|
Force a redraw
|
|
.It Ic \&?
|
|
Show help
|
|
.It Ic q
|
|
Quit
|
|
.El
|
|
.Pp
|
|
Backing up one directory level will set the cursor position at the
|
|
directory you came out of.
|
|
.Pp
|
|
.Nm
|
|
supports the following option:
|
|
.Pp
|
|
.Fl d
|
|
Open in detail view mode.
|
|
.Sh CONFIGURATION
|
|
.Nm
|
|
is configured by modifying
|
|
.Pa config.h
|
|
and recompiling the code.
|
|
.Pp
|
|
Environment variable
|
|
.Ar NNN_OPENER
|
|
overrides all hard-coded file associations.
|
|
.Pp
|
|
Hard-coded associations are specified by regexes matching on the currently selected filename. If a match is found the associated program is executed with the filename passed in as the argument. If no match is found the environment variable
|
|
.Ar NNN_FALLBACK_OPENER
|
|
is invoked, if set.
|
|
.Pp
|
|
No particular utility is set as the default opener as no standalone universal opener for all mime types exists.
|
|
.Pp
|
|
See the examples section below for more information.
|
|
.Sh FILTERS
|
|
Filters support regexes to display only the matched
|
|
entries in the current directory view. This effectively allows
|
|
searching through the directory tree for a particular entry.
|
|
.Pp
|
|
Filters do not stack on top of each other. They are applied anew
|
|
every time.
|
|
.Pp
|
|
To reset the filter you can input an empty filter expression.
|
|
.Pp
|
|
If
|
|
.Nm
|
|
is invoked as root the default filter will also match hidden
|
|
files.
|
|
.Sh ENVIRONMENT
|
|
The SHELL, EDITOR and PAGER environment variables take precedence
|
|
when dealing with the !, e and p commands respectively.
|
|
.Pp
|
|
\fBNNN_OPENER:\fR set to your desktop environment's default
|
|
mime opener to override all custom mime associations.
|
|
.br
|
|
Examples: xdg-open, gnome-open, gvfs-open.
|
|
.Pp
|
|
\fBNNN_FALLBACK_OPENER:\fR set to your desktop environment's default
|
|
mime opener to use as a fallback when no association is set for a file
|
|
type. Custom associations are listed in the EXAMPLES section below.
|
|
.Pp
|
|
\fBNNN_COPIER:\fR set to a clipboard copier script. For example, on Linux:
|
|
.Bd -literal
|
|
-------------------------------------
|
|
#!/bin/sh
|
|
|
|
echo -n $1 | xsel --clipboard --input
|
|
-------------------------------------
|
|
.Sh EXAMPLES
|
|
The following example shows one possible configuration for
|
|
file associations which is also the default if environment
|
|
variable NNN_OPENER is not set:
|
|
.Bd -literal
|
|
-----------------------------------------------
|
|
struct assoc assocs[] = {
|
|
{ "\\.(c|cpp|h|txt|log|sh)$", "vi" },
|
|
{ "\\.(wma|mp3|ogg|flac)$", "mpv" },
|
|
{ "\\.pdf$", "zathura" },
|
|
};
|
|
-----------------------------------------------
|
|
Plain text files are opened with vi.
|
|
.br
|
|
Any other file types are opened with the 'xdg-open' command.
|
|
.Ed
|
|
.Sh KNOWN ISSUES
|
|
If you are using urxvt you might have to set backspacekey to DEC.
|
|
.Sh AUTHORS
|
|
.An Lazaros Koromilas Aq Mt lostd@2f30.org ,
|
|
.An Dimitris Papastamos Aq Mt sin@2f30.org ,
|
|
.An Arun Prakash Jana Aq Mt engineerarun@gmail.com .
|
|
.Sh HOME
|
|
.Em https://github.com/jarun/nnn
|