Commit 1a9e247
committed
readline: show completions only after 2nd TAB
Show `TAB` completion suggestions only after the user has pressed `TAB`
twice in a row, so that the full list of suggestions doesn’t present
a distraction. The first time a `TAB` key is pressed, only partial
longest-common-prefix completion is performed.
This moves the `readline` autocompletion a lot closer to what e.g.
`bash` does.
Fixes: #7665
PR-URL: #7754
Reviewed-By: Rich Trott <[email protected]>
Reviewed-By: Trevor Norris <[email protected]>
Reviewed-By: Ben Noordhuis <[email protected]>
Reviewed-By: James M Snell <[email protected]>1 parent c809b88 commit 1a9e247
File tree
2 files changed
+24
-17
lines changed- lib
- test/parallel
2 files changed
+24
-17
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
| 44 | + | |
44 | 45 | | |
45 | 46 | | |
46 | 47 | | |
| |||
391 | 392 | | |
392 | 393 | | |
393 | 394 | | |
394 | | - | |
| 395 | + | |
395 | 396 | | |
396 | 397 | | |
397 | 398 | | |
| |||
407 | 408 | | |
408 | 409 | | |
409 | 410 | | |
410 | | - | |
411 | | - | |
412 | | - | |
| 411 | + | |
413 | 412 | | |
414 | 413 | | |
415 | 414 | | |
| |||
429 | 428 | | |
430 | 429 | | |
431 | 430 | | |
| 431 | + | |
432 | 432 | | |
433 | | - | |
434 | | - | |
435 | | - | |
436 | | - | |
437 | | - | |
438 | | - | |
439 | | - | |
440 | | - | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
441 | 438 | | |
| 439 | + | |
442 | 440 | | |
443 | 441 | | |
444 | 442 | | |
| |||
474 | 472 | | |
475 | 473 | | |
476 | 474 | | |
| 475 | + | |
477 | 476 | | |
478 | 477 | | |
479 | 478 | | |
| |||
688 | 687 | | |
689 | 688 | | |
690 | 689 | | |
| 690 | + | |
691 | 691 | | |
| 692 | + | |
692 | 693 | | |
693 | 694 | | |
694 | 695 | | |
| |||
892 | 893 | | |
893 | 894 | | |
894 | 895 | | |
895 | | - | |
| 896 | + | |
| 897 | + | |
896 | 898 | | |
897 | 899 | | |
898 | 900 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
| 29 | + | |
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
34 | | - | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
35 | 40 | | |
36 | | - | |
| 41 | + | |
37 | 42 | | |
0 commit comments