You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+20-16Lines changed: 20 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -343,21 +343,7 @@ NOTE: To enable this, command `fzf` must be found in `$PATH` before initializati
343
343
344
344
## Most Recently Accessed Path
345
345
346
-
We always use `cd -` to go back to last accessed directory, but with the help of `fzf` we can achieve this productively:
347
-
348
-
```bash
349
-
alias zh='z -I -t .'
350
-
```
351
-
352
-
The new alias `zh` (jump to history) uses a parameter `-t` to sort the result by time and `-I` to use `fzf` for selection. the result is:
353
-
354
-

355
-
356
-
The first column indicates how many seconds ago you have visited, and the second column is the path name. With `zh`, you can type some character to use string matching in fzf, or use `<Up>`/`<Down>` (as well as `CTRL+j/k`) to move the selector (red `>`) up and down.
357
-
358
-
At last, press `<enter>` to accept or `<ESC>` to give up.
359
-
360
-
Version `v1.5.1` has introduced a simulated "dirstack", which can be manipulated by `z -`, `z --` and `z -{num}`:
346
+
`z.lua` provides a fast way to visit MRU directories without typing any keyword. That is `dirstack`, which records recently visited paths and can be manipulated by `z -`, `z --` and `z -{num}`:
361
347
362
348
```bash
363
349
# display current dir stack
@@ -377,7 +363,24 @@ $ z -
377
363
=>cd -
378
364
```
379
365
380
-
The dirstack is calculated from z.lua's database, and has no dependency on shells or systems. You will not lost records after re-login, and history can be shared across shells and sessions.
366
+
The `dirstack` is calculated from z.lua's database, and has no dependency on shells or systems. You will not lost records after re-login, and history can be shared across shells and sessions.
367
+
368
+
There is another way to access MRU directories interactively by utilizing parameter `-I` (fzf) and `-t` (sort by time):
369
+
370
+
```bash
371
+
alias zh='z -I -t .'
372
+
```
373
+
374
+
The new alias `zh` (jump to history) uses a parameter `-t` to sort the result by time and `-I` to use `fzf` for selection. the result is:
375
+
376
+

377
+
378
+
The first column indicates how many seconds ago you have visited, and the second column is the path name. With `zh`, you can type some character to use string matching in fzf, or use `<Up>`/`<Down>` (as well as `CTRL+j/k`) to move the selector (red `>`) up and down.
379
+
380
+
At last, press `<enter>` to accept or `<ESC>` to give up.
381
+
382
+
Version `v1.5.1` has introduced a simulated "dirstack", which can be manipulated by `z -`, `z --` and `z -{num}`:
383
+
381
384
382
385
Remember to enable the [enhanced matching](#enhanced-matching) algorithm, the current working directory can be skipped with it.
383
386
@@ -450,6 +453,7 @@ As you see, z.lua is the fastest one and requires less resource.
450
453
451
454
## History
452
455
456
+
- 1.5.2 (2019-02-16): be aware of all arguments in fzf completion.
453
457
- 1.5.1 (2019-02-15): new: simulated dir stack by `z -`, `z --` and `z -{num}`.
454
458
- 1.5.0 (2019-02-14): fixed minor issues in backward jumping.
455
459
- 1.4.7 (2019-02-13): Don't use regex in backward jumping (use plain text instead).
0 commit comments