diff options
author | Arun Prakash Jana <engineerarun@gmail.com> | 2019-12-18 21:53:18 +0530 |
---|---|---|
committer | Arun Prakash Jana <engineerarun@gmail.com> | 2019-12-18 21:53:18 +0530 |
commit | 6b5bb16b46cbf8ee2b6c34d7b52ddbf872f40930 (patch) | |
tree | 1db813ee0f373e321b76769a6f1ac2d55bebbd6b | |
parent | fb2c548e86ca92b53dc01bf232ecb2b9c6896785 (diff) | |
download | nnn-6b5bb16b46cbf8ee2b6c34d7b52ddbf872f40930.tar.gz |
Minor improvements
- reduce 4 spaces between help columns as it's too wide for handhelds
- support `]` as prompt in nav-as-you-type-mode when filter is empty
- update plugin docs
-rw-r--r-- | plugins/README.md | 2 | ||||
-rw-r--r-- | src/nnn.c | 57 |
2 files changed, 30 insertions, 29 deletions
diff --git a/plugins/README.md b/plugins/README.md index 763aa43..4676a96 100644 --- a/plugins/README.md +++ b/plugins/README.md @@ -87,7 +87,7 @@ For example: Now <kbd>;x</kbd> can be used to make a file executable, <kbd>;g</kbd> can be used to the git log of a git project directory, <kbd>;s</kbd> can be used to preview a partially downloaded media file. -`nnn` waits for user confirmation when it executes a command as plugin (unline plugins which can add a `read` to wait). If you do not need to wait for user confirmation after the command has executed, add a `*` after the command. For example: +`nnn` waits for user confirmation (the prompt `Press Enter to continue`) when it executes a command as plugin (unline plugins which can add a `read` to wait). If you do not need to wait for user confirmation after the command has executed, add a `*` after the command. For example: export NNN_PLUG='x:_chmod +x $nnn;g:_git log;s:_smplayer $nnn*;o:fzopen' @@ -2070,6 +2070,7 @@ static int filterentries(char *path) switch (*ch) { case '=': // fallthrough /* Launch app */ + case ']': // fallthorugh /*Prompt key */ case ';': // fallthrough /* Run plugin key */ case '?': /* Help and config key, '?' is an invalid regex */ if (len == 1) { @@ -3463,39 +3464,39 @@ static void show_help(const char *path) const char helpstr[] = { "0\n" "1NAVIGATION\n" - "9Up k Up%-20cPgUp ^U Scroll up\n" - "7Down j Down%-18cPgDn ^D Scroll down\n" - "7Left h Parent%-16c~ ` @ - HOME, /, start, last\n" - "9g ^A Top%-15cRet Right l Open\n" - "9G ^E Bottom%-22c' First file\n" - "cb Pin CWD%-20c^B Go to pinned dir\n" - "8c, ^/ Lead key%-14cN LeadN Context N\n" - "6(Sh)Tab Cycle context%-15cd Detail view toggle\n" - "c/ Filter%-17cIns ^N Nav-as-you-type toggle\n" - "aEsc Exit prompt%-13c^L F5 Redraw/clear prompt\n" - "c. Show/hide dots%-14c? Help, conf\n" - "9Q ^Q Quit%-24cq Quit context\n" + "9Up k Up%-16cPgUp ^U Scroll up\n" + "7Down j Down%-14cPgDn ^D Scroll down\n" + "7Left h Parent%-12c~ ` @ - HOME, /, start, last\n" + "9g ^A Top%-11cRet Right l Open\n" + "9G ^E Bottom%-18c' First file\n" + "cb Pin CWD%-16c^B Go to pinned dir\n" + "8c, ^/ Lead key%-10cN LeadN Context N\n" + "6(Sh)Tab Cycle context%-11cd Detail view toggle\n" + "c/ Filter%-13cIns ^N Nav-as-you-type toggle\n" + "aEsc Exit prompt%-9c^L F5 Redraw/clear prompt\n" + "c. Show/hide dots%-10c? Help, conf\n" + "9Q ^Q Quit%-20cq Quit context\n" "b^G QuitCD%-1c\n" "1FILES\n" - "b^O Open with...%-16cn Create new/link\n" - "cD File details%-12c^R F2 Rename/duplicate\n" - "3Space ^J/a Sel toggle/all%-14cr Batch rename\n" - "9m ^K Sel range, clear%-12cM List sel\n" - "cP Copy sel here%-15cK Edit sel\n" - "cV Move sel here%-15cw Copy/move sel as\n" - "cX Delete sel%-17c^X Delete entry\n" - "cf Archive%-18co ^F Archive ops\n" - "ce Edit in EDITOR%-14cp Open in PAGER\n" + "b^O Open with...%-12cn Create new/link\n" + "cD File details%-8c^R F2 Rename/duplicate\n" + "3Space ^J/a Sel toggle/all%-10cr Batch rename\n" + "9m ^K Sel range, clear%-8cM List sel\n" + "cP Copy sel here%-11cK Edit sel\n" + "cV Move sel here%-11cw Copy/move sel as\n" + "cX Delete sel%-13c^X Delete entry\n" + "cf Archive%-14co ^F Archive ops\n" + "ce Edit in EDITOR%-10cp Open in PAGER\n" "1ORDER TOGGLES\n" - "cA Apparent du%-17cS du\n" - "cz Size%-24ct Time\n" + "cA Apparent du%-13cS du\n" + "cz Size%-20ct Time\n" "cE Extension%-1c\n" "1MISC\n" - "9! ^] Shell%-21c; x Plugin key\n" - "cC Execute file%-13ci ^V Pick plugin\n" - "cs Manage session%-14c= Launch app\n" - "cc Connect remote%-14cu Unmount\n" - "9] ^P Prompt%-22cL Lock\n" + "9! ^] Shell%-17c; x Plugin key\n" + "cC Execute file%-9ci ^V Pick plugin\n" + "cs Manage session%-10c= Launch app\n" + "cc Connect remote%-10cu Unmount\n" + "9] ^P Prompt%-18cL Lock\n" }; fd = create_tmp_file(); |