Skip to content

Instantly share code, notes, and snippets.

@stevenwilliamson
Created February 8, 2017 16:13
Show Gist options
  • Save stevenwilliamson/5fe26cb0a0513c2de24e12b5ec5d4885 to your computer and use it in GitHub Desktop.
Save stevenwilliamson/5fe26cb0a0513c2de24e12b5ec5d4885 to your computer and use it in GitHub Desktop.
Triton Profile bash helpers
# functions for easing working with multiple profiles in the shell
alias tp='triton profiles'
function get_triton_profile() {
[ -n $TRITON_PROFILE ] && echo $TRITON_PROFILE
}
function set_profile() {
export TRITON_PROFILE=$1
}
# Prompt with Triton profile currently set and current Git branch
PS1="\[$Green\]\t\[$Red\]-\[$Blue\]\u\[$Yellow\]\[$Yellow\]:\W\[\033[m\]\[$Red\]:\$(get_triton_profile)\[$Cyan\]\$(__git_ps1)\[$White\]\$ "
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment