Skip to content

Instantly share code, notes, and snippets.

@pbull
Created November 7, 2014 20:51
Show Gist options
  • Save pbull/027a6fcbcfd3c73c7e2a to your computer and use it in GitHub Desktop.
Save pbull/027a6fcbcfd3c73c7e2a to your computer and use it in GitHub Desktop.
Specify Acquia environment in your bash prompt.
# Specify Acquia environment in your bash prompt.
PS0=$PS1
if [ "$AH_SITE_ENVIRONMENT" = "prod" ]; then
ENV_COLOR="\[\033[30;41m\]"
elif [ "$AH_SITE_ENVIRONMENT" = "test" ]; then
ENV_COLOR="\[\033[30;43m\]"
else
ENV_COLOR="\[\033[30;42m\]"
fi
PS1="${ENV_COLOR}[ env: ${AH_SITE_ENVIRONMENT} ]\[\033[00m\] ${PS0}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment