Prefetch Technologies // Keeping your cache lines cozy

Printing items before PS1

While perusing the bash documentation, I came across the PROMPT_COMMAND variable. If PROMPT_COMMAND is set, bash will execute the command assigned to the variable prior to displaying PS1:

$ export PROMPT_COMMAND="echo \"straight pimpin\""
straight pimpin
$

As you can see from this example, this is super useful. ;)