Hash shell includes powerful interactive features for efficient command-line use.
| Key | Action |
Ctrl+A | Move to beginning of line |
Ctrl+E | Move to end of line |
Ctrl+U | Delete to beginning |
Ctrl+K | Delete to end |
Ctrl+W | Delete word backward |
Ctrl+L | Clear screen |
Ctrl+C | Cancel current line |
| Key | Action |
Up | Previous command |
Down | Next command |
!! | Repeat last command |
!n | Run command number n |
!prefix | Run last command starting with prefix |
| Context | Completes |
| First word | Commands, aliases, builtins |
| Other words | Files, directories |
| Double TAB | Show all matches |
The default prompt shows:
/home/user/projects git:(main) #>
- Blue path
- Green/Yellow git status (clean/dirty)
- Cyan branch name
- Blue/Red
#> based on exit code
Configure interactive features in ~/.hashrc:
# Custom prompt
set PS1='\W\g \e#>\e '
# Enable colors
set colors=on