Use 'pin' dir instead of 'mark' dir

This commit is contained in:
Arun Prakash Jana 2017-09-01 19:57:36 +05:30
parent c248f42c31
commit e2fae851c3
No known key found for this signature in database
GPG Key ID: A75979F35C080412
4 changed files with 10 additions and 10 deletions

View File

@ -82,7 +82,7 @@ Have fun with it! PRs are welcome. Check out [#1](https://github.com/jarun/nnn/i
- Navigation
- Familiar shortcuts
- *Navigate-as-you-type* mode
- Bookmarks support; mark and visit a directory
- Bookmarks support; pin and visit a directory
- Jump HOME or to the last visited directory (as usual!)
- Jump to initial dir, chdir prompt, cd ..... (with . as PWD)
- Roll-over at edges, page through entries
@ -205,8 +205,8 @@ To cook yourself, download the [latest stable release](https://github.com/jarun/
^/ | Open desktop search tool
. | Toggle hide .dot files
b | Show bookmark prompt
^B | Mark current dir
^V | Go to marked dir
^B | Pin current dir
^V | Go to pinned dir
c | Show change dir prompt
d | Toggle detail view
D | Show current file details

View File

@ -21,7 +21,7 @@ enum action {
SEL_CDBEGIN,
SEL_CDLAST,
SEL_CDBM,
SEL_MARK,
SEL_PIN,
SEL_VISIT,
SEL_TOGGLEDOT,
SEL_DETAIL,
@ -115,7 +115,7 @@ static struct key bindings[] = {
/* Change dir using bookmark */
{ 'b', SEL_CDBM, "", "" },
/* Mark a path to visit later */
{ CONTROL('B'), SEL_MARK, "", "" },
{ CONTROL('B'), SEL_PIN, "", "" },
/* Visit marked directory */
{ CONTROL('V'), SEL_VISIT, "", "" },
/* Toggle hide .dot files */

4
nnn.1
View File

@ -62,9 +62,9 @@ Toggle hide .dot files
.It Ic b
Show bookmark key prompt
.It Ic ^B
Mark current dir
Pin current dir
.It Ic ^V
Visit marked dir
Visit pinned dir
.It Ic c
Show change dir prompt
.It Ic d

6
nnn.c
View File

@ -1645,8 +1645,8 @@ show_help(char *path)
"d^/ | Open desktop search tool\n"
"e. | Toggle hide .dot files\n"
"eb | Show bookmark prompt\n"
"d^B | Mark current dir\n"
"d^V | Go to marked dir\n"
"d^B | Pin current dir\n"
"d^V | Go to pinned dir\n"
"ec | Show change dir prompt\n"
"ed | Toggle detail view\n"
"eD | Show current file details\n"
@ -2505,7 +2505,7 @@ nochange:
if (cfg.filtermode)
presel = FILTER;
goto begin;
case SEL_MARK:
case SEL_PIN:
xstrlcpy(mark, path, PATH_MAX);
printmsg(mark);
goto nochange;