Six Bash Readline Shortcuts to Speed Up Command-Line Navigation
Bash's Readline library includes several keyboard shortcuts that go beyond basic TAB completion to make terminal use faster and more flexible. Alt-g triggers glob-based completion, allowing users to match filenames by a middle segment rather than just a prefix, while Ctrl-x * expands a glob pattern directly into all matching filenames. Alt-. inserts the last argument from the previous command, saving retyping of long paths or filenames across consecutive commands. Ctrl-r enables incremental reverse search through command history, useful for quickly recalling complex or lengthy commands. For editing particularly long commands, Ctrl-x Ctrl-e opens the current input in the user's configured text editor, returning the edited command to the shell upon saving.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.
Discussion (0)
Log in to join the discussion and vote.
Log in