mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-08-04 06:36:24 +00:00
Shell integration: bash: Dont fail if an existing PROMPT_COMMAND ends with a semi-colon
Fixes #4645
This commit is contained in:
parent
dddff91fad
commit
f9d9fe6db4
2 changed files with 4 additions and 0 deletions
|
|
@ -141,6 +141,8 @@ _ksi_main() {
|
|||
elif [[ $(builtin declare -p PROMPT_COMMAND 2> /dev/null) =~ 'declare -a PROMPT_COMMAND' ]]; then
|
||||
PROMPT_COMMAND+=("_ksi_prompt_command")
|
||||
else
|
||||
PROMPT_COMMAND="${PROMPT_COMMAND%% }"
|
||||
PROMPT_COMMAND="${PROMPT_COMMAND%%;}"
|
||||
PROMPT_COMMAND+="; _ksi_prompt_command"
|
||||
fi
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue