GNU Readline Library. Node: Custom Completers
Readline Convenience Functions
Programming with GNU Readline
2.5: Custom Completers
Typically, a program that reads commands from the user has a way of
disambiguating commands and data. If your program is one of these, then
it can provide completion for commands, data, or both.
The following sections describe how your program and Readline
cooperate to provide this service.
Readline Convenience Functions
Programming with GNU Readline