My build of nnn with minor changes
Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.
 
 
 
 
 
 

214 řádky
6.7 KiB

  1. .Dd Aug 06, 2019
  2. .Dt NNN 1
  3. .Os
  4. .Sh NAME
  5. .Nm nnn
  6. .Nd the missing terminal file manager for X
  7. .Sh SYNOPSIS
  8. .Nm
  9. .Op Ar -a
  10. .Op Ar -b key
  11. .Op Ar -d
  12. .Op Ar -f
  13. .Op Ar -H
  14. .Op Ar -i
  15. .Op Ar -n
  16. .Op Ar -p file
  17. .Op Ar -r
  18. .Op Ar -s
  19. .Op Ar -S
  20. .Op Ar -v
  21. .Op Ar -h
  22. .Op Ar PATH
  23. .Sh DESCRIPTION
  24. .Nm
  25. (Nnn's Not Noice) is a performance-optimized, feature-packed fork of noice (http://git.2f30.org/noice/) with seamless desktop integration, simplified navigation, \fInavigate-as-you-type\fR mode with auto select, disk usage analyzer mode, bookmarks, contexts, application launcher, familiar navigation shortcuts, subshell spawning and much more. It remains a simple and efficient file manager that stays out of your way.
  26. .Pp
  27. .Nm
  28. opens the current working directory by default if
  29. .Ar PATH
  30. is not specified.
  31. .Sh KEYBINDS
  32. .Pp
  33. Press \fB?\fR in
  34. .Nm
  35. to see the list of keybinds.
  36. .Sh OPTIONS
  37. .Pp
  38. .Nm
  39. supports the following options:
  40. .Pp
  41. .Fl a
  42. use access time for all operations (default: modification time)
  43. .Pp
  44. .Fl "b key"
  45. specify bookmark key to open
  46. .Pp
  47. .Fl d
  48. detail mode
  49. .Pp
  50. .Fl f
  51. run filter as command when the prompt key is pressed
  52. .Pp
  53. .Fl H
  54. show hidden files
  55. .Pp
  56. .Fl i
  57. start in navigate-as-you-type mode
  58. .Pp
  59. .Fl n
  60. use case-insensitive version compare to sort files
  61. .Pp
  62. .Fl o
  63. open files only on Enter key
  64. .Pp
  65. .Fl "p file"
  66. copy (or \fIpick\fR) selection to file, or stdout if file='-'
  67. .Pp
  68. .Fl r
  69. show cp, mv progress (Linux-only, needs advcpmv; '^T' shows the progress on BSD/macOS)
  70. .Pp
  71. .Fl s
  72. use substring match for filters instead of regex
  73. .Pp
  74. .Fl S
  75. start in disk usage analyzer mode
  76. .Pp
  77. .Fl t
  78. disable directory auto-select in navigate-as-you-type mode
  79. .Pp
  80. .Fl v
  81. show version and exit
  82. .Pp
  83. .Fl h
  84. show program help and exit
  85. .Sh CONFIGURATION
  86. .Nm
  87. uses \fIxdg-open\fR (on Linux) and \fIopen(1)\fR (on macOS) as the desktop opener.
  88. .Pp
  89. There is no configuration file. Associated files are stored in \fB${XDG_CONFIG_HOME:-$HOME/.config}/nnn/\fR. Settings work on environment variables. See ENVIRONMENT section below.
  90. .Pp
  91. Configuring
  92. .Nm
  93. to change to the last visited directory on quit requires shell integration in a
  94. few easy steps. Look up NNN_TMPFILE in the ENVIRONMENT section below.
  95. .Sh CONTEXTS
  96. Contexts serve the purpose of exploring multiple directories simultaneously. 4 contexts
  97. are available. The status of the contexts are shown in the top left corner:
  98. .Pp
  99. - the current context is in reverse video
  100. .br
  101. - other active contexts are underlined
  102. .br
  103. - rest are inactive
  104. .Pp
  105. On context creation, the state of the previous context is copied. Each context remembers its last visited directory.
  106. .Pp
  107. Each context can have its own directory color specified. See ENVIRONMENT section below.
  108. .Sh FILTERS
  109. Filters support regexes (default) to instantly (search-as-you-type) list the matching
  110. entries in the current directory.
  111. .Pp
  112. Common use cases:
  113. .Pp
  114. (1) To list all matches starting with the filter expression, start the expression
  115. with a '^' (caret) symbol.
  116. .br
  117. (2) Type '\\.mkv' to list all MKV files.
  118. .br
  119. (3) Use '.*' to match any character (\fIsort of\fR fuzzy search).
  120. .Pp
  121. There is a program option to filter entries by substring match instead of regex.
  122. .Pp
  123. There is a program option to execute the current filter as a command when the prompt key is pressed.
  124. .Pp
  125. In the \fInavigate-as-you-type\fR mode directories are opened in filter mode,
  126. allowing continuous navigation. Works best with the \fBarrow keys\fR.
  127. .br
  128. When there's a unique match and it's a directory,
  129. .Nm
  130. auto selects the directory and enters it in this mode.
  131. .Sh SELECTION
  132. Use \fI^K\fR to select the file under the cursor.
  133. .Pp
  134. To select multiple files the selection mode should be enabled using \fI^Y\fR.
  135. In this mode it's possible to
  136. .Pp
  137. (1) cherry-pick individual files one by one by pressing <kbd>^K</kbd> on each entry (works across directories and contexts); or,
  138. .br
  139. (2) navigate to another file in the same directory to select a range of files.
  140. .Pp
  141. Press \fI^Y\fR again to save the selection and exit selection mode.
  142. .Pp
  143. Selected files are visually indicated by a \fB+\fR before the entries.
  144. .br
  145. The files in the list can now be listed, copied, moved, removed, archived or linked.
  146. .br
  147. Absolute paths of the selected files are copied to the temporary file \fB.selection\fR in config directory. 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.
  148. .Sh ENVIRONMENT
  149. The SHELL, EDITOR (VISUAL, if defined) and PAGER environment variables take precedence
  150. when dealing with the !, e and p commands respectively. A single combination to arguments is supported for SHELL and PAGER.
  151. .Pp
  152. \fBNNN_BMS:\fR bookmark string as \fIkey_char:location\fR pairs (max 10) separated by
  153. \fI;\fR:
  154. .Bd -literal
  155. export NNN_BMS='d:~/Documents;u:/home/user/Cam Uploads;D:~/Downloads/'
  156. NOTE: To go to a bookmark, press the leader key followed by the bookmark key.
  157. .Ed
  158. .Pp
  159. \fBNNN_PLUG:\fR directly executable plugins as \fIkey_char:location\fR pairs (max 10) separated by
  160. \fI;\fR:
  161. .Bd -literal
  162. export NNN_PLUG='o:fzy-open;p:mocplay;d:ndiff;m:nmount;t:thumb;i:mediainf'
  163. NOTE: To run a plugin directly, press 'x' followed by the plugin key.
  164. .Ed
  165. .Pp
  166. \fBNNN_USE_EDITOR:\fR use VISUAL (else EDITOR, preferably CLI, fallback vi) to handle text files.
  167. .Bd -literal
  168. export NNN_USE_EDITOR=1
  169. .Ed
  170. .Pp
  171. \fBNNN_CONTEXT_COLORS:\fR string of color codes for each context, e.g.:
  172. .Bd -literal
  173. export NNN_CONTEXT_COLORS='1234'
  174. codes: 0-black, 1-red, 2-green, 3-yellow, 4-blue (default), 5-magenta, 6-cyan, 7-white
  175. .Ed
  176. .Pp
  177. \fBNNN_SSHFS_OPTS:\fR pass additional options to sshfs command:
  178. .Bd -literal
  179. export NNN_SSHFS_OPTS='sshfs -o reconnect,idmap=user,cache_timeout=3600'
  180. NOTE: The options must be preceded by `sshfs` and comma-separated without any space between them.
  181. .Ed
  182. .Pp
  183. \fBNNN_OPENER:\fR specify a custom file opener.
  184. .Bd -literal
  185. export NNN_OPENER=mimeopen
  186. .Ed
  187. .Pp
  188. \fBNNN_IDLE_TIMEOUT:\fR set idle timeout (in seconds) to invoke terminal locker (default: disabled).
  189. .Pp
  190. \fBNNN_COPIER:\fR system clipboard copier script. The project page has some sample copier scripts.
  191. .Pp
  192. \fBNNN_TRASH:\fR trash (instead of \fIdelete\fR) files to desktop Trash.
  193. .Bd -literal
  194. export NNN_TRASH=1
  195. .Ed
  196. .Sh KNOWN ISSUES
  197. .Nm
  198. may not handle keypresses correctly when used with tmux (see issue #104 for more details). Set \fBTERM=xterm-256color\fR to address it.
  199. .Pp
  200. Use the keybind \fBK\fR to toggle selection if you are having issues with \fB^Y\fR on *BSD or macOS. To use \fB^Y\fR, run:
  201. .Bd -literal
  202. stty dsusp undef
  203. .Ed
  204. .Sh AUTHORS
  205. .An Arun Prakash Jana Aq Mt engineerarun@gmail.com ,
  206. .An Lazaros Koromilas Aq Mt lostd@2f30.org ,
  207. .An Dimitris Papastamos Aq Mt sin@2f30.org .
  208. .Sh HOME
  209. .Em https://github.com/jarun/nnn