2020-12-11 17:22:00 +01:00
|
|
|
# Command history tweaks:
|
|
|
|
# - Append history instead of overwriting
|
|
|
|
# when shell exits.
|
|
|
|
# - When using history substitution, do not
|
|
|
|
# exec command immediately.
|
|
|
|
# - Do not save to history commands starting
|
|
|
|
# with space.
|
|
|
|
# - Do not save duplicated commands.
|
|
|
|
shopt -s histappend
|
|
|
|
shopt -s histverify
|
2020-12-11 20:30:14 +01:00
|
|
|
export HISTCONTROL=ignoreboth
|
2020-12-11 17:22:00 +01:00
|
|
|
|
|
|
|
# Default command line prompt.
|
|
|
|
PROMPT_DIRTRIM=2
|
2020-12-11 20:30:14 +01:00
|
|
|
PS1='\[\e[0;32m\]\w\[\e[0m\] \[\e[0;97m\]\$\[\e[0m\] '
|
2020-12-11 17:22:00 +01:00
|
|
|
|
|
|
|
# Handles nonexistent commands.
|
|
|
|
# If user has entered command which invokes non-available
|
|
|
|
# utility, command-not-found will give a package suggestions.
|
2019-07-22 01:23:10 +02:00
|
|
|
if [ -x @TERMUX_PREFIX@/libexec/termux/command-not-found ]; then
|
|
|
|
command_not_found_handle() {
|
|
|
|
@TERMUX_PREFIX@/libexec/termux/command-not-found "$1"
|
|
|
|
}
|
|
|
|
fi
|