From 0dd124cf5bbb112309575ea8a81077d616340f7e Mon Sep 17 00:00:00 2001 From: Taylor Bockman Date: Thu, 5 Dec 2019 14:36:55 -0800 Subject: [PATCH] Add first pass bash work --- dotfiles/bash_profile | 12 ++++++++++++ dotfiles/bashrc | 14 ++++++++++++++ 2 files changed, 26 insertions(+) create mode 100644 dotfiles/bash_profile create mode 100644 dotfiles/bashrc diff --git a/dotfiles/bash_profile b/dotfiles/bash_profile new file mode 100644 index 0000000..14046ef --- /dev/null +++ b/dotfiles/bash_profile @@ -0,0 +1,12 @@ +[[ -r ~/.bashrc ]] && . ~/.bashrc +echo ".bashrc loaded" + +# Store private information (exports, keys, etc) in .bash_private. +[[ -r ~/.bash_private ]] && . ~/.bash_private +echo ".bash_private loaded" + +export CC=$(which clang) +export CXX=$(which clang++) + +if which pyenv-virtualenv-init > /dev/null; then eval "$(pyenv virtualenv-init -)"; fi + diff --git a/dotfiles/bashrc b/dotfiles/bashrc new file mode 100644 index 0000000..782cb7d --- /dev/null +++ b/dotfiles/bashrc @@ -0,0 +1,14 @@ +# Use the iterm2 material theme in the root directory of the essentials repository. For linux, +# you will need to source a material theme color scheme for your terminal. + +parse_git_branch() { + git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/' +} + +# If you ever needed weather... +weather() { + curl wttr.in +} + +export PROMPT_DIRTRIM=2 +export PS1="\e[1;37m\u@\h\e[m: \e[1;34m\w\e[m \e[1;32m\[$(parse_git_branch)\]\e[m> "