How to autocomplete at the KornShell command line with the vi editor

David picture David · Sep 17, 2008 · Viewed 28.7k times · Source

In the KornShell (ksh) on AIX UNIX Version 5.3 with the editor mode set to vi using:

set -o vi

What are the key-strokes at the shell command line to autocomplete a file or directory name?

Answer

paxdiablo picture paxdiablo · Sep 17, 2008

ESC\ works fine on AIX4.2 at least. One thing I noticed is that it only autocompletes to the unique part of the file name.

So if you have the files x.txt, x171go and x171stop, the following will happen:

Press keys:           Command line is:
x                     x
<ESC>\                x
1                     x1
<ESC>\                x171
g<ESC>\               x171go