# For Windows setup
test -f ~/.aliases && . ~/.functions
test -f ~/.aliases && . ~/.aliases
test -f ~/.private-dotfiles/env && . ~/.private-dotfiles/env
test -f ~/.env.platform && . ~/.env.platform

# Unbreak broken, non-colored terminal
export TERM=xterm-256color

# Don't use ^D to exit
set -o ignoreeof

# Needed for mingw32
export PATH=$HOME/bin/:$HOME/.dotfiles/bin:$PATH

# TMP and TEMP are defined in the Windows environment. Leaving them set to the default
# Windows temporary directory can have unexpected consequences.
export TMP=/tmp
export TEMP=/tmp
export TMPDIR=/tmp

parse_git_branch() {
  git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/'
}

export PS1='\[\033[0;32m\]\[\033[0m\033[0;32m\]\u\[\033[0;36m\] @ \w\[\033[33m\]\n$(parse_git_branch)\[\033[0;32m\]\[\033[0m\033[0;32m\] \$\[\033[0m\033[0;32m\]\[\033[0m\] '

cd ~
