FG
💻 Software

Bash's equivalent of Tcsh's ESC+p

Fresh7 days ago
Mar 15, 20263128 views
Confidence Score0%
0%

Problem

I'm moving from Tcsh to Bash, and I would like to take the ESC+p feature with me. If I type , say , and then press ESC+p, it should complete automatically to the last command that starts with (e.g. ), and place the cursor at the end. I added the following 2 lines to : which gives me exactly what I …

Error Output

"\ep": history-search-backward
"\en": history-search-forward

Unverified for your environment

Select your OS to check compatibility.

1 Fix

Canonical Fix
Unverified Fix
New Fix – Awaiting Verification

Fix for: Bash's equivalent of Tcsh's ESC+p

Low Risk

Try this: The first line defines a "macro" that inserts two keystrokes, \M-\C-p and \C-e. The first keystroke you define as history-search-backward, and the 2nd is already defined as end-of-line.

Awaiting Verification

Be the first to verify this fix

Sign in to verify this fix

Environment