I would like to fill out a command which expects a file argument, by alternating the files in the current directory. So I followed Gilles' reply
Bind the Tab key to the
menu-completecommand instead of the defaultcomplete. Put the following line in your~/.bashrc:bind '"\C-i": menu-complete'
Does "\C-i" represent the Tab key? Where is this specified? I thought "\C-i" representing Ctrl-i.
After I run the command bind '"\C-i": menu-complete', the Tab key doesn't seem to work for any purpose (including any kind of auto completion) in bash.
Do I miss understand the purpose of the command?
How can I undo the command, i.e. make the Tab key work for the default style of auto completion again? For recovery, I have run the following commands, some by accident, and none of them seem to work for recovery:
bind -u 'menu-complete'
bind -u 'complete'
bind '"TAB": complete'
bind '"\TAB": complete'
bind '"\C-i": complete'doesn't recover the default setting – Tim Jun 24 '19 at 10:31Tabcharacter is ASCII code 9, this is whatCtrl+igenerates.Ctrl+jgenerates a character with ASCII code 10 (linefeed, or the same asEnter).Ctrl+agenerates a character with code 1.ihappens to be the 9th character of the alphabet, which is whyCtrl+igenerates this character. Why this is so seems to be outside the scope of this question. – Kusalananda Jun 24 '19 at 10:39