Skip to content

Instantly share code, notes, and snippets.

View StarlitGhost's full-sized avatar
👩‍🚀
Procrastinating

StarlitGhost

👩‍🚀
Procrastinating
View GitHub Profile
@clneagu
clneagu / .bashrc
Last active January 20, 2018 09:09 — forked from cjerdonek/.bashrc
# Call virtualenvwrapper's "workon" if .venv exists. This is modified from--
# http://justinlilly.com/python/virtualenv_wrapper_helper.html
# which is linked from--
# http://virtualenvwrapper.readthedocs.org/en/latest/tips.html#automatically-run-workon-when-entering-a-directory
check_virtualenv() {
if [ -e .venv ]; then
env=`cat .venv`
if [ "$env" != "${VIRTUAL_ENV##*/}" ]; then
echo "Found .venv in directory. Calling: workon ${env}"
workon $env