I have this function named st that let's me change the name of the terminal so that I understand what the terminal session is doing.
function st() {
  if [[ -z "$ORIG" ]]; then
    ORIG=$PS1
  fi
  TITLE="\[\e]2;$*\a\]"
  PS1=${ORIG}${TITLE}
}
So when I run st yarn transportation start the title of my terminal changes to yarn transportation start. So far so good.
I don't know much about bash.
But it pains me that I have to now run yarn transportation start to actually run that command. Is there any way that I can run anything after st after the title is changed?
I want to run a single command that changes the title of the terminal and runs the command that I gave in the title
