Update prompt manipulation with functions!

This commit is contained in:
anmiller
2025-08-12 21:41:41 +00:00
parent b66b03bc78
commit dda5fcc784
2 changed files with 110 additions and 98 deletions

View File

@@ -64,3 +64,13 @@ git_prompt()
fi
fi
}
prompt_command_append() {
arg=${1}
PROMPT_COMMAND=${PROMPT_COMMAND:+"$PROMPT_COMMAND; "}"${arg}"
}
prompt_command_prepend() {
arg=${1}
PROMPT_COMMAND="${arg}"${PROMPT_COMMAND:+"; $PROMPT_COMMAND"}
}